Changeset 3332 for code/trunk/src/network/synchronisable
- Timestamp:
- Jul 21, 2009, 12:54:15 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/network/synchronisable/SynchronisableVariable.h
r3304 r3332 36 36 #include <cstring> 37 37 #include "util/Serialise.h" 38 #include "util/T emplateUtils.h"38 #include "util/TypeTraits.h" 39 39 #include "core/GameMode.h" 40 40 #include "network/synchronisable/NetworkCallbackManager.h" … … 79 79 virtual inline void putData(uint8_t*& mem, uint8_t mode, bool forceCallback = false); 80 80 virtual inline uint32_t getSize(uint8_t mode); 81 virtual inline void* getReference(){ return static_cast<void*>(const_cast<typename TypeStripper<T>::RawType*>(&this->variable_)); }81 virtual inline void* getReference(){ return static_cast<void*>(const_cast<typename Loki::TypeTraits<T>::UnqualifiedType*>(&this->variable_)); } 82 82 protected: 83 83 … … 182 182 { 183 183 this->varReference_++; 184 memcpy(static_cast<void*>(const_cast<typename TypeStripper<T>::RawType*>(&this->varBuffer_)), &this->variable_, sizeof(this->variable_));184 memcpy(static_cast<void*>(const_cast<typename Loki::TypeTraits<T>::UnqualifiedType*>(&this->varBuffer_)), &this->variable_, sizeof(this->variable_)); 185 185 } 186 186 } … … 215 215 { 216 216 mem += sizeof(varReference_); 217 memcpy(static_cast<void*>(const_cast<typename TypeStripper<T>::RawType*>(&this->varBuffer_)), &this->variable_, sizeof(T));217 memcpy(static_cast<void*>(const_cast<typename Loki::TypeTraits<T>::UnqualifiedType*>(&this->varBuffer_)), &this->variable_, sizeof(T)); 218 218 if ( this->callback_ != 0 ) 219 219 callback = true;
Note: See TracChangeset
for help on using the changeset viewer.