PDA

View Full Version : Unlimited Pistol Ammo


Hell Phoenix
07-10-2006, 12:10 PM
Description: This plugin allows for unlimited pistol ammo


Cvars: dod_pistolammo (0|1) (Default is off 0)

Changelog:
v1.0 - Created

ToDo Nothing

jason
07-23-2006, 07:03 PM
Odd I compiled the sma to amxx. Added the amxx into the plugins folder and the sma in the scripting folder. Then added dod_unlimited_pistolammo.amxx to the plugins.ini folder and then restarted the server. All I get is "unknown unknown unknown dod_unlimited_p bad load" I also added the cvar dod_pistolammo 1. I was figuring it does with the compile or plugins.ini folder. Any suggestions?

Wilson [29th ID]
07-23-2006, 10:25 PM
What version of the compiler do you have? AmxModX was recently updated -- make sure you have the most recent compiler on your computer.

Hell Phoenix
07-23-2006, 11:37 PM
You have to use at least amxx 1.71 or above. What version are you using?

jason
07-24-2006, 04:21 AM
I just been using the one on www.amxmodx.org site... I just upload the sma and compile. http://www.amxmodx.org/webcompiler.cgi

Hell Phoenix
07-24-2006, 12:25 PM
No...what version of amxx do you have running on your server? It has to be at least 1.71.

jason
07-24-2006, 02:45 PM
Doh! LOL! I am currently running amxmodx v1.60, metamod v1.18 ... hmm odd bec we usually have the most updated vers of amxmodx but I guess that is the problem....tho I have alot of plugins already but that would make sense bec chicken, unlimmited pisol ammo, and nadesforall are getting bad loads. Hmmm I guess I need to upgrade to 1.75 seing Im outdated ...crazy I feel like a noob LOL! I swear you guys should be given a dod medal.


__________
See ya on the battlefield!!!
Keeping the community alive!!!
63.215.74.212:27015 $ad|+:*:+|Avalanche|+:*:+ {FuNpLuGiNs+32 $lots MaYhAm}

Hell Phoenix
07-24-2006, 03:05 PM
Version 1.71 introduced a way to make plugins faster, and most of the coders updated their plugins to take advantage of that. All those plugins should work once you get it updated =D

jason
07-24-2006, 03:17 PM
You bring a tear to my eye .... THANKYOU!

__________
See ya on the battlefield!!!
Keeping the community alive!!!
63.215.74.212:27015 $ad|+:*:+|Avalanche|+:*:+ {FuNpLuGiNs+32 $lots MaYhAm}

jason
07-24-2006, 05:58 PM
All updated and worked. Thanks!

spitfire
07-30-2006, 06:02 PM
Well I installed checked the plugins list and its running.

Only one problem I go into my console and try to turn it on it wont work any suggestions?

Thx for any and all help.

Hell Phoenix
07-31-2006, 01:30 AM
What version of amxx are you using?

dragonspirit666
10-15-2006, 01:56 PM
hey, i was wondering if one of you guys could, post a amxx file type for this mod, for some reason i cant compile plugins. its pissing me off. thanks, id very much appreceate it. dont mind my spelling..

diamond-optic
10-15-2006, 02:04 PM
hey, i was wondering if one of you guys could, post a amxx file type for this mod, for some reason i cant compile plugins. its pissing me off. thanks, id very much appreceate it. dont mind my spelling..

try the online compiler?

http://www.dodplugins.net/compiler/

dragonspirit666
10-15-2006, 02:06 PM
well, so far the file is compiled, but i cant seem to get my ftp open now. funny how things work. thanks though, this helps alot. peace.

Draagun
10-20-2007, 01:58 AM
thank you, works great on our linux server amxx 1.76d

jondoe
01-06-2008, 09:14 PM
This plugin is very nice but im getting a runtime error in my logs.



L 01/06/2008 - 01:04:15: Start of error session.
L 01/06/2008 - 01:04:15: Info (map "dod_dust") (logfile "error_010608.log")
L 01/06/2008 - 01:04:15: [DODX] Invalid player 5
L 01/06/2008 - 01:04:15: [AMXX] Displaying debug trace (plugin "dod_unlimited_pistolammo.amxx")
L 01/06/2008 - 01:04:15: [AMXX] Run time error 10: native error (native "get_user_team")
L 01/06/2008 - 01:04:15: [AMXX] [0] dod_unlimited_pistolammo.sma::give_pammo (line 78)


