CustomActivateTrigger

From Headbone Creative
Revision as of 23:14, 19 April 2013 by Tyson Joehler (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This is an enhanced version of the ActivateTrigger script included with Unity's Standard Assets.

Public Variables

/// <summary> /// Trigger mode /// </summary> public enum Mode { Trigger = 0, // Just broadcast the action on to the target Replace = 1, // replace target with source Activate = 2, // Activate the target GameObject Enable = 3, // Enable a component Animate = 4, // Start animation on target Deactivate= 5, // Decativate target GameObject Broadcast = 6, // Broadcast the message using the messenger Spawn = 7, // Spawn the source object at the target }

/// <summary> /// The action. /// </summary> public Mode action = Mode.Activate;

/// <summary> /// The game object to affect. If none, the trigger work on this game object /// </summary> public Object target;

/// <summary> /// The source. /// </summary> public GameObject source;

/// <summary> /// The trigger count. /// </summary> public int triggerCount = 1;

/// <summary> /// The repeat trigger. /// </summary> public bool repeatTrigger = false;

/// <summary> /// The message. /// </summary> public string message = "DoActivateTrigger";

/// <summary> /// The run on trigger flag /// </summary> public bool runOnTrigger = true;

/// <summary> /// The run on collision flag /// </summary> public bool runOnCollision = false;

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox