mirror of
https://github.com/libretro/scummvm.git
synced 2025-03-03 16:58:26 +00:00
Expanded the chute animation to display the full sequence as the player leaves the dungeon
svn-id: r25302
This commit is contained in:
parent
33707d6e42
commit
a83be36a97
@ -251,11 +251,8 @@ void Game::handleMenuResponse(uint8 selection) {
|
||||
}
|
||||
|
||||
void Game::playerChangeRoom() {
|
||||
OSystem &system = System::getReference();
|
||||
Resources &res = Resources::getReference();
|
||||
Screen &screen = Screen::getReference();
|
||||
Room &room = Room::getReference();
|
||||
Mouse &mouse = Mouse::getReference();
|
||||
ValueTableData &fields = res.fieldList();
|
||||
SequenceDelayList &delayList = Resources::getReference().delayList();
|
||||
|
||||
@ -272,22 +269,10 @@ void Game::playerChangeRoom() {
|
||||
|
||||
int animFlag = fields.getField(ROOM_EXIT_ANIMATION);
|
||||
if (animFlag == 1)
|
||||
{
|
||||
Palette palette(CHUTE_PALETTE_ID);
|
||||
AnimationSequence *anim = new AnimationSequence(screen, system,
|
||||
CHUTE_ANIM_ID, palette, false);
|
||||
mouse.cursorOff();
|
||||
anim->show();
|
||||
mouse.cursorOn();
|
||||
} else if (animFlag != 0)
|
||||
{
|
||||
Palette palette(BARREL_PALETTE_ID);
|
||||
AnimationSequence *anim = new AnimationSequence(screen, system,
|
||||
BARREL_ANIM_ID, palette, false);
|
||||
mouse.cursorOff();
|
||||
anim->show();
|
||||
mouse.cursorOn();
|
||||
}
|
||||
displayChuteAnimation();
|
||||
else if (animFlag != 0)
|
||||
displayBarrelAnimation();
|
||||
fields.setField(ROOM_EXIT_ANIMATION, 0);
|
||||
|
||||
// Change to the new room
|
||||
Hotspot *player = res.getActiveHotspot(PLAYER_ID);
|
||||
@ -299,6 +284,53 @@ void Game::playerChangeRoom() {
|
||||
room.setRoomNumber(roomNum, false);
|
||||
}
|
||||
|
||||
void Game::displayChuteAnimation()
|
||||
{
|
||||
OSystem &system = System::getReference();
|
||||
Resources &res = Resources::getReference();
|
||||
Screen &screen = Screen::getReference();
|
||||
Mouse &mouse = Mouse::getReference();
|
||||
|
||||
ValueTableData &fields = res.fieldList();
|
||||
Palette palette(CHUTE_PALETTE_ID);
|
||||
|
||||
debugC(ERROR_INTERMEDIATE, kLureDebugAnimations, "Starting chute animation");
|
||||
mouse.cursorOff();
|
||||
|
||||
AnimationSequence *anim = new AnimationSequence(screen, system,
|
||||
CHUTE_ANIM_ID, palette, false);
|
||||
anim->show();
|
||||
delete anim;
|
||||
|
||||
anim = new AnimationSequence(screen, system, CHUTE2_ANIM_ID,
|
||||
palette, false);
|
||||
anim->show();
|
||||
delete anim;
|
||||
|
||||
anim = new AnimationSequence(screen, system, CHUTE3_ANIM_ID,
|
||||
palette, false);
|
||||
anim->show();
|
||||
delete anim;
|
||||
|
||||
mouse.cursorOn();
|
||||
fields.setField(82, 1);
|
||||
}
|
||||
|
||||
void Game::displayBarrelAnimation()
|
||||
{
|
||||
OSystem &system = System::getReference();
|
||||
Screen &screen = Screen::getReference();
|
||||
Mouse &mouse = Mouse::getReference();
|
||||
|
||||
debugC(ERROR_INTERMEDIATE, kLureDebugAnimations, "Starting barrel animation");
|
||||
Palette palette(BARREL_PALETTE_ID);
|
||||
AnimationSequence *anim = new AnimationSequence(screen, system,
|
||||
BARREL_ANIM_ID, palette, false);
|
||||
mouse.cursorOff();
|
||||
anim->show();
|
||||
mouse.cursorOn();
|
||||
}
|
||||
|
||||
void Game::handleClick() {
|
||||
Resources &res = Resources::getReference();
|
||||
Room &room = Room::getReference();
|
||||
|
@ -52,6 +52,8 @@ private:
|
||||
void doAction(Action action, uint16 hotspotId, uint16 usedId);
|
||||
|
||||
void playerChangeRoom();
|
||||
void displayChuteAnimation();
|
||||
void displayBarrelAnimation();
|
||||
void handleBootParam(int value);
|
||||
public:
|
||||
Game();
|
||||
|
Loading…
x
Reference in New Issue
Block a user