mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-30 20:50:42 +00:00
more FIXME and whitespace cleanups
This commit is contained in:
parent
630aa80dc4
commit
6637f3fba5
2 changed files with 8 additions and 14 deletions
|
@ -300,8 +300,7 @@ Mod_LoadAliasModel (model_t *mod, void *buffer, cache_allocator_t allocator)
|
||||||
total = end - start;
|
total = end - start;
|
||||||
|
|
||||||
mem = allocator (&mod->cache, total, loadname);
|
mem = allocator (&mod->cache, total, loadname);
|
||||||
if (!mem)
|
if (mem)
|
||||||
return; // FIXME: shouldn't this call Hunk_FreeToLowMark too?!?!
|
|
||||||
memcpy (mem, pheader, total);
|
memcpy (mem, pheader, total);
|
||||||
|
|
||||||
Hunk_FreeToLowMark (start);
|
Hunk_FreeToLowMark (start);
|
||||||
|
|
|
@ -518,22 +518,17 @@ Mod_LoadFaces (lump_t *l)
|
||||||
out->samples = loadmodel->lightdata + (i * mod_lightmap_bytes);
|
out->samples = loadmodel->lightdata + (i * mod_lightmap_bytes);
|
||||||
|
|
||||||
// set the drawing flags flag
|
// set the drawing flags flag
|
||||||
// FIXME: do this right?-)
|
if (!out->texinfo->texture || !out->texinfo->texture->name)
|
||||||
if (!out->texinfo->texture)
|
continue; // avoid crashing on null textures
|
||||||
continue;
|
|
||||||
if (!out->texinfo->texture->name)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (!strncmp (out->texinfo->texture->name, "sky", 3)) // sky
|
if (!strncmp (out->texinfo->texture->name, "sky", 3)) { // sky
|
||||||
{
|
|
||||||
out->flags |= (SURF_DRAWSKY | SURF_DRAWTILED);
|
out->flags |= (SURF_DRAWSKY | SURF_DRAWTILED);
|
||||||
if (gl_sky_divide && gl_sky_divide->int_val)
|
if (gl_sky_divide && gl_sky_divide->int_val)
|
||||||
GL_SubdivideSurface (out);
|
GL_SubdivideSurface (out);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (out->texinfo->texture->name[0] == '*') // turbulent
|
if (out->texinfo->texture->name[0] == '*') { // turbulent
|
||||||
{
|
|
||||||
out->flags |= (SURF_DRAWTURB
|
out->flags |= (SURF_DRAWTURB
|
||||||
| SURF_DRAWTILED
|
| SURF_DRAWTILED
|
||||||
| SURF_LIGHTBOTHSIDES);
|
| SURF_LIGHTBOTHSIDES);
|
||||||
|
@ -918,8 +913,8 @@ Mod_LoadBrushModel (model_t *mod, void *buffer)
|
||||||
|
|
||||||
mod->numleafs = bm->visleafs;
|
mod->numleafs = bm->visleafs;
|
||||||
|
|
||||||
if (i < mod->numsubmodels - 1) { // duplicate the basic
|
if (i < mod->numsubmodels - 1) {
|
||||||
// information
|
// duplicate the basic information
|
||||||
char name[10];
|
char name[10];
|
||||||
|
|
||||||
snprintf (name, sizeof (name), "*%i", i + 1);
|
snprintf (name, sizeof (name), "*%i", i + 1);
|
||||||
|
|
Loading…
Reference in a new issue