public IEnumerator IE_ColorChange(float _useTime, float _endValue) { var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; var v0 = (int)MorphingValueType.value; _org[v0] = new ValueData(MorphingTool.GetFloat4(GetMatValue())); _target[v0] = new ValueData(MorphingTool.GetFloat4(_endValue)); yield return(StartCoroutine(MorphingTool._instance.IE_Morphing(this, _org, _target, _useTime))); }
public IEnumerator IE_CamMorphing() { var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; var v0 = (int)MorphingValueType.Position; _org[v0] = new ValueData(MorphingTool.GetFloat4(CamTrans.position)); _target[v0] = new ValueData(MorphingTool.GetFloat4(TargetTrans.position + curRotWithTarget * dirWithTarget * curDisWithTarget)); //var v1 = (int)MorphingValueType.Rotation; //_org[v1] = new ValueData(MorphingTool.GetFloat4(CamTrans.rotation)); //_target[v1] = new ValueData(MorphingTool.GetFloat4(TargetTrans.rotation)); yield return(StartCoroutine(MorphingTool._instance.IE_Morphing(this, _org, _target, camMoveTime))); }
public void Show() { var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; //var _v0 = (int)MorphingValueType.localPosition; //_org[_v0] = new ValueData(MorphingTool.GetFloat4(Vector3.down*10)); //_target[_v0] = new ValueData(MorphingTool.GetFloat4(Trans.localPosition)); var _v1 = (int)MorphingValueType.localScale; _org[_v1] = new ValueData(MorphingTool.GetFloat4(Vector3.zero)); _target[_v1] = new ValueData(MorphingTool.GetFloat4(Vector3.one)); StartCoroutine(MorphingTool._instance.IE_Morphing(this, _org, _target, TileManager._instance.tileShowTime, TileManager._instance.easeInType)); }
public void Hide() { var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; var _v0 = (int)MorphingValueType.localRotation; _org[_v0] = new ValueData(MorphingTool.GetFloat4(Trans.localRotation)); _target[_v0] = new ValueData(MorphingTool.GetFloat4(Quaternion.Euler(0, 0, 0))); var _v1 = (int)MorphingValueType.localScale; _org[_v1] = new ValueData(MorphingTool.GetFloat4(Vector3.one)); _target[_v1] = new ValueData(MorphingTool.GetFloat4(Vector3.zero)); MorphingTool._instance.IE_Morphing(this, _org, _target, TileManager._instance.tileShowTime, TileManager._instance.easeInType); }
//自身被收缩,往中心运动 public IEnumerator IE_MoveIn(float _useTime) { var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; var v0 = (int)MorphingValueType.localPosition; _org[v0] = new ValueData(MorphingTool.GetFloat4(VirTrans.localPosition)); _target[v0] = new ValueData(MorphingTool.GetFloat4(Vector3.zero)); var v1 = (int)MorphingValueType.localScale; _org[v1] = new ValueData(MorphingTool.GetFloat4(Trans.localScale)); _target[v1] = new ValueData(MorphingTool.GetFloat4(Vector3.zero)); yield return(StartCoroutine(MorphingTool._instance.IE_Morphing(this, _org, _target, _useTime))); isMoving = false; }
//自身被展开,往外运动 public IEnumerator IE_MoveOut(float _useTime, Vector3 _dir) { isMoving = true; var _count = Enum.GetValues(typeof(MorphingValueType)).Length; var _org = new ValueData[_count]; var _target = new ValueData[_count]; var v0 = (int)MorphingValueType.localPosition; _org[v0] = new ValueData(MorphingTool.GetFloat4()); _target[v0] = new ValueData(MorphingTool.GetFloat4(_dir)); var v1 = (int)MorphingValueType.localScale; _org[v1] = new ValueData(MorphingTool.GetFloat4(Vector3.zero)); _target[v1] = new ValueData(MorphingTool.GetFloat4(Vector3.one)); var v2 = (int)MorphingValueType.value; _org[v2] = new ValueData(MorphingTool.GetFloat4(GetMatValue())); _target[v2] = new ValueData(MorphingTool.GetFloat4(matLightValue)); yield return(StartCoroutine(MorphingTool._instance.IE_Morphing(this, _org, _target, _useTime))); }