diff options
Diffstat (limited to 'engines/neverhood/module1400.cpp')
-rw-r--r-- | engines/neverhood/module1400.cpp | 34 |
1 files changed, 15 insertions, 19 deletions
diff --git a/engines/neverhood/module1400.cpp b/engines/neverhood/module1400.cpp index 5dc74787a1..b4f07447d1 100644 --- a/engines/neverhood/module1400.cpp +++ b/engines/neverhood/module1400.cpp @@ -777,23 +777,22 @@ Scene1401::Scene1401(NeverhoodEngine *vm, Module *parentModule, int which) _sprite2->getSurface()->setVisible(false); if (which < 0) { - _klayman = new KmScene1401(_vm, this, 380, 447); + InsertKlayman(KmScene1401, 380, 447); setMessageList(0x004B65C8); _sprite1->getSurface()->setVisible(false); } else if (which == 1) { - _klayman = new KmScene1401(_vm, this, 0, 447); + InsertKlayman(KmScene1401, 0, 447); setMessageList(0x004B65D0); _sprite1->getSurface()->setVisible(false); } else if (which == 2) { - _klayman = new KmScene1401(_vm, this, 660, 447); + InsertKlayman(KmScene1401, 660, 447); setMessageList(0x004B65D8); _sprite1->getSurface()->setVisible(false); } else { - _klayman = new KmScene1401(_vm, this, 290, 413); + InsertKlayman(KmScene1401, 290, 413); setMessageList(0x004B65E8); _sprite1->getSurface()->setVisible(false); } - addSprite(_klayman); if (getGlobalVar(0x04A105B3) == 2) { _class489 = addSprite(new Class489(_vm, this, _klayman, _class525)); @@ -994,16 +993,16 @@ Scene1402::Scene1402(NeverhoodEngine *vm, Module *parentModule, int which) setRectList(0x004B0C98); if (which < 0) { - _klayman = new KmScene1402(_vm, this, 377, 391); + InsertKlayman(KmScene1402, 377, 391); setMessageList(0x004B0B48); if (!getGlobalVar(0x70A1189C)) { _class482 = addSprite(new Class482(_vm, this, 0)); } } else if (which == 1) { - _klayman = new KmScene1402(_vm, this, 42, 391); + InsertKlayman(KmScene1402, 42, 391); setMessageList(0x004B0B50); } else if (which == 2) { - _klayman = new KmScene1402(_vm, this, 377, 391); + InsertKlayman(KmScene1402, 377, 391); setMessageList(0x004B0B60); _klayman->setDoDeltaX(1); if (getGlobalVar(0x70A1189C)) { @@ -1015,14 +1014,13 @@ Scene1402::Scene1402(NeverhoodEngine *vm, Module *parentModule, int which) _class482 = addSprite(new Class482(_vm, this, 0)); } } else { - _klayman = new KmScene1402(_vm, this, 513, 391); + InsertKlayman(KmScene1402, 513, 391); setMessageList(0x004B0B58); if (!getGlobalVar(0x70A1189C)) { _class482 = addSprite(new Class482(_vm, this, 2)); sub428220(); } } - addSprite(_klayman); if (_class482) { _class482->getSurface()->getClipRect().x1 = 0; @@ -1471,13 +1469,12 @@ Scene1403::Scene1403(NeverhoodEngine *vm, Module *parentModule, int which) _asTape2->setRepl(64, 0); if (which < 0) { - _klayman = new KmScene1403(_vm, this, 380, 463); + InsertKlayman(KmScene1403, 380, 463); setMessageList(0x004B1F18); } else { - _klayman = new KmScene1403(_vm, this, 640, 463); + InsertKlayman(KmScene1403, 640, 463); setMessageList(0x004B1F20); } - addSprite(_klayman); _klayman->setRepl(64, 0); if (getGlobalVar(0x04A105B3) == 4) { @@ -1589,24 +1586,23 @@ Scene1404::Scene1404(NeverhoodEngine *vm, Module *parentModule, int which) _vm->_collisionMan->addSprite(_asTape); if (which < 0) { - _klayman = new KmScene1404(_vm, this, 376, 406); + InsertKlayman(KmScene1404, 376, 406); setMessageList(0x004B8C28); } else if (which == 1) { - _klayman = new KmScene1404(_vm, this, 376, 406); + InsertKlayman(KmScene1404, 376, 406); setMessageList(0x004B8C30); } else if (which == 2) { if (getGlobalVar(0xC0418A02)) { - _klayman = new KmScene1404(_vm, this, 347, 406); + InsertKlayman(KmScene1404, 347, 406); _klayman->setDoDeltaX(1); } else { - _klayman = new KmScene1404(_vm, this, 187, 406); + InsertKlayman(KmScene1404, 187, 406); } setMessageList(0x004B8D28); } else { - _klayman = new KmScene1404(_vm, this, 30, 406); + InsertKlayman(KmScene1404, 30, 406); setMessageList(0x004B8C38); } - addSprite(_klayman); if (getGlobalVar(0x04A105B3) == 3) { _class489 = addSprite(new Class489(_vm, this, _klayman, 0)); |