Fix dedicated servers.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3897 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2011-09-04 07:07:20 +00:00
parent e8c1f669cc
commit df9dae3e5f

View file

@ -5758,6 +5758,8 @@ galiasinfo_t *Mod_ParseIQMMeshModel(model_t *mod, char *buffer)
gai[i].ofsbones = (char*)bones - (char*)&gai[i]; gai[i].ofsbones = (char*)bones - (char*)&gai[i];
gai[i].groups = h->num_anims; gai[i].groups = h->num_anims;
gai[i].groupofs = (char*)fgroup - (char*)&gai[i]; gai[i].groupofs = (char*)fgroup - (char*)&gai[i];
offset = LittleLong(mesh[i].first_vertex);
#ifndef SERVERONLY #ifndef SERVERONLY
/*skins*/ /*skins*/
@ -5774,10 +5776,9 @@ galiasinfo_t *Mod_ParseIQMMeshModel(model_t *mod, char *buffer)
R_BuildDefaultTexnums(&texnum[i], texnum[i].shader); R_BuildDefaultTexnums(&texnum[i], texnum[i].shader);
if (texnum[i].shader->flags & SHADER_NOIMAGE) if (texnum[i].shader->flags & SHADER_NOIMAGE)
Con_Printf("Unable to load texture for shader \"%s\" for model \"%s\"\n", texnum[i].shader->name, loadmodel->name); Con_Printf("Unable to load texture for shader \"%s\" for model \"%s\"\n", texnum[i].shader->name, loadmodel->name);
gai[i].ofs_st_array = (char*)(otcoords+offset) - (char*)&gai[i];
#endif #endif
offset = LittleLong(mesh[i].first_vertex);
nt = LittleLong(mesh[i].num_triangles); nt = LittleLong(mesh[i].num_triangles);
tris = (struct iqmtriangle*)(buffer + LittleLong(h->ofs_triangles)); tris = (struct iqmtriangle*)(buffer + LittleLong(h->ofs_triangles));
tris += LittleLong(mesh[i].first_triangle); tris += LittleLong(mesh[i].first_triangle);
@ -5791,7 +5792,6 @@ galiasinfo_t *Mod_ParseIQMMeshModel(model_t *mod, char *buffer)
*idx++ = LittleShort(tris[t].vertex[2]) - offset; *idx++ = LittleShort(tris[t].vertex[2]) - offset;
} }
gai[i].ofs_st_array = (char*)(otcoords+offset) - (char*)&gai[i];
/*verts*/ /*verts*/
gai[i].shares_verts = i; gai[i].shares_verts = i;
gai[i].numverts = LittleLong(mesh[i].num_vertexes); gai[i].numverts = LittleLong(mesh[i].num_vertexes);