mirror of
https://github.com/scummvm/scummvm.git
synced 2026-06-20 05:45:29 +00:00
WINTERMUTE: WME3D: Restore missing check, matching original
This commit is contained in:
@@ -1908,8 +1908,11 @@ bool AdActor3DX::scCallMethod(ScScript *script, ScStack *stack, ScStack *thisSta
|
||||
stack->pop();
|
||||
|
||||
warning("AdActor3DX::scCallMethod D3DX effects are not supported");
|
||||
|
||||
stack->pushBool(false);
|
||||
if (_modelX) {
|
||||
stack->pushBool(true);
|
||||
} else {
|
||||
stack->pushBool(false);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -411,6 +411,9 @@ bool MeshX::pickPoly(Math::Vector3d *pickRayOrig, Math::Vector3d *pickRayDir) {
|
||||
Math::Vector3d v2;
|
||||
v2.setData(&_vertexData[index3 * kVertexComponentCount + kPositionOffset]);
|
||||
|
||||
if (isnan(v0.x()))
|
||||
continue;
|
||||
|
||||
Math::Vector3d intersection;
|
||||
if (lineIntersectsTriangle(*pickRayOrig, *pickRayDir, v0, v1, v2, intersection.x(), intersection.y(), intersection.z())) {
|
||||
res = true;
|
||||
|
||||
@@ -246,6 +246,10 @@ bool ModelX::loadFromFile(const Common::String &filename, ModelX *parentModel) {
|
||||
}
|
||||
|
||||
bool ModelX::mergeFromFile(const Common::String &filename) {
|
||||
if (!_rootFrame) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint32 fileSize = 0;
|
||||
byte *buffer = BaseFileManager::getEngineInstance()->getEngineInstance()->readWholeFile(filename, &fileSize);
|
||||
XFileLexer lexer = createXFileLexer(buffer, fileSize);
|
||||
|
||||
Reference in New Issue
Block a user