diff options
author | tron <tron@openttd.org> | 2005-07-21 06:31:02 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-07-21 06:31:02 +0000 |
commit | 6ad38953061497471aa5af02771a944080718a17 (patch) | |
tree | dc5c9c74cec9bfa29f94932a20193cd902a80f15 /saveload.c | |
parent | e3f4aecd3722b88f147a1a9b96fd15807de26741 (diff) | |
download | openttd-6ad38953061497471aa5af02771a944080718a17.tar.xz |
(svn r2660) Get rid of some more shifting/anding/casting
Diffstat (limited to 'saveload.c')
-rw-r--r-- | saveload.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/saveload.c b/saveload.c index 3c561f821..bef3ef6f9 100644 --- a/saveload.c +++ b/saveload.c @@ -123,14 +123,14 @@ static inline uint64 SlReadUint64(void) static inline void SlWriteUint16(uint16 v) { - SlWriteByte((byte)(v >> 8)); - SlWriteByte((byte)v); + SlWriteByte(GB(v, 8, 8)); + SlWriteByte(GB(v, 0, 8)); } static inline void SlWriteUint32(uint32 v) { - SlWriteUint16((uint16)(v >> 16)); - SlWriteUint16((uint16)v); + SlWriteUint16(GB(v, 16, 16)); + SlWriteUint16(GB(v, 0, 16)); } static inline void SlWriteUint64(uint64 x) |