Пример #1
0
    private void Start()
    {
        playerTransform = LocalPlayerReferences.playerTransform;
        teleportation   = LocalPlayerReferences.player.teleportation;

        // Load cast range from config
        castRange = AbilityDataCache.GetAbilityCastRange("Blink");
    }
Пример #2
0
    void Awake()
    {
        id = GetComponentInParent <PhotonView>().ViewID;

        SetComponentIDs();

        // Load stats from config file
        stats = PlayerDataLoader.Load();
        interactionManager = GetComponentInParent <InteractionManager>();
        shield             = GetComponentInChildren <Shield>();
        rushAreaManager    = GetComponentInChildren <StateManager>();
        rigidBody          = GetComponent <Rigidbody2D>();
        playerCollider     = GetComponent <Collider2D>();
        teleportation      = GetComponent <PlayerTeleportation>();
        //buffsUI = GetComponentInChildren<PlayerBuffs>();

        healEffectActive = false;
        isRecevingDOT    = false;

        manaCoroutineCallsPerSecond = 5;
        manaChargePerTick           = (int)(stats.manaChargePerSecond / manaCoroutineCallsPerSecond);

        baseSpeed = stats.speed;
    }