コード例 #1
0
    // Start is called before the first frame update
    void Awake()
    {
        //objectPooler = ObjectPooler.Instance;
        //bfs = GameObject.Find("BattlefieldMaster").GetComponent<BattlefieldScript>();
        //bfs.playerPosition = new Vector2(transform.position.x, transform.position.y);

        anim          = GetComponent <Animator>();
        status        = GetComponent <EntityStatus>();
        emotionAnim   = GameObject.Find("PlayerEmotionSprite").GetComponent <Animator>();
        canvasAnim    = GameObject.Find("Canvas").GetComponent <Animator>();
        firstButton   = GameObject.Find("Slot1");
        turnBarScript = GameObject.Find("TurnBar").GetComponent <TurnBarScript>();
        cardHolder    = GameObject.Find("PlayerCanvas").GetComponent <CardHolder>();

        Instance = this;
    }
コード例 #2
0
    // Start is called before the first frame update
    void Start()
    {
        inkTypewriterText  = GameObject.Find("DialogueCanvas").GetComponent <InkTypewriterText>();
        playerAchievements = GameObject.Find("PlayerStats").GetComponent <PlayerAchievements>();
        turnBarScript      = GameObject.Find("TurnBar").GetComponent <TurnBarScript>();

        turnBarScript.SpeedModifier = 0;

        dodgeInitial = playerAchievements.ConsecutiveProjectilesDodged;



        FindObjectOfType <PlayerScript>().moveEvent += OnPlayerMove;
        objectPooler = ObjectPooler.Instance;

        GameObject.Find("PlayerCombat").GetComponent <EntityStatus>().StatusEffects.Add(StatusEffect.Endure);

        StartCoroutine(LateStart());
    }