5 reference
float start_rotation;
7 protected string m_BarHider;
8 protected string m_BarPart;
11 protected float x, y, z;
12 protected float rotation = 0;
13 protected int stage = 0;
28 void SetProgress(
float progress )
34 rotation = 360 * ( progress / 100 );
38 protected void Update(
float tDelta)
47 UpdateChild( child, index );
49 child = child.GetSibling();
53 protected void UpdateChild(
Widget child,
int index )
55 float rotation_value = ( m_Anim.GetTargetValue() *
Math.RAD2DEG );
56 if( child.GetName() == m_BarHider )
62 child.GetChildren().Show(
true);
66 child.GetChildren().Show(
false);
69 child.GetChildren().SetRotation( 0, 0, start_rotation + rotation);
74 child.GetChildren().SetRotation(0, 0, 360);
79 else if( child.GetName() == m_BarPart )
86 child.SetRotation( 0, 0, start_rotation + rotation );
91 child.SetRotation( 0, 0, 180 );
98 void OnWidgetScriptInit(
Widget w )
101 m_BarHider =
"BarHider_" +
m_Root.GetName();
102 m_BarPart =
"BarPart2_" +
m_Root.GetName();
103 m_Anim.AnimateLoop( speed );