And here is what's at that line.


}
public give_pammo(id){
if(get_user_team(id) == AXIS){
dod_set_user_ammo(id,DODW_LUGER,999)
return PLUGIN_HANDLED
}

diamond-optic
01-06-2008, 11:06 PM
that error isnt a big deal and hell phoenix could easily fix it by just adding a is_user_connected check

but anyway since no one can say when or if that will happen.. you can try this code here which is slightly modifed (added the connected check as well as simplified some other stuff)

#include <amxmodx>
#include <dodfun>
#include <dodx>

#define PLUGIN "DoD Unlimited Pistol Ammo"
#define VERSION "1.0 modified"
#define AUTHOR "AMXX DoD Community"

new pistolammo

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)

pistolammo = register_cvar("dod_pistolammo","0")

register_event("ResetHUD","give_ammo","be")
}

public give_ammo(id)
{
if(get_pcvar_num(pistolammo))
set_task(0.1,"give_pammo",id)
}

public give_pammo(id)
{
if(is_user_connected(id))
{
new team = get_user_team(id)

if(team == AXIS)
dod_set_user_ammo(id,DODW_LUGER,999)
else if(team == ALLIES)
{
if(dod_get_map_info(MI_ALLIES_TEAM) == 1)
dod_set_user_ammo(id,DODW_WEBLEY,999)
else
dod_set_user_ammo(id,DODW_COLT,999)
}
}
}

jondoe
01-06-2008, 11:21 PM
that error isnt a big deal and hell phoenix could easily fix it by just adding a is_user_connected check

but anyway since no one can say when or if that will happen.. you can try this code here which is slightly modifed (added the connected check as well as simplified some other stuff)

#include <amxmodx>
#include <dodfun>
#include <dodx>

#define PLUGIN "DoD Unlimited Pistol Ammo"
#define VERSION "1.0 modified"
#define AUTHOR "AMXX DoD Community"

new pistolammo

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)

pistolammo = register_cvar("dod_pistolammo","0")

register_event("ResetHUD","give_ammo","be")
}

public give_ammo(id)
{
if(get_pcvar_num(pistolammo))
set_task(0.1,"give_pammo",id)
}

public give_pammo(id)
{
if(is_user_connected(id))
{
new team = get_user_team(id)

if(team == AXIS)
dod_set_user_ammo(id,DODW_LUGER,999)
else if(team == ALLIES)
{
if(dod_get_map_info(MI_ALLIES_TEAM) == 1)
dod_set_user_ammo(id,DODW_WEBLEY,999)
else
dod_set_user_ammo(id,DODW_COLT,999)
}
}
}


Awesome dude you rock, as usual. will test it out right now.

jondoe
02-03-2008, 03:19 PM
Ok i been busy doing other things but just got a chance to test that code update out Diamond and im still getting that error.


02/02/2008 - 15:18:23: [AMXX] Displaying debug trace (plugin "dod_unlimited_pistolammo.amxx")
L 02/02/2008 - 15:18:23: [AMXX] Run time error 10: native error (native "get_user_team")
L 02/02/2008 - 15:18:23: [AMXX] [0] dod_unlimited_pistolammo.sma::give_pammo (line 78)
L

ijack
10-22-2008, 10:56 AM
I had this working at one time then all of a sudden the thing locked it self so I can't start or stop it?
any sugestions?

Tank
10-22-2008, 12:23 PM
Take the plugin off, redownload the plugin, make sure it's compiled for your amxmodx version and place it back on...My only suggestion

ijack
10-22-2008, 11:13 PM
thank you sir

Tank
10-26-2008, 11:46 AM
Did this solve your problems though?

ijack
10-27-2008, 10:59 PM
yes it did thanks again

Raider
01-01-2009, 07:54 AM
okay im pretty new to a lot of this but i have the unlimited pistol ammo working and it says its running... but does not show that it works and when i type dod_pistolammo it doesnt show that its on...
any help?

meathead
01-01-2009, 12:46 PM
did you add the cvar to your amxx.cfg file?

dod_pistolammo 1

Also as previously stated you must have amx v1.71 or newer.

Raider
01-01-2009, 06:41 PM
thanx i did not have the cvar in there

Tank
06-09-2009, 08:07 PM
So I re-enabled the plugin and still getting the issue D-O tried to resolve in an earlier post.

Im still getting the errors posted before. Anyone know how to fix this. I know it's not a bad error as also posted before but I rather have no errors at all.

Dr.G
06-10-2009, 04:51 PM
i would try with Ham_Item_Deploy :

/**
* Description: Deploys the entity (usually a weapon).
* Forward params: function(this);
* Return type: Integer (boolean).
* Execute params: ExecuteHam(Ham_Item_Deploy, this);
*/
Ham_Item_Deploy,