public void SimulateMove(NgEnum.AXIS nTransAxis, float fHalfDist, float fSpeed, bool bRotFront)
	{
		Vector3	pos	= transform.position;
		m_nAxis		= nTransAxis;
		m_StartPos	= pos;
		m_EndPos	= pos;
		m_StartPos[(int)m_nAxis]	-= fHalfDist;
		m_EndPos[(int)m_nAxis]		+= fHalfDist;
		m_fDist		= Vector3.Distance(m_StartPos, m_EndPos);
		m_Mode		= MODE_TYPE.MOVE;
		SimulateStart(m_StartPos, fSpeed, bRotFront);
	}
Exemple #2
0
    public static GUIContent[] GetHcEffectControls_Trans(NgEnum.AXIS nTransAxis)
    {
        if (HcEffectControls_Transs == null || HcEffectControls_Transs_nTransAxis != nTransAxis)
        {
            CheckValid(HcEffectControls_Trans);
            HcEffectControls_Transs = new GUIContent[8];
            HcEffectControls_Transs_nTransAxis = nTransAxis;
            GUIContent[]	cons = HcEffectControls_Transs;

            cons[0]	= GetGUIContent("Stop"		, HcEffectControls_Trans[GetLang(), 0] + AddHintRect(FXMakerLayout.GetClientRect));
            cons[1]	= GetGUIContent(nTransAxis.ToString() + " Move"	, "- " + string.Format(HcEffectControls_Trans[GetLang(), 1], nTransAxis.ToString()) + AddHintRect(FXMakerLayout.GetClientRect));
            cons[2]	= GetGUIContent(nTransAxis.ToString() + " Scale"	, "- " + string.Format(HcEffectControls_Trans[GetLang(), 2], nTransAxis.ToString())+ AddHintRect(FXMakerLayout.GetClientRect));
            cons[3]	= GetGUIContent("Arc"		, HcEffectControls_Trans[GetLang(), 3]	+ AddHintRect(FXMakerLayout.GetClientRect));
            cons[4]	= GetGUIContent("Fall"		, HcEffectControls_Trans[GetLang(), 4]	+ AddHintRect(FXMakerLayout.GetClientRect));
            cons[5]	= GetGUIContent("Raise"		, HcEffectControls_Trans[GetLang(), 5]	+ AddHintRect(FXMakerLayout.GetClientRect));
            cons[6]	= GetGUIContent("Circle"	, HcEffectControls_Trans[GetLang(), 6]	+ AddHintRect(FXMakerLayout.GetClientRect));
            cons[7]	= GetGUIContent("Tornado"	, HcEffectControls_Trans[GetLang(), 7]	+ AddHintRect(FXMakerLayout.GetClientRect));
        }
        return HcEffectControls_Transs;
    }