3 string m_AnimSource =
"";
12 override void CreateConditionComponents()
30 Object targetObject = target.GetObject();
34 targetObject.GetActionComponentNameList(target.GetComponentIndex(), selections);
37 if (
Class.CastTo(car, targetEnt))
39 for (
int i = 0; i < selections.Count(); i++)
41 m_AnimSource = car.GetAnimSourceFromSelection(selections[i]);
42 if (m_AnimSource !=
"")
52 override void OnStartServer(
ActionData action_data)
55 if (
Class.CastTo(targetEnt, action_data.m_Target.GetObject()))
57 if (targetEnt.GetAnimationPhase(m_AnimSource) > 0.5)
59 targetEnt.SetAnimationPhase(m_AnimSource, 0.0);
62 if (targetEnt.GetAnimationPhase(m_AnimSource) <= 0.5)
64 targetEnt.SetAnimationPhase(m_AnimSource, 1.0);
69 if (
Class.CastTo(car, action_data.m_Target.GetObject()))
71 car.ForceUpdateLightsStart();
75 override void OnEndServer(
ActionData action_data )
78 if (
Class.CastTo(car, action_data.m_Target.GetObject()))
80 car.ForceUpdateLightsEnd();