equal
deleted
inserted
replaced
70 int8_t NetworkPacket::read_int8 (void) { |
70 int8_t NetworkPacket::read_int8 (void) { |
71 return read_val<int8_t>(); |
71 return read_val<int8_t>(); |
72 } |
72 } |
73 |
73 |
74 float NetworkPacket::read_float32 (void) { |
74 float NetworkPacket::read_float32 (void) { |
75 /* XXX */ |
75 return (float) read_uint32(); |
76 } |
76 } |
77 |
77 |
78 Vector NetworkPacket::read_vector (void) { |
78 Vector NetworkPacket::read_vector (void) { |
79 float fx = read_float32(); |
79 float fx = read_float32(); |
80 float fy = read_float32(); |
80 float fy = read_float32(); |
104 |
104 |
105 void NetworkPacket::write_int8 (int8_t val) { |
105 void NetworkPacket::write_int8 (int8_t val) { |
106 write_val<int8_t>(val); |
106 write_val<int8_t>(val); |
107 } |
107 } |
108 |
108 |
109 void write_float32 (float val) { |
109 void NetworkPacket::write_float32 (float val) { |
110 /* XXX: */ |
110 write_uint32((uint32_t) val); |
111 } |
111 } |
112 |
112 |
113 void NetworkPacket::write_vector (const Vector &vec) { |
113 void NetworkPacket::write_vector (const Vector &vec) { |
114 write_float32(vec.x); |
114 write_float32(vec.x); |
115 write_float32(vec.y); |
115 write_float32(vec.y); |