diff options
Diffstat (limited to 'engines/dreamweb')
-rw-r--r-- | engines/dreamweb/structs.h | 10 | ||||
-rw-r--r-- | engines/dreamweb/stubs.cpp | 20 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 2 |
3 files changed, 30 insertions, 2 deletions
diff --git a/engines/dreamweb/structs.h b/engines/dreamweb/structs.h index a5ddabf7fe..822546b7f3 100644 --- a/engines/dreamweb/structs.h +++ b/engines/dreamweb/structs.h @@ -32,6 +32,16 @@ struct ObjData { uint8 b6; uint8 delay; uint8 type; + uint8 b9; + uint8 b10; + uint8 b11; + uint8 b12; + uint8 b13; + uint8 b14; + uint8 b15; + uint8 b16; + uint8 b17; + uint8 b18[256]; // NB: Don't know the size yet }; diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp index b5b88f66e2..45efe8b02c 100644 --- a/engines/dreamweb/stubs.cpp +++ b/engines/dreamweb/stubs.cpp @@ -829,14 +829,30 @@ void DreamGenContext::backobject(Sprite* sprite) { else if (objData->type == 2) doorway(); else if (objData->type == 1) - constant(); + constant(sprite, objData); else - steady(); + steady(sprite, objData); ds = pop(); es = pop(); } +void DreamGenContext::constant(Sprite* sprite, ObjData* objData) { + ++sprite->b19; + if (objData->b18[sprite->b19] == 255) { + sprite->b19 = 0; + } + uint8 b18 = objData->b18[sprite->b19]; + objData->b17 = b18; + sprite->b15 = b18; +} + +void DreamGenContext::steady(Sprite* sprite, ObjData* objData) { + uint8 b18 = objData->b18[0]; + objData->b17 = b18; + sprite->b15 = b18; +} + void DreamGenContext::modifychar() { al = engine->modifyChar(al); } diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index dbedb32640..5a4377b119 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -27,6 +27,8 @@ void spriteupdate(); void mainmanCPP(Sprite* sprite); void backobject(Sprite* sprite); + void constant(Sprite* sprite, ObjData* objData); + void steady(Sprite* sprite, ObjData* objData); void modifychar(); void lockmon(); |