public void Start() { animator = GetComponent <TinkerAnimator>(); at_t = 0; aiBehaviour = SeekPlayer; //target = GameObject.FindWithTag("Player"); }
public void LoadModelGear(SerializedItemData idObj, TinkerAnimator modelPart) { ItemDatabase db = GameManager.instance.itemDatabase; if (idObj != null) { if (idObj.itemID != -1) { modelPart.animations[(int)ANIMATIONS.IDLE] = ((Armour)db.items[idObj.itemID]).idle; } else { modelPart.animations[(int)ANIMATIONS.IDLE] = null; } if (idObj.itemID != -1) { modelPart.animations[(int)ANIMATIONS.RUN] = ((Armour)db.items[idObj.itemID]).run; } else { modelPart.animations[(int)ANIMATIONS.RUN] = null; } } }
void Start() { animator = GetComponent <TinkerAnimator> (); rb = GetComponent <Rigidbody2D> (); bullet = Resources.Load("Prefabs/Bullet") as GameObject; // To deprecate swingSpeed = swingForce; finalSpeed = speed; }
public override void Start() { base.Start(); moveSpeed = speed.GetTotal(); animator = GetComponent <TinkerAnimator> (); rb = GetComponent <Rigidbody2D> (); bullet = Resources.Load("Prefabs/Bullet") as GameObject; // To deprecate swingSpeed = weapon.stepForce; finalSpeed = moveSpeed; }
public void LoadModelGear(Armour idObj, TinkerAnimator modelPart) { ItemDatabase db = GameManager.instance.itemDatabase; if (idObj != null) { modelPart.animations[(int)ANIMATIONS.IDLE] = (idObj).idle; modelPart.animations[(int)ANIMATIONS.RUN] = (idObj).run; } else { modelPart.animations[(int)ANIMATIONS.IDLE] = null; modelPart.animations[(int)ANIMATIONS.RUN] = null; } }
// Use this for initialization void Start () { t = 0; currentRoom = Dungeon.instance.dungeon_rooms[0]; animator = GetComponentInChildren<TinkerAnimator>(); cam = Camera.main; }