コード例 #1
0
    void Start()
    {
        abilityIconController = AbilityIconController.instance;
        rangeCollider         = GetComponentInChildren <RangeCollider>();

        maxUnitCount = units.Count;

        AssignUnitPositions();
        AssignLeaderPosition();
    }
コード例 #2
0
    void Start()
    {
        health        = GetComponent <Health>();
        rangeCollider = GetComponentInChildren <RangeCollider>();
        TryGetComponent <Shooter>(out myShooter);

        audioManager = AudioManager.instance;
        anim         = GetComponent <Animator>();
        castleHealth = CastleHealth.instance;
        sr           = transform.GetComponentInChildren <SpriteRenderer>();

        startingBluntDamage    = bluntDamage;
        startingSlashDamage    = slashDamage;
        startingPiercingDamage = piercingDamage;
        startingFireDamage     = fireDamage;

        StartCoroutine(Movement());
    }