Day of Defeat Plugins Community
This site is an archive — everything is readable and downloadable, nothing can be posted. Admin

Unlimited Pistol Ammo

by Hell Phoenix · 2006-07-10 · 29 replies · 20331 views · 522 downloads

Read the thread (30 posts)

From the first post

Description:	This plugin allows for unlimited pistol ammornrnrnCvars:     dod_pistolammo (0|1)  (Default is off 0)rnrnChangelog:rnv1.0    - CreatedrnrnToDo    Nothing

Files

dod_unlimited_pistolammo.sma Plugin Source 3 KB 522 dl Download Compile

Archived builds from the server loose

These compiled builds sat loose in the server's script folder rather than attached to a post. They are matched to this release by comparing their decompiled Pawn against the source published above, so treat the attribution as strong but not certain. Versions come from the register_plugin() call recovered from the bytecode.

dod_unlimited_pistolammo_241.sma v1.0 3 KB Download Compile
1.sma v1.0 modified 2 KB Download Compile
dod_pistolammo.sma v1.0 modified 2 KB Download Compile

The thread

All 30 posts from 13 people on Unlimited Pistol Ammo, kept as they were written.

H Hell Phoenix
started this thread
Posts: 201
Threads: 17
Joined: Jan 2005
07-10-2006, 11:10 AM #1
Description:	This plugin allows for unlimited pistol ammornrnrnCvars:     dod_pistolammo (0|1)  (Default is off 0)rnrnChangelog:rnv1.0    - CreatedrnrnToDo    Nothing
J jason
posted here
Posts: 75
Threads: 10
Joined: Apr 2005
07-23-2006, 06:03 PM #2

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]
posted here
Posts: 623
Threads: 57
Joined: Oct 2005
07-23-2006, 09:25 PM #3

What version of the compiler do you have? AmxModX was recently updated -- make sure you have the most recent compiler on your computer.

H Hell Phoenix
started this thread
Posts: 201
Threads: 17
Joined: Jan 2005
07-23-2006, 10:37 PM #4

You have to use at least amxx 1.71 or above. What version are you using?

J jason
posted here
Posts: 75
Threads: 10
Joined: Apr 2005
07-24-2006, 03:21 AM #5

I just been using the one on www.amxmodx.org site... I just upload the sma and compile. http://www.amxmodx.org/webcompiler.cgi

H Hell Phoenix
started this thread
Posts: 201
Threads: 17
Joined: Jan 2005
07-24-2006, 11:25 AM #6

No...what version of amxx do you have running on your server? It has to be at least 1.71.

J jason
posted here
Posts: 75
Threads: 10
Joined: Apr 2005
07-24-2006, 01:45 PM #7

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.nnn__________nSee ya on the battlefield!!!nKeeping the community alive!!!n63.215.74.212:27015 $ad|+:*:+|Avalanche|+:*:+ {FuNpLuGiNs+32 $lots MaYhAm}

H Hell Phoenix
started this thread
Posts: 201
Threads: 17
Joined: Jan 2005
07-24-2006, 02:05 PM #8

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

J jason
posted here
Posts: 75
Threads: 10
Joined: Apr 2005
07-24-2006, 02:17 PM #9

You bring a tear to my eye .... THANKYOU!rnrn__________rnSee ya on the battlefield!!!rnKeeping the community alive!!!rn63.215.74.212:27015 $ad|+:*:+|Avalanche|+:*:+ {FuNpLuGiNs+32 $lots MaYhAm}

J jason
posted here
Posts: 75
Threads: 10
Joined: Apr 2005
07-24-2006, 04:58 PM #10

All updated and worked. Thanks!

S spitfire
posted here
Posts: 39
Threads: 4
Joined: Jul 2006
07-30-2006, 05:02 PM #11

Well I installed checked the plugins list and its running.rnrnOnly one problem I go into my console and try to turn it on it wont work any suggestions?rnrnThx for any and all help.

H Hell Phoenix
started this thread
Posts: 201
Threads: 17
Joined: Jan 2005
07-31-2006, 12:30 AM #12

What version of amxx are you using?

D dragonspirit666
posted here
Posts: 4
Threads: 0
Joined: Jul 2006
10-15-2006, 12:56 PM #13

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
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
10-15-2006, 01:04 PM #14
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..
nntry the online compiler?nnhttps://www.dodplugins.net/compiler/

D dragonspirit666
posted here
Posts: 4
Threads: 0
Joined: Jul 2006
10-15-2006, 01:06 PM #15

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.

D Draagun
posted here
Posts: 5
Threads: 2
Joined: Jun 2007
10-20-2007, 12:58 AM #16

thank you, works great on our linux server amxx 1.76d

J jondoe
posted here
Posts: 129
Threads: 6
Joined: Aug 2005
01-06-2008, 09:14 PM #17

This plugin is very nice but im getting a runtime error in my logs.rnrnrn

rnL 01/06/2008 - 01:04:15: Start of error session.rnL 01/06/2008 - 01:04:15: Info (map "dod_dust") (logfile "error_010608.log")rnL 01/06/2008 - 01:04:15: [DODX] Invalid player 5rnL 01/06/2008 - 01:04:15: [AMXX] Displaying debug trace (plugin "dod_unlimited_pistolammo.amxx")rnL 01/06/2008 - 01:04:15: [AMXX] Run time error 10: native error (native "get_user_team")rnL 01/06/2008 - 01:04:15: [AMXX]    [0] dod_unlimited_pistolammo.sma::give_pammo (line 78)rn
rnrnAnd here is what's at that line.rnrn
rn}rnpublic give_pammo(id){rnif(get_user_team(id) == AXIS){rndod_set_user_ammo(id,DODW_LUGER,999)rnreturn PLUGIN_HANDLEDrn}rn
diamond-optic
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
01-06-2008, 11:06 PM #18

that error isnt a big deal and hell phoenix could easily fix it by just adding a is_user_connected checknnbut 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)nn

