public override void BindEntity(Entity *entityPtr)
 {
     if (entityPtr == null)
     {
         throw new Exception("BindViewError: EntityPtr should not be null");
     }
     _ptr         = (PlayerCube *)entityPtr;
     _cloneEntity = *_ptr;
     _Instance    = this;
 }
Esempio n. 2
0
 private int _GetOffsetOfPlayerCube_Move()
 {
     var tempObj = new PlayerCube(); PlayerCube *ptr = &tempObj; var filedPtr = &(ptr->Move);  return((int)((long)filedPtr - (long)ptr));
 }
 public override void DoUpdate(float deltaTime)
 {
     _cloneEntity = *_ptr;
     UpdatePosRot(ref _cloneEntity.Transform);
 }