Commit graph

2504 commits

Author SHA1 Message Date
Christoph Oelckers
905a9bfeae - backend update from GZDoom. 2023-01-07 19:30:49 +01:00
Rachael Alexanderson
532a726ae3 - respect i_pauseinbackground setting 2023-01-07 07:18:52 -05:00
Christoph Oelckers
cfef8c8a71 - ignore executable files in a zip's main folder when checking for mod content in a subdirectory. 2023-01-06 18:01:34 +01:00
Christoph Oelckers
32ce8a97bf - SW: do not double interpolate sectors that are both part of a sector object but also have a global interpolation attached.
In this case the SO interpolation must be skipped. The only use case for this combination is sine-wave animated water.
2023-01-05 19:26:42 +01:00
Mitchell Richters
d59208ce74 - Default initialise g_nextskill to -1 so maps loaded directly from the command line load with the game's default skill. 2023-01-05 20:57:14 +11:00
Christoph Oelckers
ad0860f4bf - fixed sprite rendering being aborted if a sprite with invalid texture was encountered. 2022-12-29 14:53:21 +01:00
Christoph Oelckers
d064706f93 - got rid of wallpicnum and overpicnum.
All map geometry npw uses texture IDs and no longer depends on Build's tile system.
(What's missing is a new map format, though, but this was a necessary prerequisite to make that worthwile...)
2022-12-29 14:14:53 +01:00
Christoph Oelckers
90702ae2f5 - consolidated the animwall code by using texture flags.
This is way too hacky for generalization. For that newly defined control actors are surely a better option.
2022-12-29 14:14:53 +01:00
Christoph Oelckers
9bc0a43028 - fixed lookup for tile aliases pointing to non-existent tiles. 2022-12-29 13:33:02 +01:00
Christoph Oelckers
0d9fe83cba - implemented the switch parser and set up the external definitions. 2022-12-29 13:32:29 +01:00
Kevin Caccamo
996e0ef6cf Attempt to fix #806
Default-initialize TilesetBuildInfo `info`.
Also, make every function in defparser.cpp static except for loaddefinitionsfile, since that's the only function which is called from other source files.
2022-12-22 22:14:13 +01:00
Christoph Oelckers
ef7c72ce9f - Blood: add all statically stored EventObjects to the GC processor. 2022-12-18 17:54:54 +01:00
Christoph Oelckers
21d4aae182 - fixed lookup for tile aliases pointing to non-existent tiles. 2022-12-18 15:19:35 +01:00
Christoph Oelckers
8c41294cb0 - overpicnum lightening.
Especially make sure that it is never set to tile 0. There seems to have been some undefined behavior here treating 0 as 'no texture', but doing so inconsistently.
2022-12-18 15:13:22 +01:00
Christoph Oelckers
79c91b2538 - only write special texture properties if they are being defined. 2022-12-18 15:06:20 +01:00
Christoph Oelckers
a9ea2cd5c0 - moved GetReservedScreenSpace function into the scripted status bar where it belongs.
Since this is supposed to return the height of the status bar, keeping it native is a bit pointless as it cannot be modified that way.
2022-12-18 14:47:38 +01:00
Mitchell Richters
b4f6ea6232 - Fix linking errors. 2022-12-18 14:47:32 +01:00
Christoph Oelckers
e78fd90f67 - adapted sky code for using texture IDs. 2022-12-18 14:42:27 +01:00
Christoph Oelckers
8dfbbc8220 - migrated floorpicnum and ceilingpicnum to FTextures.
The sky code still needs some work.
2022-12-18 14:32:52 +01:00
Christoph Oelckers
622710ede4 - migrated all uses of floorpicnum.
This necessitated a few more surface type definitions.
2022-12-18 14:02:56 +01:00
Christoph Oelckers
4a306a21dc - split several texture flags off into a surface type value.
Using the same field in the TexExtInfo struct as Blood's surfType.
This frees up a lot of flags for later use.
2022-12-18 13:56:54 +01:00
Christoph Oelckers
5b8dd84361 - use setceilingtexture where textures are simply copied around 2022-12-18 13:52:10 +01:00
Christoph Oelckers
ee8b685fe2 - adapted the breakable stuff interface in Duke to Texture IDs. 2022-12-18 13:52:03 +01:00
Christoph Oelckers
5147826eeb - consolidated precaching code and rewrote the core to work on texture IDs. 2022-12-18 13:37:54 +01:00
Christoph Oelckers
1a6f808fca - refactored all access to the fake picanm[] array.
Also use symbolic names in precache calls in Blood.
2022-12-18 13:26:29 +01:00
Christoph Oelckers
e23a5095cb - moved the other tile info tables of Blood to the texExtInfo array as well.
The two fields are easily reusable for the other games so it's a welcome simplification.
2022-12-18 13:23:59 +01:00
Christoph Oelckers
c34756e5f2 - cleanup of voxel init code.
The voxreserve array was never properly set up so it is gone now.
nextvoxid now gets set right before loading .def files.
2022-12-18 13:18:44 +01:00
Christoph Oelckers
8a789b9015 - voxel management cleanup.
Moving the voxel index into the texExtInfo array and removing most of Blood's and SW's special handling.
2022-12-18 13:18:43 +01:00
Christoph Oelckers
be2112a507 - fixed ESC pressing on Duke's monitors.
This got busted by an update from GZDoom.
2022-12-18 13:06:09 +01:00
Christoph Oelckers
6ff91f8ebc - disable the freelist management for discarded tiles.
This does not work as implemented - may be checked out later, but this is not essential.
2022-12-18 13:06:09 +01:00
Christoph Oelckers
20edd800f9 - big texture system refactor.
Finally that quickly slapped together BuildTiles class is gone and replaced with something that better integrates with the underlying texture manager
2022-12-18 13:05:58 +01:00
Mitchell Richters
6e4e2b04eb - Fix pitch direction for controller input. 2022-12-15 08:42:43 +11:00
Christoph Oelckers
d5414da096 - added a - sign to FindBestSector' default return.
This somehow get lost when the code was moved out of clipmove into a separate utility function.
2022-12-14 11:48:34 +01:00
Mitchell Richters
c3f276a08a - Tidy up remaining Build angle constants in gamefuncs.h. 2022-12-11 19:46:27 +01:00
Mitchell Richters
de8353f085 - Eliminate BAngToDegree constant. 2022-12-11 19:46:26 +01:00
Mitchell Richters
67b40ee1d5 - Convert angle in hud_drawsprite() to work on true degrees, and in the right direction. 2022-12-11 19:46:26 +01:00
Christoph Oelckers
bea6834f8e - code cleanup. 2022-12-11 19:45:38 +01:00
Christoph Oelckers
3874cf365c - use TEXMAN_ForceLookup where it was missing. 2022-12-11 19:45:38 +01:00
Christoph Oelckers
c1abd6fe22 - rewrote drawtile CVAR handling to render the image larger and allow using aliases. 2022-12-11 19:45:38 +01:00
Christoph Oelckers
97d76a01e4 - SW: do a proper implementation for sprites which do not want texture animations.
Instead of hacking the picanm table it is far more preferable to flag the sprite as non-animating and let the renderer handle it.
2022-12-11 19:45:38 +01:00
Christoph Oelckers
58db09969c - moved tileForName out of BuildTiles.
Just pulling one change out of the big upcoming refactor commit.
2022-12-11 19:45:18 +01:00
Christoph Oelckers
630276f7e0 - migrated texture flags parsing from .def to RMAPINFO.
This was the final piece of non-tile-related data to be in there.
.def should be restricted to existing use cases concerning setup of render data, not for game content.
2022-12-11 19:45:18 +01:00
Christoph Oelckers
0bacb05c1b - wrapped hiofs in a getter function.
This makes it a lot easier later to refactor.
2022-12-11 19:45:01 +01:00
Christoph Oelckers
aa58b152ab - use a TArray in BuildTiles for the tile descriptors.
For some reason MSVC wants to put this in the EXE now and the array is quite large.
2022-12-11 19:45:00 +01:00
Christoph Oelckers
71ca2c4677 - eliminate the last remaining references to the tile manager in the core renderer files.
The only thing left is the sky which needs more refactoring first and the tileUpdatePicnum call for sprites which cannot be resolved by the texture manager because Blood has a randomization factor included here.
2022-12-11 19:44:01 +01:00
Christoph Oelckers
e26d9106aa - handle all occurences of tileWidth and tileHeight using spritetypebase::picnum. 2022-12-11 19:44:01 +01:00
Christoph Oelckers
f479f995a1 - transitioned all tileLeftOffset and tileTopOffset calls to use the texture manager. 2022-12-11 19:44:01 +01:00
Christoph Oelckers
0869497ecb - rewrote the tile pixel cache to work on texture IDs instead of tile IDs.
This allows using the related checking features with other textures as well.
2022-12-11 19:44:00 +01:00
Christoph Oelckers
a6db974a62 - refactored Blood's tile property arrays to texture IDs.
The data structure here can be optimized later when the other games get to the same point, but this allows to rid Blood of all references to wallpicnunm, floorpicnum and ceilingpicnum except one place in the precacher.
2022-12-11 19:44:00 +01:00
Christoph Oelckers
4ecb4aacb2 - mark all return values from the texture() getters as const.
This is necessary to evade C++ stupidity which happily allows assignment to non-const struct type return values and won't even warn about it.
As const these will throw an error when that happens.
2022-12-11 19:44:00 +01:00