mirror of
https://github.com/MaddyThorson/StrawberryBF.git
synced 2025-07-06 20:45:26 +08:00
Grid out of bounds checks snap into bounds. RemoveSelf->Destroy
This commit is contained in:
@ -33,7 +33,7 @@ namespace Strawberry
|
||||
value = 0;
|
||||
OnComplete?.Invoke();
|
||||
if (RemoveOnComplete)
|
||||
RemoveSelf();
|
||||
Entity.Remove(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ namespace Strawberry
|
||||
public Ease.Easer Easer ~ delete _;
|
||||
public delegate void(float) OnUpdate ~ delete _;
|
||||
public delegate void() OnComplete ~ delete _;
|
||||
public bool RemoveOnComplete;
|
||||
public bool DestroyOnComplete;
|
||||
|
||||
public bool Playing { get; private set; }
|
||||
public float T { get; private set; }
|
||||
@ -17,7 +17,7 @@ namespace Strawberry
|
||||
Easer = easer;
|
||||
OnUpdate = onUpdate;
|
||||
OnComplete = onComplete;
|
||||
RemoveOnComplete = removeOnComplete;
|
||||
DestroyOnComplete = removeOnComplete;
|
||||
}
|
||||
|
||||
[Inline]
|
||||
@ -45,8 +45,8 @@ namespace Strawberry
|
||||
{
|
||||
OnComplete?.Invoke();
|
||||
Playing = false;
|
||||
if (RemoveOnComplete)
|
||||
RemoveSelf();
|
||||
if (DestroyOnComplete)
|
||||
Destroy();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user