would take away a weapon with a weapon file called current_weapon from the player, which does obviouly not exist. You probably want something like this:
Code Snippet
Plaintext
current_weapon = self GetCurrentWeapon(); self TakeWeapon(current_weapon); // You should probably switch to another one then
If you mean (by "get up"), after the player is revived, you could also call GetWeaponsListPrimaries() and remove a weapon from that list if it contains 3.
would take away a weapon with a weapon file called current_weapon from the player, which does obviouly not exist. You probably want something like this:
Code Snippet
Plaintext
current_weapon = self GetCurrentWeapon(); self TakeWeapon(current_weapon); // You should probably switch to another one then
If you mean (by "get up"), after the player is revived, you could also call GetWeaponsListPrimaries() and remove a weapon from that list if it contains 3.
- Phil.
the question is where i put that in laststand.gsc or zombiemode.gsc?
Has the ability to issue warnings to users, edit and remove posts from the forum and to move topics to other boards. Upholds the rules of the forum. Moderates Chat Rooms.
the question is where i put that in laststand.gsc or zombiemode.gsc?
You put it wherever your TakeWeapon code already is... "current_weapon" is not a valid parameter for TakeWeapon. You have to use a valid gun name and the player has to have the gun in order for it to do anything. current_weapon = self GetCurrentWeapon() sets the variable to the string name of whatever gun the player is holding when the function runs. Then self TakeWeapon(current_weapon) will take that gun name from the player.
You put it wherever your TakeWeapon code already is... "current_weapon" is not a valid parameter for TakeWeapon. You have to use a valid gun name and the player has to have the gun in order for it to do anything. current_weapon = self GetCurrentWeapon() sets the variable to the string name of whatever gun the player is holding when the function runs. Then self TakeWeapon(current_weapon) will take that gun name from the player.
if i give you the scripts you can see it? Post Merge: February 19, 2013, 07:15:34 amUpdate on the first reply! Post Merge: February 19, 2013, 07:18:10 amads
Last Edit: February 19, 2013, 07:18:10 am by DARKLEGION