Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 10, 2008, 1:38:17 PM (15 years ago)
Author:
rgrieder
Message:

Trying to synchronise phyiscs over the network.

  • Removed derivation of CollisionShape from WorldEntity (BaseObject instead).
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/physics/src/orxonox/objects/worldentities/ControllableEntity.h

    r2300 r2374  
    3333
    3434#include "MovableEntity.h"
    35 #include "objects/Tickable.h"
    3635
    3736namespace orxonox
    3837{
    39     class _OrxonoxExport ControllableEntity : public MovableEntity, public Tickable
     38    class _OrxonoxExport ControllableEntity : public MovableEntity
    4039    {
    4140        public:
     
    7271            virtual void switchCamera();
    7372
    74             inline const Vector3& getVelocity() const
    75                 { return this->velocity_; }
    76             inline const Vector3& getAcceleration() const
    77                 { return this->acceleration_; }
    7873            inline const std::string& getHudTemplate() const
    7974                { return this->hudtemplate_; }
    80 
    81             inline void setAcceleration(const Vector3& acceleration)
    82                 { this->acceleration_ = acceleration; }
    83             inline void setAcceleration(float x, float y, float z)
    84                 { this->acceleration_.x = x; this->acceleration_.y = y; this->acceleration_.z = z; }
    8575
    8676            inline Camera* getCamera() const
     
    10999                { return this->bControlled_; }
    110100
    111             Vector3 acceleration_;
    112 
    113101        private:
    114102            void overwrite();
     
    116104
    117105            void processServerPosition();
    118             void processServerVelocity();
     106            void processServerLinearVelocity();
    119107            void processServerOrientation();
     108            void processServerAngularVelocity();
    120109
    121110            void processClientPosition();
    122             void processClientVelocity();
     111            void processClientLinearVelocity();
    123112            void processClientOrientation();
     113            void processClientAngularVelocity();
    124114
    125             void positionChanged();
    126             void orientationChanged();
    127             void velocityChanged();
     115            void positionChanged       (bool bContinuous);
     116            void orientationChanged    (bool bContinuous);
     117            void linearVelocityChanged (bool bContinuous);
     118            void angularVelocityChanged(bool bContinuous);
    128119
    129120            void networkcallback_changedplayerID();
     
    135126            Vector3 server_position_;
    136127            Vector3 client_position_;
    137             Vector3 server_velocity_;
    138             Vector3 client_velocity_;
     128            Vector3 server_linear_velocity_;
     129            Vector3 client_linear_velocity_;
    139130            Quaternion server_orientation_;
    140131            Quaternion client_orientation_;
     132            Vector3 server_angular_velocity_;
     133            Vector3 client_angular_velocity_;
    141134
    142135            PlayerInfo* player_;
Note: See TracChangeset for help on using the changeset viewer.