ScummVM API documentation
scene4010.h
1/* ScummVM - Graphic Adventure Engine
2 *
3 * ScummVM is the legal property of its developers, whose names
4 * are too numerous to list here. Please refer to the COPYRIGHT
5 * file distributed with this source distribution.
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 *
20 */
21
22#ifndef HOLLYWOOD_MONSTERS_SCENES_PLAYABLE_SCENE4010_H
23#define HOLLYWOOD_MONSTERS_SCENES_PLAYABLE_SCENE4010_H
24
25#include "graphics/managed_surface.h"
26
27#include "hollywood/monsters/scenes/playable/playable_scene.h"
28
29namespace Hollywood {
30
31class HollywoodEngine;
32struct Scene4010ReleaseProfile;
33
34class Scene4010 : public PlayableScene {
35public:
37
38private:
39 uint framebufferResourceChunkIndex() const override;
40 void initializeCustomPreviewState() override;
41 void drawCustomActorForegroundComposite(int activeWorldX, int activeWorldY,
42 byte actorDrawOrderMode) override;
43 void runCustomEntrySequence() override;
44 void advanceCustomGameplayLoop(uint32 delta) override;
45 bool dispatchCustomSceneAction(uint16 handlerId) override;
46 bool adjustCustomWalkTargetToFloorMask(int &targetX, int &targetY) const override;
47 bool customizeRouteSegment(byte currentRegion, byte nextRegion, const ActorPathBuildState &state,
48 const ScenePoint &boundary, int &requestedFacing, bool &restoredStepDeltas) override;
49 bool applyCustomSceneStateToHotspotsAndPatches(byte selector) override;
50 AmbientAudioProfile ambientAudioProfile() const override;
51 byte primarySpeechAnimationBaseFrame(byte animationGroup) const override;
52 byte primarySpeechAnimationFrameCount(byte animationGroup) const override;
53 void setPrimarySpeechAnimationFrame(byte animationGroup, byte frameIndex) override;
54 void primarySpeechAnimationRestored(byte animationGroup, byte baseFrame) override;
55
56 bool alternateBackgroundActive() const;
57 void initializeRoomIdleLayer();
58 void resetPaletteCycle();
59 void advancePaletteCycle(uint32 delta);
60 void rotatePaletteCycle();
61 void updateRoomAmbientAudio(uint32 delta);
62 void advanceHeckerIdleLayer(uint32 delta);
63 void advanceHeckerIdleTick();
64 void drawForegroundBlocks(int activeWorldY);
65 void runFirstEntrySequence();
66 void runEntryFromRightSide();
67 void runEntryFromLeftSide();
68 void setActiveActorPose(int x, int y, byte facing);
69 void setHeckerFrame(byte frameIndex);
70 void runHeckerFrameSequence(const byte *frames, uint frameCount);
71 void waitForHeckerIdlePose();
72 void runHeckerDialoguePoseStart();
73 void runHeckerRandomResponsePoseStart();
74 void runHeckerResponsePoseEnd();
75 void finishHeckerDialoguePose();
76 void beginD01SpeechLine(uint16 rowIndex, byte normalFrame, byte alternateFrame = 0xff);
77 void beginSecondarySpeechLineAndEnterHeckerPose(uint16 rowIndex, byte frameIndex);
78 void beginHeckerSpeechLine(byte frameIndex);
79 void runHeckerDialogue();
80 void initializeHeckerDialogueRecords(Common::Array<DialogueChoiceRecord> &records) const;
81 void setHeckerDialogueRecord(Common::Array<DialogueChoiceRecord> &records, uint index,
82 byte enabled, byte nextNodeIndex, byte transitionMode, byte playerTextRowId,
83 byte responseFrameIndex, byte disableAfterUse) const;
84 void runProgressiveExitSpeech();
85 void takeAnimatedItem3A();
86 void handlePendingItem3A();
87 void unlockDestinationFromRoomAction();
88 void runDestinationUnlockAnimation();
89 void takeThrownItem();
90 void applyBaseFramebufferPatch(uint chunkIndex);
91 void copySmallRow(uint sourceOffset, uint destinationOffset);
92 void setScenePoint(uint baseOffset, byte itemId, uint16 x, uint16 y);
93 void clearVerbActionRecord(uint recordIndex);
94 void removeColorMapItem(byte itemId);
95 void replaceColorMapItem(byte sourceItem, byte destinationItem);
96 void copyStepDeltas(uint targetOffset, uint sourceOffset, uint count);
97
98 const Scene4010ReleaseProfile &_releaseProfile;
99 TimedAnimationChannel _roomIdleChannel;
100 TimedAnimationChannel _paletteCycleChannel;
101 TimedAnimationChannel _secondaryAmbientChannel;
102 byte _heckerAnimationState;
103 byte _heckerLoopCount;
104 byte _previousSecondaryAmbientCue;
105 bool _heckerAlternateSpeechPose;
106 bool _heckerManualSequenceActive;
107 bool _heckerPoseTransitionPending;
108 bool _roomAnimationPaused;
109};
110
111} // End of namespace Hollywood
112
113#endif // HOLLYWOOD_MONSTERS_SCENES_PLAYABLE_SCENE4010_H
Definition: array.h:52
Definition: hollywood.h:47
Definition: playable_scene.h:84
Definition: scene4010.h:34
Definition: actor_types.h:59
Definition: ambient_audio.h:44
Definition: scene_data.h:29
Definition: animation_channels.h:34