Page 1 of 2
Adjusting Ammo
Posted: Mon Feb 25, 2013 3:14 am
by CraftDinur
Is it possible to adjust your clip and reserve ammo on spawn and maintain that throughout the game? For example, could I change the shotgun to have 10 ammo in clip and 50 in reserve like a rifle and stay that way through the whole game? I've been attempting to make a script that will do this but it seems to be failing and whenever I go in game nothing happens.
Re: Adjusting Ammo
Posted: Mon Feb 25, 2013 3:16 am
by Jdrew
It would be nice for the guns to have more ammo and not just the rifle and shot gun
Re: Adjusting Ammo
Posted: Mon Mar 04, 2013 9:32 pm
by LinktersHD
CraftDinur wrote:Is it possible to adjust your clip and reserve ammo on spawn and maintain that throughout the game? For example, could I change the shotgun to have 10 ammo in clip and 50 in reserve like a rifle and stay that way through the whole game? I've been attempting to make a script that will do this but it seems to be failing and whenever I go in game nothing happens.
Nope, it's client side with the amount of ammo, though it might be possible.
Re: Adjusting Ammo
Posted: Mon Mar 04, 2013 11:14 pm
by topo
Danko pasted this in #aloha a while ago (possibly originally showing it to you?) but in case anyone else wants it,
http://paste.quacknet.org/view/e53282c7 ... 81c95da.py
Re: Adjusting Ammo
Posted: Tue Mar 05, 2013 12:13 am
by Handles
Im not sure it's possible...

Re: Adjusting Ammo
Posted: Tue Mar 05, 2013 7:26 am
by LinktersHD
topo wrote:Danko pasted this in #aloha a while ago (possibly originally showing it to you?) but in case anyone else wants it, http://paste.quacknet.org/view/e53282c7 ... 81c95da.py
Have you tried it out?
Re: Adjusting Ammo
Posted: Tue Mar 05, 2013 9:21 pm
by CraftDinur
topo wrote:Danko pasted this in #aloha a while ago (possibly originally showing it to you?) but in case anyone else wants it, http://paste.quacknet.org/view/e53282c7 ... 81c95da.py
i didn't see this. thanks for posting it here. i'll try this out when i have some spare time.
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 8:48 pm
by LinktersHD
CraftDinur wrote:topo wrote:Danko pasted this in #aloha a while ago (possibly originally showing it to you?) but in case anyone else wants it, http://paste.quacknet.org/view/e53282c7 ... 81c95da.py
i didn't see this. thanks for posting it here. i'll try this out when i have some spare time.
Did you try it?
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 9:00 pm
by topo
Why don't you try it?
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 9:27 pm
by LinktersHD
topo wrote:Why don't you try it?
Haven't got time, but i do now, going to try it out now.
Code: Select allfrom pyspades.server import weapon_reload
# Run this on players at spawn to set their ammo/stock to whatever
# Not sure how well this works *in general*, because I've only tested with ridiculous values
# and that's caused some reloading bugs
def bleep_bloop(player, new_ammo, new_stock):
weapon = player.weapon_object
weapon.set_shoot(False)
weapon.current_ammo = new_ammo
weapon.current_stock = new_stock
weapon_reload.player_id = player.player_id
weapon_reload.clip_ammo = weapon.current_ammo
weapon_reload.reserve_ammo = weapon.current_stock
player.send_contained(weapon_reload)
Do i replace "new_ammo with the amount of ammo and etc?
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 9:33 pm
by LinktersHD
Simple answer....NO it does not work:

Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 10:18 pm
by topo
you are legitimately awful
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 10:20 pm
by cow
Excuse the shameless advertising, but it's already been done on Stormwind's servers :)
Re: Adjusting Ammo
Posted: Wed Mar 06, 2013 10:26 pm
by EldredChandler
omg this entire thing
Re: Adjusting Ammo
Posted: Thu Mar 07, 2013 6:02 pm
by LinktersHD
cow wrote:Excuse the shameless advertising, but it's already been done on Stormwind's servers :)
How did you do it?