当前位置: 首页>>代码示例>>C#>>正文


C# EaseType.ToString方法代码示例

本文整理汇总了C#中EaseType.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# EaseType.ToString方法的具体用法?C# EaseType.ToString怎么用?C# EaseType.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在EaseType的用法示例。


在下文中一共展示了EaseType.ToString方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: MoveTo

    static void MoveTo(GameObject target, Vector3[] nodes, float time, EaseType easyType, bool firstNode, 
		string updateFuncName, string complateFuncName, GameObject funcTarget, object param)
    {
        if( null != target &&
            firstNode &&
            null != nodes &&
            nodes.Length > 0 )
        {
            target.transform.localPosition = nodes[0];
        }

        Hashtable args = iTween.Hash("path", nodes, "time", time, "easetype", easyType.ToString());
        if(null != updateFuncName)
        {
            args["onupdate"] = updateFuncName;
            if(null != param)
            {
                args["onupdateparams"] = param;
            }
            if(null != funcTarget) args["onupdatetarget"] = funcTarget;
        }
        if(null != complateFuncName)
        {
            args["oncomplete"] = complateFuncName;
            if(null != param)
            {
                args["oncompleteparams"] = param;
            }
            if(null != funcTarget) args["oncompletetarget"] = funcTarget;
        }

        iTween.MoveTo(target, args);
    }
开发者ID:hismile06jf,项目名称:sgqy8,代码行数:33,代码来源:iTweenExt.cs

示例2: InFactor

		/// <summary>
		/// Provides an ease-in factor for the given animation progress.
		/// </summary>
		/// <param name="progress"> The fractional progress of the animation (from 0 to 1). </param>
		/// <param name="type"> The type of easing to perform. </param>
		/// <returns> The factor to use in the animation. </returns>
		public static double InFactor(double progress, EaseType type)
		{
			switch (type)
			{
			case EaseType.Linear:
				return progress;
			case EaseType.Quadratic:
				return progress * progress;
			case EaseType.Cubic:
				return progress * progress * progress;
			}
			throw new NotImplementedException("Don't know how to ease in for " + type.ToString());
		}
开发者ID:erisonliang,项目名称:monoworks,代码行数:19,代码来源:Ease.cs