#include <amxmodx>n#include <dodfun>n#include <dodx>nn#define PLUGIN "DoD Unlimited Pistol Ammo"n#define VERSION "1.0 modified"n#define AUTHOR "AMXX DoD Community"nnnew pistolammonnpublic plugin_init()n{n    register_plugin(PLUGIN, VERSION, AUTHOR)n   n    pistolammo = register_cvar("dod_pistolammo","0")n   n    register_event("ResetHUD","give_ammo","be")n}nnpublic give_ammo(id)n{n    if(get_pcvar_num(pistolammo))n        set_task(0.1,"give_pammo",id)n}nnpublic give_pammo(id)n{n    if(is_user_connected(id))n        {        n        new team = get_user_team(id)n    n        if(team == AXIS)n            dod_set_user_ammo(id,DODW_LUGER,999)n        else if(team == ALLIES)n            {n            if(dod_get_map_info(MI_ALLIES_TEAM) == 1)n                dod_set_user_ammo(id,DODW_WEBLEY,999)n            elsen                dod_set_user_ammo(id,DODW_COLT,999)n            }n        }n}
J jondoe
posted here
Posts: 129
Threads: 6
Joined: Aug 2005
01-06-2008, 11:21 PM #19
that error isnt a big deal and hell phoenix could easily fix it by just adding a is_user_connected checkrnrnbut 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)rnrn
#include <amxmodx>rn#include <dodfun>rn#include <dodx>rnrn#define PLUGIN "DoD Unlimited Pistol Ammo"rn#define VERSION "1.0 modified"rn#define AUTHOR "AMXX DoD Community"rnrnnew pistolammornrnpublic plugin_init()rn{rn    register_plugin(PLUGIN, VERSION, AUTHOR)rn   rn    pistolammo = register_cvar("dod_pistolammo","0")rn   rn    register_event("ResetHUD","give_ammo","be")rn}rnrnpublic give_ammo(id)rn{rn    if(get_pcvar_num(pistolammo))rn        set_task(0.1,"give_pammo",id)rn}rnrnpublic give_pammo(id)rn{rn    if(is_user_connected(id))rn        {        rn        new team = get_user_team(id)rn    rn        if(team == AXIS)rn            dod_set_user_ammo(id,DODW_LUGER,999)rn        else if(team == ALLIES)rn            {rn            if(dod_get_map_info(MI_ALLIES_TEAM) == 1)rn                dod_set_user_ammo(id,DODW_WEBLEY,999)rn            elsern                dod_set_user_ammo(id,DODW_COLT,999)rn            }rn        }rn}
rnrnrnAwesome dude you rock, as usual. will test it out right now.

J jondoe
posted here
Posts: 129
Threads: 6
Joined: Aug 2005
02-03-2008, 03:19 PM #20

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. rnrn

rn02/02/2008 - 15:18:23: [AMXX] Displaying debug trace (plugin "dod_unlimited_pistolammo.amxx")rnL 02/02/2008 - 15:18:23: [AMXX] Run time error 10: native error (native "get_user_team")rnL 02/02/2008 - 15:18:23: [AMXX]    [0] dod_unlimited_pistolammo.sma::give_pammo (line 78)rnLrn
I ijack
posted here
Posts: 10
Threads: 0
Joined: Feb 2008
10-22-2008, 09:56 AM #21

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?rnany sugestions?

Tank
posted here
Posts: 581
Threads: 59
Joined: Jan 2007
10-22-2008, 11:23 AM #22

Take the plugin off, redownload the plugin, make sure it's compiled for your amxmodx version and place it back on...My only suggestion

I ijack
posted here
Posts: 10
Threads: 0
Joined: Feb 2008
10-22-2008, 10:13 PM #23

thank you sir

Tank
posted here
Posts: 581
Threads: 59
Joined: Jan 2007
10-26-2008, 10:46 AM #24

Did this solve your problems though?

I ijack
posted here
Posts: 10
Threads: 0
Joined: Feb 2008
10-27-2008, 09:59 PM #25

yes it did thanks again

R Raider
posted here
Posts: 2
Threads: 0
Joined: Dec 2008
01-01-2009, 07:54 AM #26

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...rnany help?

meathead
posted here
Posts: 337
Threads: 23
Joined: Aug 2007
01-01-2009, 12:46 PM #27

did you add the cvar to your amxx.cfg file? rnrndod_pistolammo 1rnrnAlso as previously stated you must have amx v1.71 or newer.

R Raider
posted here
Posts: 2
Threads: 0
Joined: Dec 2008
01-01-2009, 06:41 PM #28

thanx i did not have the cvar in there

Tank
posted here
Posts: 581
Threads: 59
Joined: Jan 2007
06-09-2009, 07:07 PM #29

So I re-enabled the plugin and still getting the issue D-O tried to resolve in an earlier post.rnrnIm 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
posted here
Posts: 776
Threads: 75
Joined: Nov 2007
06-10-2009, 03:51 PM #30

i would try with Ham_Item_Deploy :rnrn

/**rn * Description: Deploys the entity (usually a weapon).rn * Forward params: function(this);rn * Return type: Integer (boolean).rn * Execute params: ExecuteHam(Ham_Item_Deploy, this);rn */rn Ham_Item_Deploy,
DoD Plugins Archive · Repository · Old Forum Threads · Maps · Admin · built 14 Sep 2026 00:34 UTC