mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-16 22:58:09 +00:00
AVALANCHE: Fix CID 1109677, 1109678, 1109694, 1109695
This commit is contained in:
parent
9961e0b83f
commit
a6fbfd958d
@ -48,6 +48,35 @@ const int32 Animation::kCatacombMap[8][8] = {
|
||||
|
||||
AnimationType::AnimationType(Animation *anim) {
|
||||
_anim = anim;
|
||||
|
||||
_yLength = 0;
|
||||
for (int i = 0; i < 24; i++) {
|
||||
_mani[i] = nullptr;
|
||||
_sil[i] = nullptr;
|
||||
}
|
||||
_frameNum = 0;
|
||||
_seq = 0;
|
||||
_characterId = 0;
|
||||
_count = 0;
|
||||
_facingDir = kDirNone;
|
||||
_stepNum = 0;
|
||||
_x = 0;
|
||||
_y = 0;
|
||||
_moveX = 0;
|
||||
_moveY = 0;
|
||||
_quick = false;
|
||||
_visible = false;
|
||||
_homing = false;
|
||||
_doCheck = false;
|
||||
_homingX = 0;
|
||||
_homingY = 0;
|
||||
_speedX = 0;
|
||||
_speedY = 0;
|
||||
_vanishIfStill = false;
|
||||
_callEachStepFl = false;
|
||||
_eachStepProc = Animation::kProcNone;
|
||||
_fgBubbleCol = kColorWhite;
|
||||
_bgBubbleCol = kColorBlack;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -370,6 +399,13 @@ Animation::Animation(AvalancheEngine *vm) {
|
||||
for (int16 i = 0; i < kSpriteNumbMax; i++) {
|
||||
_sprites[i] = new AnimationType(this);
|
||||
}
|
||||
|
||||
_direction = kDirNone;
|
||||
_oldDirection = kDirNone;
|
||||
_arrowTriggered = false;
|
||||
_geidaSpin = 0;
|
||||
_geidaTime = 0;
|
||||
_sayWhat = 0;
|
||||
}
|
||||
|
||||
Animation::~Animation() {
|
||||
@ -1202,6 +1238,8 @@ void Animation::animLink() {
|
||||
case kProcGeida :
|
||||
geidaProcs(i);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -97,7 +97,8 @@ public:
|
||||
static const byte kSpriteNumbMax = 5; // current max no. of sprites
|
||||
|
||||
enum Proc {
|
||||
kProcFollowAvvyY = 1,
|
||||
kProcNone = 0,
|
||||
kProcFollowAvvyY,
|
||||
kProcBackAndForth,
|
||||
kProcFaceAvvy,
|
||||
kProcArrow,
|
||||
|
@ -207,6 +207,11 @@ void MenuItem::parseKey(char c) {
|
||||
_menu->_vm->_sound->blip();
|
||||
}
|
||||
|
||||
MenuBar::MenuBar() {
|
||||
_menuNum = 0;
|
||||
_menu = nullptr;
|
||||
}
|
||||
|
||||
void MenuBar::init(Menu *menu) {
|
||||
_menu = menu;
|
||||
_menuNum = 0;
|
||||
@ -261,6 +266,9 @@ Menu::Menu(AvalancheEngine *vm) {
|
||||
_vm = vm;
|
||||
_activeMenuItem.init(this);
|
||||
_menuBar.init(this);
|
||||
|
||||
_menuActive = false;
|
||||
_lastPerson = kPeopleNone;
|
||||
}
|
||||
|
||||
void Menu::findWhatYouCanDoWithIt() {
|
||||
|
@ -102,6 +102,7 @@ public:
|
||||
HeadType _menuItems[8];
|
||||
byte _menuNum;
|
||||
|
||||
MenuBar();
|
||||
void init(Menu *menu);
|
||||
void createMenuItem(char trig, Common::String title, char altTrig, MenuFunc setupFunc, MenuFunc chooseFunc);
|
||||
void draw();
|
||||
|
Loading…
Reference in New Issue
Block a user