Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2016
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.27 KB | None | 0 0
  1. using UnityEngine;
  2. using Makinom;
  3. using System.Collections.Generic;
  4.  
  5. namespace Makinom.Schematics.Nodes
  6. {
  7.     // INFO: The 'EditorHelp' attribute manages the name and description of the node.
  8.     [EditorHelp("ChangeAnimationStateNode", "Changes the animation state.", "")]
  9.     // INFO: The 'NodeInfo' attribute manages in which section the node can be found in the add node selection.
  10.     [NodeInfo("Custom")]
  11.     public class NewSchematicNode : BaseSchematicNode
  12.     {
  13.         // INFO: Place your settings here.
  14.        
  15.         public NewSchematicNode()
  16.         {
  17.            
  18.         }
  19.        
  20.         // INFO: This code will be executed when the node is executed.
  21.         public override void Execute(Schematic schematic)
  22.         {
  23.                
  24.                
  25.                
  26.                 targetObject = GameObject.Find("Illyia_Prefab(Clone)");
  27.                 targetObject.GetComponent<Character>().ForceAnimation("CROUCH",3.0f);
  28.            
  29.            
  30.            
  31.            
  32.            
  33.             // INFO: Don't forget the schematic what to do next.
  34.             schematic.NodeFinished(this.next);
  35.         }
  36.        
  37.        
  38.         // INFO: This returns the text displayed in the node's info area.
  39.         public override string GetNodeDetails()
  40.         {
  41.             return "Node info text";
  42.         }
  43.        
  44.         // INFO: This property handles the color of your node in the node editor.
  45.         public override Color EditorColor
  46.         {
  47.             get{ return Maki.EditorSettings.baseNodeColor;}
  48.         }
  49.     }
  50. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement