#include "quakedef.h"
#include "clvm_cmds.h"
#include "cl_collision.h"
+#include "com_list.h"
/*
#ifndef LINK_TO_LIBODE
// Load the DLL
- if (Sys_LoadLibrary (dllnames, &ode_dll, odefuncs))
+ if (Sys_LoadDependency (dllnames, &ode_dll, odefuncs))
#endif
{
dInitODE();
# else
Con_Printf("ODE library not compiled for double precision - incompatible! Not using ODE physics.\n");
# endif
- Sys_UnloadLibrary(&ode_dll);
+ Sys_FreeLibrary(&ode_dll);
ode_dll = NULL;
}
else
{
dCloseODE();
#ifndef LINK_TO_LIBODE
- Sys_UnloadLibrary(&ode_dll);
+ Sys_FreeLibrary(&ode_dll);
ode_dll = NULL;
#endif
}
// check if trimesh can be defined with convex
convex_compatible = false;
- for (i = 0;i < model->nummodelsurfaces;i++)
+ for (i = model->submodelsurfaces_start;i < model->submodelsurfaces_end;i++)
{
- if (!strcmp(((msurface_t *)(model->data_surfaces + model->firstmodelsurface + i))->texture->name, "collisionconvex"))
+ if (!strcmp(model->data_surfaces[i].texture->name, "collisionconvex"))
{
convex_compatible = true;
break;