Commit graph

659 commits

Author SHA1 Message Date
Dileep V. Reddy
25f1407228 Cleaning up implementation of isometric camera with optional orthographic projection.
All CVars, mapinfo variables, and playerinfo/playerpawn variables are gone.
A Camera actor named 'SpectatorCamera' is defined in warsrc/static/zscript/actors/shared/camera.zs

The following new flag bits were defined in the 'DViewPosition' struct for use with actor->ViewPos in src/playsim/actor.h:
	VPSF_ALLOWOUTOFBOUNDS =		1 << 3,			// Allow viewpoint to go out of bounds (hardware renderer only).
	VPSF_ORTHOGRAPHIC =		1 << 4,			// Use orthographic projection.
	VPSF_ISOMETRICSPRITES =		1 << 5,			// Displace sprites towards camera and don't billboard (drawn from isometric perspective).

Basically, spawn a SpectatorCamera actor with the appropriate flags and set it to player.camera.
See example template: https://www.mediafire.com/file/fv8rytayjt9l6g1/isometric_actor_wads.zip/file

Has been tested with multiplayer death and disconnection (and respawns). Not tested with portals.
Still only works with hardware renderer (mostly). But should be compatible with older mods and libraries.
2024-02-01 08:43:34 -05:00
Dileep V. Reddy
d3405837ce Changed all of the isometric functionality to mapinfo and playerinfo variables. Retained function of most of the CVars. 2024-01-21 12:13:42 -05:00
Rachael Alexanderson
af08413e10
- reverting pull request #2361 - apparently pull request #2364 changed some behaviour and these two do not play nice together. One or the other unfortunately has to be rolled back to allow GZDoom to build properly again.
Revert "Restored r_orthographic behavior."

This reverts commit 26908f5bc5.

Revert "Changed all of the isometric functionality to mapinfo and playerinfo variables. Retained function of most of the CVars."

This reverts commit dc897eacc0.

Revert "Adding isometric camera mode with orthographic projection to current state of master branch of GZDoom."

