/// <summary> /// Sets the extra S. /// </summary> /// <param name="grounds">原點</param> /// <param name="dir">方向</param> /// <param name="idxs">角色編號</param> /// <param name="upInt">上升值</param> public void SetExtraSE(List <GroundController> grounds, Vector3 dir, int idxs, int upInt) { extraLight.SetParabola(grounds [0].transform.localPosition, dir); var eP = extraParticle.main; if (upInt == 25) { eP.startColor = particleColor[1]; } else { eP.startColor = particleColor[0]; } SetLightParent(grounds[0].transform.localPosition, dir); upRatio = upInt; showedCount = 0; showTime = 0; seType = SpecailEffectType.ExtraRatio; charaIdx = idxs; setComplete = true; isRun = false; }
public void SetAttackShow(Vector3 orgPos, Vector3 targetPos, FightItemButton target, DamageData data) { SetLightParent(orgPos, targetPos); damageData = data; callbackTarget = target; tPos = targetPos; seType = SpecailEffectType.Attack; damageLight.SetParabola(orgPos, targetPos); setComplete = true; isRun = false; }
public void SetReverseSE(List <GroundController> grounds, List <Vector3> positions) { showNumber = new List <int> (); plusDamage = 0; seGrounds = grounds; for (int i = 0; i < positions.Count; i++) { ratioTxt [i].gameObject.SetActive(true); ratioTxt [i].transform.localPosition = positions [i]; } foreach (var ground in seGrounds) { if (ground.onShowedFst == null) { ground.onShowedFst = OnShowed; ground.onShowingFst = OnShowing; showNumber.Add(1); } else { if (ground.onShowedSec == null) { ground.onShowedSec = OnShowed; ground.onShowingSec = OnShowing; showNumber.Add(2); } else { ground.onShowedThr = OnShowed; ground.onShowingThr = OnShowing; showNumber.Add(3); } } } showedCount = 0; showTime = 0; seType = SpecailEffectType.Reverse; setComplete = true; isRun = false; }
public void SetDamageShow(DamageData damageData, Vector3 orgPos) { showDamage = 0; plusDamage = damageData.damage; speedRatio = Random.Range(0.5f, 1.2f); plusSpeed = damageData.damage / speedRatio; seType = SpecailEffectType.Damage; showTime = 0.5f; damageTxtIdx = System.Convert.ToInt32(damageData.isCrt); damageTxt[damageTxtIdx].GetComponent <TweenPostion>().SetJump(orgPos, orgPos + Vector3.right * Random.Range(-50, 50), speedRatio); damageTxt [damageTxtIdx].color = Const.attriColor [damageData.attributes]; setComplete = true; isRun = false; isShowDamage = false; }