void OnEnable() { powerupController = GetComponent <IPowerupController>(); if (powerupController == null) { Debug.LogError("Power up controller not found"); } input = new MovementController.PlayerInput(); }
public void Start() { powerupController = GameObject.FindGameObjectWithTag("GameController").GetComponent <IPowerupController>(); if (powerupController == null) { Debug.LogError("Powerup controller not found"); } playerId = GetComponent <PlayerScore>().playerId; }
//ENDOF private variables //MonoBehaviour lifecycle public void Awake() { instance = this; }