Esempio n. 1
0
    protected override void OnAddingEffect( )
    {
        LastingShootTarget slow = m_action.iceballPrefab.GetComponent <LastingShootTarget>();

        slow.time = m_time;
        slow.d    = m_slowRate;
    }
Esempio n. 2
0
    public void OnTriggerEnter(Collider collider)
    {
        if (isFirst && collider.transform.GetInstanceID() == m_shoot.target.GetInstanceID())
        {
            // reset it for next usage
            isFirst = false;
            targets = PlayerData.GetInstance().action.targets;
            for (int i = 0; i < targets.Count; i++)
            {
                // a enemy that has been attacked by a fire ball will not be attacked by a splited fire ball
                if (targets[i].GetInstanceID() == collider.gameObject.GetInstanceID())
                {
                    continue;
                }

                // split this orbs
                GameObject         orb   = PoolManager.GetInstance().GetPool(name).GetObject(transform.position);
                LastingShootTarget shoot = orb.GetComponent <LastingShootTarget>();
                shoot.target = targets[i].transform;
                shoot.sizeY  = targets[i].GetComponent <Collider>().bounds.size.y / 2;
                shoot.atk    = PlayerData.GetInstance().GetAttributeValue(GameCode.BasicAttributeName.Intelligence) + m_shoot.atk / targets.Count;

                SplitFireBall split = orb.GetComponent <SplitFireBall>();
                split.isFirst = false;
            }
        }
    }
Esempio n. 3
0
    protected override void OnAddingEffect( )
    {
        LastingShootTarget firingEffect = m_action.fireballPrefab.GetComponent <LastingShootTarget>();

        firingEffect.time = m_time;
        firingEffect.d    = m_atk;
    }
Esempio n. 4
0
    protected override void OnAddingEffect( )
    {
        orbsType = fuckRPGLib.GameCode.OrbsType.SlowDown;
        LastingShootTarget sst = m_action.orbsPrefabs[(int)GameCode.OrbsType.SlowDown].GetComponent <LastingShootTarget>();

        sst.time = m_duration;
        sst.d    = m_slowDownRate;
    }