![]() |
FCV Engine 0.1
A tool and framework for tutorials in game development
|
Controls what weapons are picked up, which ones are to be active and sends event accordingly. More...
Private Member Functions | |
void | Update () |
Checks for distance to weapons and adds them to list if they are close enough to be picked up. Checks for inputs to control which is the active weapon. | |
void | AddWeapon (Weapon weapon) |
Sets the weapon up to be stored in the weapon controller. | |
void | CheckForInput () |
If input key was pressed set that to active weapon, only checks up to amount of active weapons. | |
void | SetActiveWeapon (int index) |
Unequips old weapons and equips new one. | |
Controls what weapons are picked up, which ones are to be active and sends event accordingly.
Definition at line 12 of file WeaponController.cs.
|
private |
Sets the weapon up to be stored in the weapon controller.
weapon | Weapon to be added |
Definition at line 67 of file WeaponController.cs.
|
private |
Unequips old weapons and equips new one.
index | index for weapon |
Definition at line 95 of file WeaponController.cs.