Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Reset or refill ammo everytime player joins new team?

Asked by
Sunzig 0
6 years ago

I'm new to Lua, I've been trying to write a short script to reset the players ammo at the beginning of every level.

At the beginning of every level there is a new spawn location when touched changes the players team.

I've been trying to write a short onTouched script to reset their "Tool" or gun so they have a full clip at the beginning of each level instead of having to die and respawn.

Every script I write breaks the gun or has no effect. Any help would be appreciated.

I'd be happy with an onTouched script I can put into every new spawnpoint that resets the gun, or updates ammo, or if there is a local script to reset the gun everytime a player joins a new team I think that would be the cleanest way to do it. However I'm open to all suggestions.

Thanks! ~Sunzig

Answer this question