]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - csprogs.c
shader_glsl: Don't apply the fringe effect if it's disabled, it fixes scr_screenshot_...
[xonotic/darkplaces.git] / csprogs.c
index 21453faea0f2e5f6cb3b543c02bbfe46eaefba84..f5d3f9ea38b420f49369dde8a5fda63af4824909 100644 (file)
--- a/csprogs.c
+++ b/csprogs.c
@@ -293,7 +293,7 @@ qbool CSQC_AddRenderEdict(prvm_edict_t *ed, int edictnum)
        int c;
        float scale;
        entity_render_t *entrender;
-       dp_model_t *model;
+       model_t *model;
        prvm_vec3_t modellight_origin;
 
        model = CL_GetModelFromEdict(ed);
@@ -487,9 +487,16 @@ qbool CL_VM_UpdateView (double frametime)
                prog->polygonbegin_guess2d = false;
                // free memory for resources that are no longer referenced
                PRVM_GarbageCollection(prog);
-               // pass in width and height as parameters (EXT_CSQC_1)
+               // pass in width and height and menu/focus state as parameters (EXT_CSQC_1)
                PRVM_G_FLOAT(OFS_PARM0) = vid.width;
                PRVM_G_FLOAT(OFS_PARM1) = vid.height;
+               /*
+                * This should be fine for now but FTEQW uses flags for keydest
+                * and checks that an array called "eyeoffset" is 0
+                * 
+                * Just a note in case there's compatibility problems later
+                */
+               PRVM_G_FLOAT(OFS_PARM2) = key_dest == key_game;
                prog->ExecuteProgram(prog, PRVM_clientfunction(CSQC_UpdateView), "QC function CSQC_UpdateView is missing");
                //VectorCopy(oldangles, cl.viewangles);
                // Dresk : Reset Dmg Globals Here
@@ -1172,7 +1179,7 @@ qbool CL_VM_GetEntitySoundOrigin(int entnum, vec3_t out)
 {
        prvm_prog_t *prog = CLVM_prog;
        prvm_edict_t *ed;
-       dp_model_t *mod;
+       model_t *mod;
        matrix4x4_t matrix;
        qbool r = 0;