I searched and searched already... so don't yell at me if this topic is out there already.
I'm trying make my game function in such a way that the player can only hold three weapons at a time, along with a knife. And perhaps, while I'm at it, only a certain amount of ammunition for each of these three weapons.
Per say, a rifle, a pistol, and a grenade.
And in order to do this, the pickup script would have to be compatible with some kind of "Press F to pick up ____" type thing, as well as a "dropcurrentweapon" type thing
And of course, the player cannot drop the knife.
Any suggestions about how I might begin yet another dauntless task?
I'm thinking that if there is a static variable for the number of weapons the player currently has, and if there is a way to tell what each weapon is, this process will become phenomenonally easier.
Also, the pickup script will have to be edited so that instead of automatically picking up the weapon as the player walks over it, the text "Press F to pick up ___" will be displayed. And when the player presses F, the weapon is picked up/swapped with the weapon the player is currently wielding
i know how i'm going to do the pickup script
i do not know how to limit the number of weapons the player can carry at one time
Suggestions?
"There's more to life than being really, really, ridiculously good looking." - Derek Zoolander