home *** CD-ROM | disk | FTP | other *** search
/ Game Programming in C++ - Start to Finish / GameProgrammingS.iso / developer_install / ReplicaNetFreewareV5_4.exe / data1.cab / Program_Executable_Files / Example1 / Plane.h < prev    next >
Encoding:
C/C++ Source or Header  |  2005-10-30  |  1.3 KB  |  72 lines

  1. /* START_LICENSE_HEADER
  2.  
  3. Copyright (C) 2000 Martin Piper, original design and program code
  4. Copyright (C) 2001-2005 Replica Software
  5.  
  6. This program file is copyright (C) Replica Software and can only be used under license.
  7. For more information visit: http://www.replicanet.com/
  8. Or email: info@replicanet.com
  9.  
  10. END_LICENSE_HEADER */
  11. /*
  12. See Plane.cpp
  13. */
  14. #ifndef __PLANE_H__
  15. #define __PLANE_H__
  16.  
  17. #include "d3dfile.h"
  18.  
  19. #include "GameObject.h"
  20. #include "Shadow.h"
  21.  
  22. #include "_RO_Plane.h"
  23.  
  24. class Plane : _RO_DO_PUBLIC_RO(Plane) , public GameObject
  25. {
  26. public:
  27.     Plane();
  28.     virtual ~Plane();
  29.  
  30.     void Render(void);
  31.  
  32.     void PollIt(void);
  33.  
  34.     D3DXVECTOR4 GetPosition(void)
  35.     {
  36.         return mPosition;
  37.     }
  38.  
  39.     void SetPosition(D3DXVECTOR4 position)
  40.     {
  41.         mPosition = position;
  42.     }
  43.  
  44.     D3DXVECTOR4 GetRotation(void)
  45.     {
  46.         return mRotation;
  47.     }
  48.  
  49.     CD3DMesh *mMesh;
  50.     ShadowVolume *mShadow;
  51.     D3DXMATRIX    m_matObjectMatrix;
  52.  
  53.     float CalculateDistanceToObject(RNReplicaNet::ReplicaObject *object);
  54.  
  55.     bool ApproveFault(void);
  56.  
  57.     void OwnerChange(void);
  58.  
  59. /* These variables are defined in the ROL file for this object */
  60. private:
  61. _RO_DO_ALLOW_FRIEND_RO(Plane);
  62.     D3DXVECTOR4 mPosition;
  63.     D3DXVECTOR4 mRotation;
  64.  
  65.     int mPlayerNumber;
  66.     int mPlayerColour;
  67.     float mPlayerEnergy;
  68.  
  69. };
  70.  
  71. #endif
  72.