mirror of
https://github.com/Cardidi/dotween-upm-fork.git
synced 2025-12-21 01:36:05 +08:00
Added screenshots
This commit is contained in:
parent
fd1cb57ddd
commit
19e2b30586
@ -1,7 +1,10 @@
|
|||||||
# dotween
|
# dotween
|
||||||
|
|
||||||
A Unity C# animation engine. HOTween v2
|
A Unity C# animation engine. HOTween v2
|
||||||
|
|
||||||
Developed by Daniele Giardini - http://www.demigiant.com
|
Developed by Daniele Giardini - http://www.demigiant.com
|
||||||
|
|
||||||
Check the docs on DOTween's website - http://dotween.demigiant.com
|
Check the docs on DOTween's website - http://dotween.demigiant.com
|
||||||
|
|
||||||
|

|
||||||
|

|
||||||
|

|
||||||
@ -53,7 +53,6 @@ public class CustomRangePlugin : ABSTweenPlugin<CustomRange, CustomRange, NoOpti
|
|||||||
// Calculates the value based on the given time and ease
|
// Calculates the value based on the given time and ease
|
||||||
public override void EvaluateAndApply(NoOptions options, Tween t, bool isRelative, DOGetter<CustomRange> getter, DOSetter<CustomRange> setter, float elapsed, CustomRange startValue, CustomRange changeValue, float duration, bool usingInversePosition, UpdateNotice updateNotice)
|
public override void EvaluateAndApply(NoOptions options, Tween t, bool isRelative, DOGetter<CustomRange> getter, DOSetter<CustomRange> setter, float elapsed, CustomRange startValue, CustomRange changeValue, float duration, bool usingInversePosition, UpdateNotice updateNotice)
|
||||||
{
|
{
|
||||||
CustomRange res = getter();
|
|
||||||
float easeVal = EaseManager.Evaluate(t, elapsed, duration, t.easeOvershootOrAmplitude, t.easePeriod);
|
float easeVal = EaseManager.Evaluate(t, elapsed, duration, t.easeOvershootOrAmplitude, t.easePeriod);
|
||||||
|
|
||||||
// Here I use startValue directly because CustomRange a struct, so it won't reference the original.
|
// Here I use startValue directly because CustomRange a struct, so it won't reference the original.
|
||||||
|
|||||||
@ -13,56 +13,8 @@ public class TempTests : BrainBase
|
|||||||
|
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
DOTween.Init();
|
DOTween.Sequence().SetDelay(2)
|
||||||
PlayTween();
|
// .AppendInterval(2)
|
||||||
}
|
.Append(rectTrans.DOAnchorPosX(100, 1).SetRelative());
|
||||||
|
|
||||||
Sequence mySequence;
|
|
||||||
|
|
||||||
Tween anchorMinTween = null;
|
|
||||||
Tween anchorMaxTween = null;
|
|
||||||
Tween anchorPositionTween = null;
|
|
||||||
Tween scaleTween = null;
|
|
||||||
|
|
||||||
void PlayTween()
|
|
||||||
{
|
|
||||||
mySequence = DOTween.Sequence();
|
|
||||||
|
|
||||||
anchorMaxTween = DOTween.To(() => rectTrans.anchorMax, v => rectTrans.anchorMax = v, new Vector2(0.5f, 0.5f), 1f)
|
|
||||||
// .Pause()
|
|
||||||
.SetDelay(2f)
|
|
||||||
.OnPlay(()=> Debug.Log(Time.realtimeSinceStartup + " Start MAX"))
|
|
||||||
;
|
|
||||||
|
|
||||||
anchorMinTween = DOTween.To(() => rectTrans.anchorMin, v => rectTrans.anchorMin = v, new Vector2(0.5f, 0.5f), 1f)
|
|
||||||
// .Pause()
|
|
||||||
.SetDelay(2f)
|
|
||||||
.OnPlay(() => Debug.Log(Time.realtimeSinceStartup + " Start MIN"))
|
|
||||||
;
|
|
||||||
|
|
||||||
anchorPositionTween = DOTween.To(() => rectTrans.anchoredPosition, v => rectTrans.anchoredPosition = v, Vector2.zero, 1f)
|
|
||||||
//.Pause()
|
|
||||||
.SetDelay(2f)
|
|
||||||
.OnPlay(() => Debug.Log(Time.realtimeSinceStartup + " Start POS"))
|
|
||||||
;
|
|
||||||
|
|
||||||
scaleTween = DOTween.To(() => rectTrans.localScale, v => rectTrans.localScale = v, Vector3.zero, 1f)
|
|
||||||
//.Pause()
|
|
||||||
.SetDelay(2f)
|
|
||||||
.OnPlay(() => Debug.Log(Time.realtimeSinceStartup + " Start SCALE"))
|
|
||||||
;
|
|
||||||
|
|
||||||
mySequence
|
|
||||||
.AppendInterval(5f)
|
|
||||||
.Append(anchorMaxTween)
|
|
||||||
.Join(anchorMinTween)
|
|
||||||
.Join(anchorPositionTween)
|
|
||||||
.AppendInterval(2f)
|
|
||||||
.Append(scaleTween)
|
|
||||||
//.SetDelay(2f)
|
|
||||||
//.Play()
|
|
||||||
.Pause()
|
|
||||||
.OnPlay(()=> Debug.Log(Time.realtimeSinceStartup + " >>> PLAY"))
|
|
||||||
;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
BIN
screenshots/splash_dotween.png
Normal file
BIN
screenshots/splash_dotween.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 50 KiB |
BIN
screenshots/splash_lambda.png
Normal file
BIN
screenshots/splash_lambda.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 28 KiB |
BIN
screenshots/splash_shortcuts.png
Normal file
BIN
screenshots/splash_shortcuts.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 13 KiB |
Loading…
x
Reference in New Issue
Block a user