AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   New-Era's Unlimited Ammo v1.0.1 Updated ! (https://forums.alliedmods.net/showthread.php?t=72574)

New-Era 06-10-2008 23:05

New-Era's Unlimited Ammo v1.0.1 Updated !
 
4 Attachment(s)
v1.0.1 updated ! (pcvars)

Hello. :)


This plugin for cs 1.6 gives all players unlimited ammo with reload.
What more can I say?


Installation :
Put "addons\amxmodx\plugins\ne_unlimitedammo.amxx " to "addons\amxmodx\plugins\" in your server.
Then put "ne_unlimitedammo.amxx" without the quotes in the bottom of your plugins.ini file in the addons/amxmodx/configs folder.


Cvars :
ne_uammo_enable
Default: "1"
Enables and disables the plugin.

Any suggestions let me know.

Sn!ff3r 06-10-2008 23:19

Re: Team New-Era's Unlimited Ammo v1.0.0
 
v3x's plugin is better.

Shaman 06-10-2008 23:22

Re: Team New-Era's Unlimited Ammo v1.0.0
 
Wow! You tested it so fast!

New-Era 06-10-2008 23:25

Re: Team New-Era's Unlimited Ammo v1.0.0
 
Sorry , But isn't v3x's plugin set so only admins can give it to a player?

atomen 06-11-2008 06:28

Re: Team New-Era's Unlimited Ammo v1.0.0
 
You have to use pcvars to get your plugin approved
PHP Code:

#define NE_UA_VERSION "1.0.0"

/*
    New-Era_UnlimitedAmmo by New-Era Scripting Team members:
        Alican Çubukçuoğlu (AKA AlicanC and Shaman)Xoxo Sneaky
    
    You can reach us from Steam Community group "#n.E Scripting Team"
*/
#include <amxmodx>
#include <amxmisc>

#include <cstrike>
#include <fakemeta>

#define find_ent_by_class(%1,%2) engfunc(EngFunc_FindEntityByString, %1, "classname", %2)

new ne_uammo_enable
new CSW_MAXAMMO[33]=
{
    -
2,
    
52,
    
0,
    
90,
    
1,
    
32,
    
1,
    
100,
    
90,
    
1,
    
120,
    
100,
    
100,
    
90,
    
90,
    
90,
    
100,
    
120,
    
30,
    
120,
    
200,
    
32,
    
90,
    
120,
    
90,
    
2,
    
35,
    
90,
    
90,
    
0,
    
100,
    -
1,
    -
1
}

public 
plugin_init()
{
    
register_plugin("New-Era_UnlimitedAmmo"NE_UA_VERSION"New-Era Scripting Team")
    
register_cvar("ne_uammo_version"NE_UA_VERSIONFCVAR_SPONLY)

    
ne_uammo_enable        =    register_cvar("ne_uammo_enable""1")

    
register_event("CurWeapon""event_curweapon""be""1=1")
    
register_clcmd("ne_uammo""command_ne_uammo"_"Dispays information about New-Era_UnlimitedAmmo")
}

public 
event_curweapon(id)
{
    if(!
get_pcvar_num(ne_uammo_enable) || !is_user_alive(id))
        return 
0

    
new weaponID read_data(2)
    if(
weaponID == CSW_C4 || weaponID == CSW_KNIFE || weaponID == CSW_HEGRENADE || weaponID == CSW_SMOKEGRENADE || weaponID == CSW_FLASHBANG)
        return 
PLUGIN_CONTINUE;
    
    
cs_set_user_bpammo(idweaponIDCSW_MAXAMMO[weaponID])
    
    return 
0
}

public 
command_ne_uammo(idlevelclientId)
{
    
client_print(idprint_console" ")
    
client_print(idprint_console"+-----|  About New-Era_UnlimitedAmmo  |-----+")
    
client_print(idprint_console"| ")
    
client_print(idprint_console"| New-Era_UnlimitedAmmo %s"NE_UA_VERSION)
    
client_print(idprint_console"| ")
    
client_print(idprint_console"| Coded by New-Era Scripting Team members:")
    
client_print(idprint_console"|     Alican Cubukcuoglu (AKA AlicanC and Shaman)")
    
client_print(idprint_console"| ")
    
client_print(idprint_console"| You can reach us from Steam Community group ^"#n.E Scripting Team^"")
    
client_print(idprint_console"| ")
    
client_print(idprint_console"+-----+")
    
client_print(idprint_console" ")
    
    return 
1



New-Era 06-11-2008 13:01

Re: Team New-Era's Unlimited Ammo v1.0.0
 
It says "use pcvars where optimization is important" and in our case optimization isn't much important. We can add it in next version though.

soccdoodcss 06-11-2008 13:15

Re: Team New-Era's Unlimited Ammo v1.0.0
 
Not going to lie, I enjoy the chat message. However I suggest checking if the player already has the maximum amount of ammunition before giving him more. And I strongly suggest the use of pcvars. Maybe it isn't a large optimization but when you have multiple plugins running, the slightest bit could make a difference, even if it is tiny.

YamiKaitou 06-11-2008 13:55

Re: Team New-Era's Unlimited Ammo v1.0.0
 
Quote:

Originally Posted by New-Era (Post 637668)
It says "use pcvars where optimization is important" and in our case optimization isn't much important. We can add it in next version though.

Approval will NOT be granted if you do not use pcvars. *et_pcvar_* is much faster than using *et_cvar_*


Also, what is the point of the ne_uammo_version command?

New-Era 06-11-2008 14:06

Re: Team New-Era's Unlimited Ammo v1.0.0
 
Uhh yami wow ........ "ne_uammo_version" is not a command , thank you .....
Same goes for you yami ....... read the post above socc's ...... Then you can talk to me ...... RTFMP !!!!

New-Era 06-11-2008 14:41

Re: Team New-Era's Unlimited Ammo v1.0.0
 
You know that idc? He should RTFMP? Not my fault.

http://forums.alliedmods.net/showthread.php?t=21956

Read GHW's post ...


All times are GMT -4. The time now is 01:02.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.