void Start() { EnterFreeState(); playerMovement = GetComponent <PLAYER_movement_directional_2d> (); playerInteraction = GetComponent <PLAYER_interaction> (); playerAnimation = GetComponent <PLAYER_animation> (); }
// Constructor: public PLAYER_STATE_Menu(GameObject player) { playerObject = player; movementScript = playerObject.GetComponent <PLAYER_movement_directional_2d>(); }
// Constructor: public PLAYER_STATE_FreeControl(GameObject player) { playerObject = player; movementScript = playerObject.GetComponent <PLAYER_movement_directional_2d>(); interactionScript = playerObject.GetComponent <PLAYER_interaction>(); }