本文整理汇总了C#中Tweener.Pause方法的典型用法代码示例。如果您正苦于以下问题:C# Tweener.Pause方法的具体用法?C# Tweener.Pause怎么用?C# Tweener.Pause使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Tweener
的用法示例。
在下文中一共展示了Tweener.Pause方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Awake
// Use this for initialization
protected virtual void Awake()
{
tweener = SetupTween();
tweener.SetEase(easeType);
tweener.SetAutoKill(false);
tweener.Pause();
}
示例2: OnClick
void OnClick(){
if( Time.timeSinceLevelLoad> 0.1f ){
if( State == 0 ){
SettingsTween = HOTween.To(Menü, 0.5f, new TweenParms().AutoKill(false)
.Prop("position",MenüPos, true) // Position tween (set as relative)
.Ease(EaseType.EaseInOutQuad) // Ease
);
SettingsTween.Pause ();
TweenSlider.ShowMenue = name;
SettingsTween.PlayForward ();
OldIcon = Icon.GetComponent<UISprite>().spriteName;
Icon.GetComponent<UISprite>().spriteName = "ArrowBack";
Icon.GetComponent<UIButton>().normalSprite = "ArrowBack";
Icon.transform.localScale = Icon.transform.localScale/1.2f;
transform.Rotate(0,0,-90);
Menü.GetComponent<AudioSource>().Play();
State = 1;
}else if (State == 1){
TweenSlider.ShowMenue = null;
SettingsTween.PlayBackwards ();
Icon.GetComponent<UISprite>().spriteName = OldIcon;
Icon.GetComponent<UIButton>().normalSprite = OldIcon;
Icon.transform.localScale = Icon.transform.localScale*1.2f;
transform.Rotate(0,0,90);
Menü.GetComponent<AudioSource>().Play();
State = 0;
}
}
}
示例3: Update
// Use this for initialization
// Update is called once per frame
void Update () {
if( Time.timeSinceLevelLoad> 0.1f){
if(!scriptLoaded){
scriptLoaded = true;
ShowMenue = null;
BackTween = HOTween.To(Slider, 0.5f, new TweenParms().AutoKill(false)
.Prop("position",BackPos, true) // Position tween (set as relative)
.Ease(EaseType.EaseInOutQuad) // Ease
);
BackTween.PlayForward ();
Stage = 1;
HoverTween = HOTween.To(Slider, 0.1f, new TweenParms().AutoKill(false)
.Prop("position",HoverPos, true) // Position tween (set as relative)
.Ease(EaseType.EaseInOutQuad) // Ease
);
HoverTween.Pause ();
ClickTween = HOTween.To(Slider, 0.5f, new TweenParms().AutoKill(false)
.Prop("position",ClickedPos, true) // Position tween (set as relative)
.Ease(EaseType.EaseInOutQuad) // Ease
);
ClickTween.Pause ();
MenueTween = HOTween.To(Menue, 0.8f, new TweenParms().AutoKill(false)
.Prop("position",MenuePos, true) // Position tween (set as relative)
.Ease(EaseType.EaseInOutQuad) // Ease
);
MenueTween.Pause ();
}
if (ShowMenue != null && ShowMenue != name && Stage == 1) {
BackTween.PlayBackwards();
Stage = 0;
}
if (ShowMenue == null && Stage == 0) {
BackTween.PlayForward();
Slideeffect.getSlided = false;
Stage = 1;
}
if (ShowMenue != null && Stage == 2 && ShowMenue != name ){
MenueTween.PlayBackwards();
ClickTween.PlayBackwards();
StartCoroutine(ShowSettings());
GetComponent<AudioSource>().Play();
Icon.GetComponent<UISprite>().spriteName = OldIcon;
OldIcon = null;
Slideeffect.getSlided = false;
Stage = 0;
}
}
}