/// <summary> /// Initializes the entity with the references needed. /// </summary> /// <param name="gameManager">The global game manager.</param> /// <param name="lookHandler">The "Camera" transform that this entity uses.</param> public virtual void Init(GameManager gameManager, LookHandler lookHandler, InputControlType controlType) { this.GameManager = gameManager; this.lookHandler = lookHandler; InputManager.SetControllerID(0); InputManager.SetControlType(controlType); }
public void Activate(Entity playerEntity, Entity otherEntity) { CharacterSpriteComponent spriteComp = playerEntity.GetComponent <CharacterSpriteComponent> (); spriteComp.LookAt((Entity)Entity); LookHandler.StartLook(playerEntity, (Entity)Entity); }