mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
Added a stub for kMergePoly, to avoid crashing in QFG1VGA after killing a monster
svn-id: r49288
This commit is contained in:
parent
bea6ef4beb
commit
967d9ea308
@ -332,6 +332,7 @@ SciKernelFunction kfunct_mappers[] = {
|
||||
DEFUN("DoSync", kDoSync, ".*"),
|
||||
DEFUN("MemorySegment", kMemorySegment, "iri*"),
|
||||
DEFUN("Intersections", kIntersections, "iiiiriiiri"),
|
||||
DEFUN("MergePoly", kMergePoly, "rli"),
|
||||
DEFUN("ResCheck", kResCheck, "iii*"),
|
||||
DEFUN("SetQuitStr", kSetQuitStr, "r"),
|
||||
DEFUN("ShowMovie", kShowMovie, ".*"),
|
||||
|
@ -414,6 +414,7 @@ reg_t kDoAudio(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kDoSync(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kMemorySegment(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kIntersections(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kMergePoly(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kResCheck(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kSetQuitStr(EngineState *s, int argc, reg_t *argv);
|
||||
reg_t kShowMovie(EngineState *s, int argc, reg_t *argv);
|
||||
|
@ -1694,4 +1694,34 @@ reg_t kIntersections(EngineState *s, int argc, reg_t *argv) {
|
||||
}
|
||||
}
|
||||
|
||||
reg_t kMergePoly(EngineState *s, int argc, reg_t *argv) {
|
||||
// 3 parameters: raw polygon data, polygon list, list size
|
||||
reg_t polygonData = argv[0];
|
||||
|
||||
// TODO: actually merge the polygon
|
||||
|
||||
#if 0
|
||||
List *list = s->_segMan->lookupList(argv[1]);
|
||||
Node *node = s->_segMan->lookupNode(list->first);
|
||||
// List size is not needed
|
||||
|
||||
Polygon *polygon;
|
||||
int count = 0;
|
||||
|
||||
while (node) {
|
||||
polygon = convert_polygon(s, node->value);
|
||||
|
||||
if (polygon) {
|
||||
count += GET_SEL32V(s->_segMan, node->value, SELECTOR(size));
|
||||
}
|
||||
|
||||
node = s->_segMan->lookupNode(node->succ);
|
||||
}
|
||||
#endif
|
||||
|
||||
warning("Stub: kMergePoly");
|
||||
|
||||
return polygonData;
|
||||
}
|
||||
|
||||
} // End of namespace Sci
|
||||
|
Loading…
Reference in New Issue
Block a user