Client: add vv_flag VFL_VIDREMOVE, for client-side entities needing deletion on renderer restart.
This commit is contained in:
parent
70d6302808
commit
5c6f405872
2 changed files with 12 additions and 4 deletions
|
@ -272,13 +272,20 @@ Entities_ParseLump(void)
|
|||
void
|
||||
Entities_RendererRestarted(void)
|
||||
{
|
||||
int c = 0;
|
||||
int c = 0i;
|
||||
int f = 0i;
|
||||
|
||||
for (entity b = world; (b = findfloat(b, ::isCSQC, TRUE));) {
|
||||
NSEntity pf = (NSEntity) b;
|
||||
|
||||
if (pf.vv_flags & VFL_VIDREMOVE) {
|
||||
pf.Destroy();
|
||||
f++;
|
||||
} else {
|
||||
pf.RendererRestarted();
|
||||
c++;
|
||||
}
|
||||
|
||||
NSLog("...resource reload called on %i entities", c);
|
||||
}
|
||||
|
||||
NSLog("...resource reload called on %i entities, flushed %i", c, f);
|
||||
}
|
||||
|
|
|
@ -47,3 +47,4 @@
|
|||
#define VFL_PRIMEDFUSE (1<<11) /**< Entity is not allowed to fire. */
|
||||
#define VFL_REDRAW (1<<12) /**< Entity is not allowed to fire. */
|
||||
#define VFL_FIRING (1<<13) /**< Entity is firing. */
|
||||
#define VFL_VIDREMOVE (1<<14) /**< Entity will be flushed upon vid_reload. */
|
||||
|
|
Loading…
Reference in a new issue