[Scummvm-cvs-logs] CVS: scummvm/simon simon.cpp,1.11,1.12
Ludvig Strigeus
strigeus at users.sourceforge.net
Sun Apr 14 13:23:02 CEST 2002
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/morphos morphos.h,NONE,1.1 morphos_start.cpp,NONE,1.1 Makefile,1.2,1.3 morphos.cpp,1.7,1.8 morphos_sound.cpp,1.5,1.6
- Next message: [Scummvm-cvs-logs] CVS: tools descumm5.cpp,NONE,1.1 descumm6.cpp,NONE,1.1 readme.txt,1.2,1.3
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/simon
In directory usw-pr-cvs1:/tmp/cvs-serv5565
Modified Files:
simon.cpp
Log Message:
fixed a few endianness bugs
Index: simon.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/simon/simon.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** simon.cpp 14 Apr 2002 18:13:08 -0000 1.11
--- simon.cpp 14 Apr 2002 20:22:36 -0000 1.12
***************
*** 5782,5786 ****
void SimonState::o_unk_120(uint a) {
! uint16 id = READ_BE_UINT16_UNALIGNED(&a);
_lock_word |= 0x4000;
_vc_ptr = (byte*)&id;
--- 5782,5786 ----
void SimonState::o_unk_120(uint a) {
! uint16 id = TO_BE_16(a);
_lock_word |= 0x4000;
_vc_ptr = (byte*)&id;
***************
*** 6056,6060 ****
void SimonState::o_unk_99_simon1(uint a) {
! uint16 b = READ_BE_UINT16_UNALIGNED(&a);
_lock_word |= 0x4000;
_vc_ptr = (byte*)&b;
--- 6056,6060 ----
void SimonState::o_unk_99_simon1(uint a) {
! uint16 b = TO_BE_16(a);
_lock_word |= 0x4000;
_vc_ptr = (byte*)&b;
***************
*** 6066,6071 ****
uint16 items[2];
! items[0] = READ_BE_UINT16_UNALIGNED(&a);
! items[1] = READ_BE_UINT16_UNALIGNED(&b);
_lock_word |= 0x4000;
--- 6066,6071 ----
uint16 items[2];
! items[0] = TO_BE_16(a);
! items[1] = TO_BE_16(a);
_lock_word |= 0x4000;
***************
*** 7179,7185 ****
p = dst + num_1 * 8;
! *(uint16*)(p+4) = READ_BE_UINT16_UNALIGNED(&height);
! *(uint16*)(p+6) = READ_BE_UINT16_UNALIGNED(&width);
! dst += READ_BE_UINT32_UNALIGNED(&*(uint32*)p);
memset(dst, 0, count);
--- 7179,7185 ----
p = dst + num_1 * 8;
! *(uint16*)(p+4) = TO_BE_16(height);
! *(uint16*)(p+6) = TO_BE_16(width);
! dst += READ_BE_UINT32_UNALIGNED(p);
memset(dst, 0, count);
***************
*** 8597,8601 ****
do {
if (!(_game & GAME_SIMON2)) {
! opcode = READ_BE_UINT16_UNALIGNED(&*(uint16*)src);
src+=2;
} else {
--- 8597,8601 ----
do {
if (!(_game & GAME_SIMON2)) {
! opcode = READ_BE_UINT16_UNALIGNED((uint16*)src);
src+=2;
} else {
***************
*** 8616,8625 ****
case 'x': fprintf(_dump_file,"\n"); return;
case 'b': fprintf(_dump_file,"%d ", *src++); break;
! case 'd': fprintf(_dump_file,"%d ", READ_BE_UINT16_UNALIGNED(&*(uint16*)src)); src+=2; break;
! case 'v': fprintf(_dump_file,"[%d] ", READ_BE_UINT16_UNALIGNED(&*(uint16*)src)); src+=2; break;
! case 'i': fprintf(_dump_file,"%d ", (int16)READ_BE_UINT16_UNALIGNED(&*(uint16*)src)); src+=2; break;
case 'q':
while (*(uint16*)src != 0xE703) {
! fprintf(_dump_file,"(%d,%d) ", READ_BE_UINT16_UNALIGNED(&((uint16*)src)[0]), READ_BE_UINT16_UNALIGNED(&((uint16*)src)[1]));
src += 4;
}
--- 8616,8625 ----
case 'x': fprintf(_dump_file,"\n"); return;
case 'b': fprintf(_dump_file,"%d ", *src++); break;
! case 'd': fprintf(_dump_file,"%d ", READ_BE_UINT16_UNALIGNED(src)); src+=2; break;
! case 'v': fprintf(_dump_file,"[%d] ", READ_BE_UINT16_UNALIGNED(src)); src+=2; break;
! case 'i': fprintf(_dump_file,"%d ", (int16)READ_BE_UINT16_UNALIGNED(src)); src+=2; break;
case 'q':
while (*(uint16*)src != 0xE703) {
! fprintf(_dump_file,"(%d,%d) ", READ_BE_UINT16_UNALIGNED(src), READ_BE_UINT16_UNALIGNED(src+2));
src += 4;
}
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/morphos morphos.h,NONE,1.1 morphos_start.cpp,NONE,1.1 Makefile,1.2,1.3 morphos.cpp,1.7,1.8 morphos_sound.cpp,1.5,1.6
- Next message: [Scummvm-cvs-logs] CVS: tools descumm5.cpp,NONE,1.1 descumm6.cpp,NONE,1.1 readme.txt,1.2,1.3
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list