FrameIT
|
Base class for all Gadgets to derive from. A Gadget is a tool for the player (and level editor) to interact with the GameWorld. More...
Public Member Functions | |
virtual void | OnHit (RaycastHit hit) |
Called when CommunicationEvents.TriggerEvent is invoked, a.k.a. when Player clicks in GameWorld. More... | |
Public Attributes | |
int | id = -1 |
Position in tool belt. More... | |
string | UiName = "Name Not Set" |
Tool Name More... | |
float | MaxRange |
Maximum range for this Tool. For consistency use GadgetDistances in GlobalBehaviour. More... | |
Sprite | Sprite |
Which sprite to use More... | |
LayerMask | ignoreLayerMask |
Layers to ignore for thid gadget by default. More... | |
WorldCursor | Cursor |
Which cursor to use More... | |
Protected Member Functions | |
void | Awake () |
void | OnEnable () |
Base class for all Gadgets to derive from. A Gadget is a tool for the player (and level editor) to interact with the GameWorld.
|
protected |
|
protected |
|
virtual |
Called when CommunicationEvents.TriggerEvent is invoked, a.k.a. when Player clicks in GameWorld.
hit | the position where it was clicked |
Reimplemented in AngleTool, ExtraGadget, LineTool, LotTool, Pendulum, Pointer, PoleTool, Remover, and Tape.
WorldCursor Gadget.Cursor |
Which cursor to use
When not set in Inspector, will be searching for any WorldCursor.
int Gadget.id = -1 |
Position in tool belt.
Set in Inspector or Awake
LayerMask Gadget.ignoreLayerMask |
Layers to ignore for thid gadget by default.
Set in Inspector
float Gadget.MaxRange |
Maximum range for this Tool. For consistency use GadgetDistances in GlobalBehaviour.
Set in Inspector or Awake
Sprite Gadget.Sprite |
Which sprite to use
Set in Inspector
string Gadget.UiName = "Name Not Set" |
Tool Name
Set in Inspector or Awake