|
|
@@ -52,6 +52,10 @@ public class WavePowerSkill : MonoBehaviour
|
|
|
|
|
|
private void Update()
|
|
|
{
|
|
|
+ if (pc.isDie)
|
|
|
+ {
|
|
|
+ ActiveFalse();
|
|
|
+ }
|
|
|
if (curLength < maxLength)
|
|
|
{
|
|
|
curLength += longSpeed * Time.deltaTime;
|
|
|
@@ -62,16 +66,21 @@ public class WavePowerSkill : MonoBehaviour
|
|
|
continueTime -= Time.deltaTime;
|
|
|
if (continueTime <= 0)
|
|
|
{
|
|
|
- pc.conductCanRelease[cacheID] = true;
|
|
|
- pc.canMove = true;
|
|
|
- pc.rb.constraints = RigidbodyConstraints.FreezeRotation | RigidbodyConstraints.FreezePositionZ;
|
|
|
- pc.rb.useGravity = true;
|
|
|
- gameObject.SetActive(false);
|
|
|
+ ActiveFalse();
|
|
|
}
|
|
|
}
|
|
|
AttackMode();
|
|
|
}
|
|
|
|
|
|
+ public void ActiveFalse()
|
|
|
+ {
|
|
|
+ pc.conductCanRelease[cacheID] = true;
|
|
|
+ pc.canMove = true;
|
|
|
+ pc.rb.constraints = RigidbodyConstraints.FreezeRotation | RigidbodyConstraints.FreezePositionZ;
|
|
|
+ pc.rb.useGravity = true;
|
|
|
+ gameObject.SetActive(false);
|
|
|
+ }
|
|
|
+
|
|
|
private void AttackMode()
|
|
|
{
|
|
|
switch (curMode)
|