mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-03 09:23:37 +00:00
Fix Indy4. Make invalid actor warnings -d only.
FIXME note: Need to track down why these invalid calls are happening in the first place. svn-id: r3960
This commit is contained in:
parent
0eaa9b16b4
commit
9b7db10944
@ -1254,10 +1254,15 @@ void Scumm::o5_getActorMoving()
|
||||
void Scumm::o5_getActorRoom()
|
||||
{
|
||||
int temp;
|
||||
Actor *act;
|
||||
getResultPos();
|
||||
temp = getVarOrDirectByte(0x80);
|
||||
|
||||
act = derefActorSafe(temp, "o5_getActorRoom");
|
||||
if (!act)
|
||||
return;
|
||||
|
||||
setResult(derefActorSafe(temp, "o5_getActorRoom")->room);
|
||||
setResult(act->room);
|
||||
}
|
||||
|
||||
void Scumm::o5_getActorScale()
|
||||
|
@ -902,9 +902,8 @@ void Scumm::convertKeysToClicks()
|
||||
Actor *Scumm::derefActorSafe(int id, const char *errmsg)
|
||||
{
|
||||
if (id < 1 || id >= NUM_ACTORS) {
|
||||
warning
|
||||
("Invalid actor %d in %s (script %d, opcode 0x%x) - This is potentially a BIG problem.",
|
||||
id, errmsg, vm.slot[_curExecScript].number, _opcode);
|
||||
if (_debugMode)
|
||||
warning("Invalid actor %d in %s (script %d, opcode 0x%x) - This is potentially a BIG problem.", id, errmsg, vm.slot[_curExecScript].number, _opcode);
|
||||
return NULL;
|
||||
}
|
||||
return derefActor(id);
|
||||
|
Loading…
x
Reference in New Issue
Block a user