ST_DemoTurretSwitcher
A simple script to allow a player to use number keys to switch between turrets.
Public Variables
ActivatedBehavior : ControlType enum { AI_AutoTarget, None, Player_Mouse, Player_Click }
How the turret acts when its number key is pressed.
DeactivatedBehavior : ControlType
How the turret acts when other number keys are pressed.
switchCamera : bool
If true, will switch to the camera assigned to a turret when activated.
turrets : TurretData[]
An array of turrets to switch between. This should not be more than 9 turrets.
selectedTurret : int
The index of the currently selected turret.
playerScript : ST_Player
If blank: Will assume the player script is on the same object. May also be left blank if none of the behaviors use a player script.
Public Class TurretData
turretScript : ST_TurretControl
The turret assigned to this index.
turretCamera : GameObject
The camera to use when this index is activated.
A simple script to allow a player to use number keys to switch between turrets.
Public Variables
ActivatedBehavior : ControlType enum { AI_AutoTarget, None, Player_Mouse, Player_Click }
How the turret acts when its number key is pressed.
DeactivatedBehavior : ControlType
How the turret acts when other number keys are pressed.
switchCamera : bool
If true, will switch to the camera assigned to a turret when activated.
turrets : TurretData[]
An array of turrets to switch between. This should not be more than 9 turrets.
selectedTurret : int
The index of the currently selected turret.
playerScript : ST_Player
If blank: Will assume the player script is on the same object. May also be left blank if none of the behaviors use a player script.
Public Class TurretData
turretScript : ST_TurretControl
The turret assigned to this index.
turretCamera : GameObject
The camera to use when this index is activated.