Ejemplo n.º 1
0
    // Start is called before the first frame update
    void Start()
    {
        rb2d            = GetComponent <Rigidbody2D>();
        spriteRenderers = GetComponentsInChildren <SpriteRenderer>();
        animators       = GetComponentsInChildren <Animator>();
        playerCollider  = GetComponent <Collider2D>();

        gameManager      = FindObjectOfType <GameManager>();
        musicManager     = FindObjectOfType <MusicManager>();
        narrationManager = FindObjectOfType <NarrationManager>();
        batteryBank      = FindObjectOfType <BatteryBank>();
        lightSystem      = FindObjectOfType <LightSystem>();
    }
Ejemplo n.º 2
0
 // Start is called before the first frame update
 void Start()
 {
     Instructions.enabled = false;
     musicManager         = FindObjectOfType <MusicManager>();
     GameState            = GameState.Introduction;
     player               = FindObjectOfType <PlayerController>();
     lightSystem          = FindObjectOfType <LightSystem>();
     batteryBank          = FindObjectOfType <BatteryBank>();
     blackImage.enabled   = false;
     winText.enabled      = false;
     gameOverText.enabled = false;
     playAgain.enabled    = false;
 }
Ejemplo n.º 3
0
 // Start is called before the first frame update
 void Start()
 {
     batteryBank     = FindObjectOfType <BatteryBank>();
     audioSource     = GetComponent <AudioSource>();
     spriteRenderers = GetComponentsInChildren <SpriteRenderer>();
 }