mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-22 04:01:23 +00:00
DIRECTIR: LINGO: Do not crash on 'the number of castmembers' when Shared Cast is not present
This commit is contained in:
parent
89c4a1c7e1
commit
1e1703bf37
@ -390,7 +390,7 @@ Datum Lingo::getTheEntity(int entity, Datum &id, int field) {
|
||||
break;
|
||||
case kTheCastMembers:
|
||||
d.type = INT;
|
||||
d.u.i = movie->getCast()->_loadedCast->size() + movie->_sharedCast->_loadedCast->size();
|
||||
d.u.i = movie->getCast()->_loadedCast->size() + (movie->_sharedCast ? movie->_sharedCast->_loadedCast->size() : 0);
|
||||
break;
|
||||
case kTheCenterStage:
|
||||
d.type = INT;
|
||||
|
Loading…
x
Reference in New Issue
Block a user