mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-01 16:35:20 +00:00
FULLPIPE: Implement lift_goAnimation()
This commit is contained in:
parent
07568931ce
commit
00369347e0
@ -41,6 +41,8 @@ namespace Fullpipe {
|
||||
#define MV_FLY_FLY 4917
|
||||
#define MV_MAN_GOLADDER 451
|
||||
#define MV_MAN_GOLADDER2 2844
|
||||
#define MV_MAN_LIFTDOWN 1052
|
||||
#define MV_MAN_LIFTUP 1051
|
||||
#define MV_MAN_LOOKUP 4773
|
||||
#define rMV_MAN_LOOKUP 4775
|
||||
#define MV_MAN_TOLADDER 448
|
||||
|
@ -29,6 +29,7 @@
|
||||
#include "fullpipe/scene.h"
|
||||
#include "fullpipe/statics.h"
|
||||
#include "fullpipe/messages.h"
|
||||
#include "fullpipe/gameloader.h"
|
||||
|
||||
namespace Fullpipe {
|
||||
|
||||
@ -234,8 +235,52 @@ void FullpipeEngine::lift_clickButton() {
|
||||
lift_walkAndGo();
|
||||
}
|
||||
|
||||
void FullpipeEngine::lift_goAnimation() {
|
||||
warning("STUB: FullpipeEngine::lift_goAnimation()");
|
||||
void FullpipeEngine::lift_goAnimation() { if (_lastLiftButton) {
|
||||
int parentId = _currentScene->_sceneId;
|
||||
int buttonId = lift_getButtonIdN(_lastLiftButton->_statics->_staticsId);
|
||||
|
||||
if (!buttonId)
|
||||
return;
|
||||
|
||||
int numItems = _gameLoader->_preloadItems.size();
|
||||
|
||||
for (int i = 0; i < numItems; i++) {
|
||||
PreloadItem *pre = _gameLoader->_preloadItems[i];
|
||||
|
||||
if (pre->preloadId2 == buttonId && pre->preloadId1 == _currentScene->_sceneId) {
|
||||
MessageQueue *mq = new MessageQueue(_globalMessageQueueList->compact());
|
||||
|
||||
ExCommand *ex = new ExCommand(ANI_MAN, 1, (pre->keyCode != LiftDown ? MV_MAN_LIFTDOWN : MV_MAN_LIFTUP), 0, 0, 0, 1, 0, 0, 0);
|
||||
|
||||
ex->_keyCode = -1;
|
||||
ex->_field_24 = 1;
|
||||
ex->_excFlags |= 2;
|
||||
|
||||
mq->addExCommandToEnd(ex);
|
||||
|
||||
ex = new ExCommand(parentId, 17, 61, 0, 0, 0, 1, 0, 0, 0);
|
||||
|
||||
ex->_keyCode = buttonId;
|
||||
ex->_excFlags |= 3;
|
||||
|
||||
mq->addExCommandToEnd(ex);
|
||||
|
||||
_aniMan->_flags &= 0xFEFF;
|
||||
|
||||
if (!mq->chain(_aniMan))
|
||||
delete mq;
|
||||
|
||||
_aniMan->_flags |= 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
lift_exitSeq(0);
|
||||
|
||||
if (_lastLiftButton) {
|
||||
_lastLiftButton->_statics = _lastLiftButton->getStaticsById(lift_getButtonIdN(_lastLiftButton->_statics->_staticsId));
|
||||
_lastLiftButton = 0;
|
||||
}
|
||||
}
|
||||
|
||||
void FullpipeEngine::lift_sub1(StaticANIObject *ani) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user