]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/lib/warpzone/client.qc
Disallow enabling r_water via mapinfo, automatically enable it on maps with warpzones...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / lib / warpzone / client.qc
index 3a6765e9d46fbfc7ed9025238cfe8017a1fc5bde..7f8b0cdc837258a7bb5547d984afbcd960430baa 100644 (file)
@@ -28,6 +28,8 @@ void WarpZone_Fade_PreDraw(entity this)
 void WarpZone_Touch(entity this, entity toucher);
 NET_HANDLE(ENT_CLIENT_WARPZONE, bool isnew)
 {
+       if(!warpzone_warpzones_exist)
+               cvar_settemp("r_water", "1"); // HACK for DarkPlaces: always enable reflections when a map has warpzones
        warpzone_warpzones_exist = 1;
        if (!this.enemy)
        {
@@ -84,6 +86,8 @@ NET_HANDLE(ENT_CLIENT_WARPZONE, bool isnew)
 
 NET_HANDLE(ENT_CLIENT_WARPZONE_CAMERA, bool isnew)
 {
+       if(!warpzone_cameras_exist)
+               cvar_settemp("r_water", "1"); // HACK for DarkPlaces: always enable reflections when a map has cameras
        warpzone_cameras_exist = 1;
        this.classname = "func_warpzone_camera";