This reverts commit d2c2c93cf1.
2024-01-21 08:18:16 -05:00
Dileep V. Reddy
dc897eacc0 Changed all of the isometric functionality to mapinfo and playerinfo variables. Retained function of most of the CVars. 2024-01-21 03:34:00 -05:00
Boondorl
a8e350aed8 Renamed Networking Functions
New names more appropriately match the size of the value they write to/read from the stream.
2024-01-05 23:33:15 +01:00
inkoalawetrust
ce2a0c9295 Added LightningSound MAPINFO property.
Also added a tempSound parameter to ForceLightning(). Allowing for changing the specific sound that particular thunderbolt makes when it hits.
2024-01-05 17:35:03 +01:00
Rachael Alexanderson
42ab7dd70f - mark gl_maplightmode as a cheat
I've heard from several people since this was put in that this should be marked as a cheat. This PR lets you make the final call on that.
2023-12-10 18:22:57 +01:00
Christoph Oelckers
ebc808e2a9 did some cleanup of the FResourceFile interface.
* making all members protected (but adding friend overrides for the classes which still need it)
* allowing to read data without retrieving the FResourceLump object.
2023-12-10 10:24:39 +01:00
Professor Hastig
3781c43aec allow defining zero gravity through MAPINFO 2023-11-09 07:17:16 -05:00
Christoph Oelckers
12bc9db609 hooked up the per-level colormaps with the hardware renderer. 2023-10-29 08:13:01 +01:00
Ricardo Luís Vaz Silva
e12f2ce0fe Allow setting the colormap from mapinfo (dsda-doom) 2023-10-29 07:40:56 +01:00
Christoph Oelckers
c94c63110e added a third batch of GetChars call to FStrings. 2023-10-07 23:03:40 +02:00
Christoph Oelckers
084301f4d6 - refined light mode selection.
This is to ensure that if the map specifies light mode Doom (i.e. hardware approximation of software lighting) it is not overridden by the user-selected software emulating light mode.
gl_lightmode should only apply if neither the map nor gl_maplightmode set an explicit light mode.
2023-09-17 08:40:36 +02:00
Christoph Oelckers
f55e388d3f - add description to gl_lightmode 2023-09-16 12:09:57 +02:00
Christoph Oelckers
7fbd99ca0f - fixed flags for gl_lightmode.
With how this is being handled now, the CVAR needs to have the CVAR_GLOBALCONFIG flag and CVAR_NOINITCALL unset or it simply won't work right.
Since its meaning has completely changed now (i.e. it's mainly a performance switch to a less demanding implementation instead of being able to select vastly different lighting methods) making it global is more sensible.
2023-09-16 12:06:42 +02:00
Ricardo Luís Vaz Silva
736d38e8c3 add StartGameDirect function 2023-09-14 16:28:08 +02:00
Christoph Oelckers
ebb71cebf1 - put the entire filesystem code into a namespace and created some subdirectories. 2023-08-22 22:54:54 +02:00
Christoph Oelckers
f9a86c595c - fixed getRealLightmode: don't overwrite level->info->lightmode. 2023-07-21 14:55:59 +02:00
Professor Hastig
4b49d9d185 fixed bad operator 2023-07-17 22:50:05 +02:00
Professor Hastig
666a99f204 lightmode refactor
* make all legacy light modes except 'Doom' MAPINFO only. A CVAR still exists for testing but its value won't be saved to the config.
* user can only select between "performance', 'software' and 'vanilla'. 'performance' is the old 'Doom' mode which is still needed to speed things up on low end hardware.
* MAPINFO can not enforce any of the two software light modes, as low end users require the option to change this to the 'performance' setting. Selecting one will always revert to the user's light mode selection.
2023-07-17 22:50:05 +02:00
Rachael Alexanderson
4ac76d82d8 - redirected maps need to be defined in order to redirect 2023-02-03 20:21:40 -05:00
Rachael Alexanderson
33b217bcc9 - unlatch cvars before checking cvar map redirections 2023-02-01 01:56:10 -05:00
Rachael Alexanderson
04ea28defc - add RedirectCVAR directive for loading alternate maps based on a Bool CVAR setting 2023-02-01 00:06:01 -05:00
Marisa the Magician
0e5c6e37b1 Prevent important messages from being accidentally filtered. 2023-01-04 17:54:09 +01:00
Boondorl
0d4d5587b5 Added FOV Interpolation 2022-12-18 08:23:19 +01:00
Christoph Oelckers
d0c86952ee - disabled shortcutting the intermission code if no summary screen is wanted.
This also disabled all cutscenes being attached to the completed map.
2022-11-16 16:29:02 +01:00
Christoph Oelckers
df7a58d756 - missed one BaseBlend use. 2022-11-08 12:01:34 +01:00
Marisa the Magician
2bb0dcca13 Fix print color of level load message. 2022-11-05 13:08:51 +01:00
Marisa the Magician
a75a96d993 Level name printout on load shouldn't be sent to the HUD. 2022-11-05 13:08:51 +01:00
Christoph Oelckers
6eab875ec2 - added option to show hub and episode names on the alt HUD.
Still very much work in progress because few mods have set this up.
CVARs default to off and are not exposed to the menu.
2022-10-26 17:44:51 +02:00
Christoph Oelckers
453688ccc6 - reworked CVARs to not use a linked list and to be initialized manually.
This solves two problems:

* The linked list is too slow, a map is better. A map cannot be used with statically allocated CVARs because order of initialization is undefined.
* The current CVAR system is an unordered mishmash of static variables and dynamically allocated ones and the means of identification are unsafe. With this everything is allocated on the heap so it can all be handled the same by the cleanup code.
2022-10-21 18:56:43 +02:00
Christoph Oelckers
8aaab153fa - add a system interface for CheckCheatmode and moved some sound code to the backend. 2022-10-02 16:48:56 +02:00
Christoph Oelckers
71ce8aa79a - block wipes when streaming movies are playing.
For synchronization purposes they cannot be interrupted by the wipe loop.
This also groups the cutscene state in a struct for readability purposes.
2022-06-06 12:30:47 +02:00
Christoph Oelckers
4cb7c70e27 - restored accidentally deleted line of code. 2022-06-05 16:43:12 +02:00
Christoph Oelckers
3c96f7e21c - added handling for start-of-episode cutscenes. 2022-06-04 21:58:46 +02:00
Christoph Oelckers
df74288f7b - use the same rules for cutscenes as for old intermissions when travelling in a hub 2022-06-03 00:30:34 +02:00
Christoph Oelckers
99d98cf79d - added cutscene creation code 2022-06-03 00:03:57 +02:00
nashmuhandes
f235dcc38e Squashed commit of the following:
commit 553c4c12abd15e5f8fa02496ccfde81bdfdb53b0
Merge: cb03de5d2 add4ff12a
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Mon Feb 14 18:55:52 2022 +0800

    Merge branch 'master' of https://github.com/coelckers/gzdoom into ActorFallAndSink

commit cb03de5d2fdcba8a32b83be32579be935c8b6600
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Tue Jan 25 12:54:33 2022 +0800

    Re-add WaterDepth to the custom namedef file

commit 8d1ff3c16018dd7c73c8950aa4c51f2bc0207837
Merge: f201e6307 a9eaae074
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Tue Jan 25 12:52:57 2022 +0800

    Merge branch 'master' of https://github.com/coelckers/gzdoom into ActorFallAndSink

    # Conflicts:
    #	src/common/engine/namedef.h

commit f201e630706fc0ea7628b8a32bd5d88afb712208
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Sun Jan 16 20:45:27 2022 +0800

    Fix compile error (MAX() -> max())

commit fe292ebd4312afe34b1e35e4c1eafba0dc168920
Merge: 3f9150c4e 12ed24d06
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Sun Jan 16 20:37:58 2022 +0800

    Merge branch 'master' of https://github.com/coelckers/gzdoom into ActorFallAndSink

    # Conflicts:
    #	src/playsim/p_mobj.cpp

commit 3f9150c4eae1c5c5510e8f9b1c4bfaab46a96b8f
Author: nashmuhandes <nashbackslash@gmail.com>
Date:   Sat May 29 05:32:54 2021 +0800

    - Implement virtual Actor.FallAndSink for scriptable falling and water physics
    - Added Actor.WaterDepth to retrieve how submerged and actor is, in map units

    Original work credited to "gzdoomthrowaway"
2022-05-31 18:57:38 +02:00
Christoph Oelckers
9b0b44d83b - proper handling for running an end-of-game intermission. 2022-04-27 10:53:07 +02:00
Christoph Oelckers
7b59293995 - properly deal with 'gototitle'. 2022-04-26 20:50:36 +02:00
Christoph Oelckers
1aa71cc5a3 - prepared DrawFullscreenSubtitle for script export.
This needed to get the font passed as argument and take care of stringtable lookup inside the function.
2022-04-26 20:50:36 +02:00
Christoph Oelckers
336c45aaa4 - SCreenjob fixes
Still doesn’r show anything but we got it all set up now.
2022-04-26 20:50:35 +02:00
Christoph Oelckers
54329bd87b - make stuff compile again 2022-04-26 20:50:35 +02:00
Christoph Oelckers
1bb750c061 Screenjob WIP stuff 2022-04-26 20:50:35 +02:00
Christoph Oelckers
390bf58698 - first stage of migrating intermissions to screenjobs. 2022-04-26 20:50:35 +02:00
nashmuhandes
1b95f2515b Merge branch 'master' of https://github.com/coelckers/gzdoom into lightmaps2 2021-11-10 19:57:49 +08:00
Christoph Oelckers
77d74a11d1 - removed most templates.h includes. 2021-10-30 10:49:12 +02:00
Magnus Norddahl
764a08752f Use a faster way to find the closest light probe
Fix light probe not being applied to psprite
2021-10-14 05:43:35 +02:00
nashmuhandes
d35cd9549f Merge branch 'master' of https://github.com/coelckers/gzdoom into lightmaps2 2021-10-05 12:53:05 +08:00
Marisa Kirisame
457f7c31c3 Allow WorldUnloaded events to know the next map name (if any). 2021-10-01 20:18:36 +02:00