示例3: RotateAdd

	/// <summary>
	/// Adds supplied Euler angles in degrees to a GameObject's rotation over time.
	/// </summary>
	/// <param name="amount">
	/// A <see cref="Vector3"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easetype">
	/// A <see cref="EaseType"/>
	/// </param> 
	/// <param name="looptype">
	/// A <see cref="LoopType"/>
	/// </param>
	public static void RotateAdd(this GameObject go,Vector3 amount,float time,float delay,EaseType easeType,LoopType loopType){
		iTween.RotateAdd(go,iTween.Hash("amount",amount,"time",time,"delay",delay,"easeType",easeType.ToString(),"looptype",loopType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:21,代码来源:iTweenExtensions.cs

示例4: MoveTo

	/// <summary>
	/// Changes a GameObject's position over time along a supplied path.
	/// </summary>
	/// <param name="go">
	/// A <see cref="GameObject"/>
	/// </param>
	/// <param name="path">
	/// A <see cref="Transform[]"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easeType">
	/// A <see cref="EaseType"/>
	/// </param>
	/// <param name="loopType">
	/// A <see cref="LoopType"/>
	/// </param>
	public static void MoveTo(this GameObject go,Transform[] path,float time,float delay,EaseType easeType,LoopType loopType){
		iTween.MoveTo(go,iTween.Hash("path",path,"time",time,"delay",delay,"easeType",easeType.ToString(),"looptype",loopType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:24,代码来源:iTweenExtensions.cs

示例5: MoveBy

	/// <summary>
	/// Adds the supplied coordinates to a GameObject's position.
	/// </summary>
	/// <param name="amount">
	/// A <see cref="Vector3"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easeType">
	/// A <see cref="EaseType"/>
	/// </param>
	public static void MoveBy(this GameObject go,Vector3 amount,float time,float delay,EaseType easeType){
		iTween.MoveBy(go,iTween.Hash("amount",amount,"time",time,"delay",delay,"easeType",easeType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:18,代码来源:iTweenExtensions.cs

示例6: LookTo

	/// <summary>
	/// Rotates a GameObject to look at the supplied Vector3 over time.
	/// </summary>
	/// <param name="lookTarget">
	/// A <see cref="Vector3"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easeType">
	/// A <see cref="EaseType"/>
	/// </param>
	/// <param name="loopType">
	/// A <see cref="LoopType"/>
	/// </param>
	public static void LookTo(this GameObject go,Vector3 lookTarget,float time,float delay,EaseType easeType,LoopType loopType){
		iTween.LookTo(go,iTween.Hash("lookTarget",lookTarget,"time",time,"delay",delay,"easeType",easeType.ToString(),"looptype",loopType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:21,代码来源:iTweenExtensions.cs

示例7: ScaleTo

	/// <summary>
	/// Changes a GameObject's scale over time.
	/// </summary>
	/// <param name="scale">
	/// A <see cref="Vector3"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easeType">
	/// A <see cref="EaseType"/>
	/// </param>
	/// <param name="loopType">
	/// A <see cref="LoopType"/>
	/// </param>
	public static void ScaleTo(this GameObject go,Vector3 scale,float time,float delay,EaseType easeType,LoopType loopType){
		iTween.ScaleTo(go,iTween.Hash("scale",scale,"time",time,"delay",delay,"easeType",easeType.ToString(),"looptype",loopType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:21,代码来源:iTweenExtensions.cs

示例8: RotateTo

	/// <summary>
	/// Rotates a GameObject to the supplied Euler angles in degrees over time.
	/// </summary>
	/// <param name="amount">
	/// A <see cref="Vector3"/>
	/// </param>
	/// <param name="time">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="delay">
	/// A <see cref="System.Single"/>
	/// </param>
	/// <param name="easeType">
	/// A <see cref="EaseType"/>
	/// </param>
	public static void RotateTo(this GameObject go,Vector3 rotation,float time,float delay,EaseType easeType){
		iTween.RotateTo(go,iTween.Hash("rotation",rotation,"time",time,"delay",delay,"easeType",easeType.ToString()));
	}
开发者ID:qishiyexu,项目名称:gravityball,代码行数:18,代码来源:iTweenExtensions.cs

示例9: MoveTo

 public static void MoveTo(this GameObject go,Vector3 position,float time,
                           float delay,EaseType easeType, string onCompleteCall, GameObject onCompleteGO, Vector3 onCompleteParams)
 {
     iTween.MoveTo(go,iTween.Hash("position",position,"time",time,"delay",delay,"easeType",easeType.ToString(),
                                  "oncomplete", onCompleteCall, "oncompletetarget", onCompleteGO,"oncompleteparams", onCompleteParams));
 }
开发者ID:exdev,项目名称:band-of-warriors,代码行数:6,代码来源:iTweenExtensions.cs

示例10: MoveBy

 //nantas override moveby functions
 public static void MoveBy(this GameObject go,Vector3 amount,float time,float delay,
                           EaseType easeType, string onCompleteCall, GameObject onCompleteGO, Object onCompleteParams )
 {
     iTween.MoveBy(go,iTween.Hash("amount",amount,"time",time, "delay",delay,
                                  "easeType",easeType.ToString(),"oncomplete", onCompleteCall, "oncompletetarget", onCompleteGO,
                                  "oncompleteparams", onCompleteParams));
 }
开发者ID:exdev,项目名称:band-of-warriors,代码行数:8,代码来源:iTweenExtensions.cs

示例11: MoveTo

 public static void MoveTo(this GameObject go, Vector3 position, float time, string OnComplete, GameObject onCompleteTarget, float delay = 0, EaseType easeType = EaseType.linear)
 {
     iTween.MoveTo(go, iTween.Hash("position", position, "time", time, "delay", delay, "easeType", easeType.ToString(), "oncompletetarget", onCompleteTarget, "oncomplete", OnComplete));
 }
开发者ID:kewur,项目名称:HungryDude,代码行数:4,代码来源:iTweenExtensions.cs


注:本文中的EaseType.ToString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。