示例#1
0
        public override void OnAdd()
        {
            m_SelfTransform = behavior.transform;
            TarVSpeed       = -behavior.MaxFallSpeed;
            m_AnimComp      = behavior.GetEntityComp <AnimComp>() as AnimComp;
            m_InputComp     = behavior.GetEntityComp <InputComp>() as InputComp;
            m_RotateComp    = behavior.GetEntityComp <RotateComp>() as RotateComp;

            //0.1s同步一次到服务端
            syncFrame = (int)(Application.targetFrameRate * 0.1f);
        }
示例#2
0
 public override void OnRemove()
 {
     m_AnimComp   = null;
     m_InputComp  = null;
     m_RotateComp = null;
 }
示例#3
0
 public override void OnAdd()
 {
     m_InputComp = behavior.GetEntityComp <InputComp>() as InputComp;
 }