]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - clvm_cmds.c
allocate memory for big temporary storage arrays rather than using the
[xonotic/darkplaces.git] / clvm_cmds.c
index 756da39abb582a54b790c6eaf83d13e032399b1a..9815a9d220a3498bad700f3f4f737e72e4ae4759 100644 (file)
@@ -437,7 +437,7 @@ static void VM_CL_findradius (void)
        vec_t                   radius, radius2;
        vec3_t                  org, eorg, mins, maxs;
        int                             i, numtouchedicts;
-       prvm_edict_t    *touchedicts[MAX_EDICTS];
+       static prvm_edict_t     *touchedicts[MAX_EDICTS];
        int             chainfield;
 
        VM_SAFEPARMCOUNTRANGE(2, 3, VM_CL_findradius);
@@ -3174,7 +3174,7 @@ void VM_CL_R_PolygonBegin (void)
        sf = NULL;
        if(*picname)
        {
-               tf = TEXF_ALPHA;
+               tf = TEXF_PRECACHE | TEXF_ALPHA;
                if((int)PRVM_G_FLOAT(OFS_PARM1) & DRAWFLAG_MIPMAP)
                        tf |= TEXF_MIPMAP;