Mitch Richters
add3481e40
- SW: Replace use of pushmove_old()
inline wrapper with pushmove()
and remove inline wrappers.
2021-10-30 17:30:02 +02:00
Mitch Richters
adcdbdc931
- SW: Replace use of clipmove_old()
inline wrapper with clipmove()
and remove inline wrappers.
2021-10-30 17:30:02 +02:00
Mitch Richters
9894729fc2
- Replace MAX()
from templates.h
with version provided in STL.
...
# Conflicts:
# source/common/textures/hw_ihwtexture.cpp
# source/common/utility/templates.h
2021-10-30 10:36:02 +02:00
Christoph Oelckers
57b638f26f
- use std::clamp instead of our homegrown version.
2021-10-30 10:35:00 +02:00
Mitch Richters
879e2f3ce4
- Build: Promote sintable[]
array values to precision Blood uses in prep for replacing Blood's costable[]
.
2021-10-30 10:24:15 +02:00
Christoph Oelckers
c4ea5cf336
- restore original krand formula.
...
Note: The only game module actually using this is Duke/RR.
2021-10-26 18:48:54 +02:00
Christoph Oelckers
86c58649ba
- fixed black rendered sectors in Exhumed/Polymost.
...
More a hack than a fix, thanks to Polymost's poor state handling
2021-10-16 15:36:34 +02:00
Christoph Oelckers
62d0d3712e
- use a sprite flag to mark mapped sprites.
...
This avoids another global array which needs to be addressed by sprite index.
2021-10-14 15:09:43 +02:00
Christoph Oelckers
29769dd673
- fixed engine code warnings pointed out by XCode 13.
2021-10-08 19:06:41 +02:00
Christoph Oelckers
7f485bfab1
- split off the extended sprite flags into their own word.
...
Some code overwrites the cstat field entirely (thanks Duke, for being sloppy with this...!)
2021-09-12 18:26:35 +02:00
Christoph Oelckers
99ecfe133d
- flag sprites for automapping regardless of the 'automapping' variable's value.
...
Duke should show its floor sprites, too.
2021-09-12 18:22:38 +02:00
Christoph Oelckers
0bd0923f44
- cleaned up some dirty code.
2021-08-30 08:07:40 +02:00
Mitchell Richters
4298399e00
- Build: Change MAXSPRITESONSCREEN
from constant of 2560 to 1/4 of MAXSPRITES.
...
* Mods like Blood's Eviction are pushing these limits hard. Bumping the onscreen limit resolved recurring crash on `sstation.map` with no apparent ill-effects.
2021-07-25 15:38:51 +10:00
Dino Bollinger
8dd0f947f7
Remove useless code introduced in bad17f29
2021-07-07 21:31:32 +02:00
Mitchell Richters
1dbf34fe56
- Repair some potential issues from 1354d52c05
that might be causing issues with #455 .
2021-07-04 21:06:13 +10:00
Christoph Oelckers
5b38343407
- fixed sprite exclusion logic in getzrange.
...
This was using the wrong flag.
2021-06-09 00:31:54 +02:00
Christoph Oelckers
7fa690082e
- fixed cherry picked commit.
...
# Conflicts:
# source/core/gamecontrol.h
2021-06-02 20:52:47 +02:00
Christoph Oelckers
dc846dcd49
- Duke: avoid clipping against self when executing script logic for floor sprites.
...
A good place to see the result is a kitchen knife in E4L2 that went missing due to the faulty check.
2021-06-01 21:21:39 +02:00
Christoph Oelckers
454816299e
- reorganized loading of textures.
...
Due to dependencies on initializing some data in app_init it was not possible to cleanly set up the fonts.
This adds a game-side function for loading the entire palettes before starting with the texture data and another one for loading game-side texture data.
This now allows fully setting up the palettes before starting with the textures and to fully set up the textures before reading the .def files.
All this is needed because to properly initialize, the fonts need to be able to access the fully initialized texture state, including replacements and hires substitutions from the .def files.
2021-06-01 11:05:26 +02:00
Brian Koropoff
e4e949877d
Fix buffer overflow at maploader.cpp:392
2021-05-22 22:31:16 +02:00
Christoph Oelckers
d572e56839
- removed the indirection for the global arrays.
...
No idea what part of EDuke32 needed this, but it is not necessary.
2021-05-21 14:32:01 +02:00
Christoph Oelckers
d4eb54d686
- render free standing wall sprites without depth bias.
...
Otherwise they can end up badly ordered with walls.
2021-05-20 12:36:35 +02:00
Christoph Oelckers
5ae1c334fa
- Duke: fixed bad check in 'ifnotmoving' CON command.
2021-05-14 10:03:07 +02:00
Christoph Oelckers
b6dd834420
- fixed warnings in Build code.
2021-05-12 21:47:32 +02:00
Christoph Oelckers
7283de0084
- fixed some very noisy warnings in two headers.
2021-05-12 21:47:32 +02:00
Christoph Oelckers
e40ed2262e
- cleanup of 'gotpic' handling.
2021-05-10 20:13:28 +02:00
Christoph Oelckers
e74aca291c
- position tweaking for Nam's skies.
...
Why is this such an utter mess to get skies placed correctly? :(
2021-05-10 20:13:28 +02:00
Cacodemon345
36b910a253
Fix compilation on OpenBSD
2021-05-10 08:25:14 +02:00
Christoph Oelckers
34a5fb5a6a
- make testnewrenderer persistent.
2021-05-06 18:12:23 +02:00
Christoph Oelckers
d54a8724b5
- default 'testnewrenderer' to false.
2021-05-06 17:04:48 +02:00
Christoph Oelckers
020a636c2f
- removed some more useless stuff from headers.
2021-05-03 19:16:26 +02:00
Christoph Oelckers
0db8fc6163
- removed UNREFERENCED_PARAMETER macro.
...
Using C++ standard of not naming such parameters instead.
2021-05-03 19:10:53 +02:00
Christoph Oelckers
7d77b2315f
- merged the few remaining contents of mmulti.h into d_net.h
2021-05-03 19:01:00 +02:00
Christoph Oelckers
8c379f7a44
Merge branch 'master' into newrenderer
2021-04-25 11:33:47 +02:00
Christoph Oelckers
3ad4a869c1
- handle the case that a deleted sprite has inserted its bogus sector reference into the clip list.
...
We got one report of Blood crashing on this.
2021-04-23 20:11:46 +02:00
Christoph Oelckers
db7527fa43
- fix sky palette in Polymost mode.
2021-04-22 22:03:16 +02:00
Christoph Oelckers
9092b5c392
- removed some unused stuff from engine.
2021-04-21 22:32:27 +02:00
Mitchell Richters
98a9963bb5
- Fix release builds of project and remove old def_.cpp
stub file.
2021-04-22 06:30:44 +10:00
Christoph Oelckers
ba5e7d419c
- cleaned up the remains of the old def parser.
2021-04-21 18:15:55 +02:00
Christoph Oelckers
1ea25e5d0e
- reworked the def parser's main loop.
2021-04-21 18:15:25 +02:00
Christoph Oelckers
8c854441bc
- model command migrated
2021-04-21 18:15:12 +02:00
Christoph Oelckers
542e1b2ba7
- ported all simple model commands.
...
'model' is the last remaining one.
2021-04-21 18:15:12 +02:00
Christoph Oelckers
b49de68c86
- migrated highpalookup, basepalette and undefbasepaletterange.
2021-04-20 22:43:02 +02:00
Christoph Oelckers
512411d0fa
- parseUndefTexture(Range)
2021-04-20 20:41:15 +02:00
Christoph Oelckers
1518156386
- parseUndefPalookupRange
2021-04-20 20:41:15 +02:00
Christoph Oelckers
276fd19462
- parseMakePalookup
2021-04-20 20:41:15 +02:00
Christoph Oelckers
6fb09f36c7
- fixed a few parsing errors.
2021-04-20 20:41:04 +02:00
Christoph Oelckers
aaad546729
- palookup.
2021-04-20 20:21:51 +02:00
Christoph Oelckers
bb119fa928
- parseNumAlphaTabs
2021-04-20 20:21:51 +02:00
Christoph Oelckers
82a0b0502b
- parseBlendTable
2021-04-20 20:21:51 +02:00
Christoph Oelckers
01f93f4cca
- several smaller texture (un)definition commands.
2021-04-20 20:05:35 +02:00
Christoph Oelckers
8c5a9c23c3
- tileimportfromtexture and copytile.
2021-04-20 20:04:44 +02:00
Christoph Oelckers
97637e4d2d
- parseArtFile.
2021-04-20 20:03:19 +02:00
Christoph Oelckers
2761ced670
- handle 2 dead .def commands.
2021-04-20 20:02:19 +02:00
Christoph Oelckers
afb2cd3b82
- fixed NoFullbrightRange.
...
Ever since the texture system switchover this only set a dead bit, it has to explicitly mark the texture as not having a brightmap.
2021-04-20 20:02:08 +02:00
Christoph Oelckers
40a632a2ae
- rffdefineid
2021-04-20 19:39:12 +02:00
Christoph Oelckers
82194bbf6b
Merge branch 'master' into newrenderer
...
# Conflicts:
# source/games/exhumed/src/2d.cpp
2021-04-17 13:22:30 +02:00
Christoph Oelckers
42b87362ee
- When keeping around a dummy sprite, make sure that the engine's utilities cannot find it anymore.
...
This was causing issues with the master switch sprites in Duke that have to be kept for sound purposes.
Unfortunately, both hitscan and neartag are far too dumb to analyze sprites they may hit in any way and needed some help skipping such sprites.
2021-04-17 09:37:38 +02:00
Christoph Oelckers
f4ec9a1921
- 4 more .def commands ported
2021-04-13 18:14:46 +02:00
Christoph Oelckers
798cf2f973
Merge branch 'newrenderer2' of https://github.com/coelckers/Raze-private into newrenderer2
2021-04-12 20:25:56 +02:00
Christoph Oelckers
aebcc13c4a
- migrated voxel parsing stuff.
2021-04-11 18:37:11 +02:00
Christoph Oelckers
c33eea2540
- migrating 'tint .def command.
2021-04-11 15:23:42 +02:00
Christoph Oelckers
42d02834b1
Merge branch 'master' into newrenderer2
...
# Conflicts:
# source/build/include/build.h
# source/build/src/polymost.cpp
# source/build/src/voxmodel.cpp
# source/core/gamecontrol.cpp
# source/core/gamestruct.h
# source/games/blood/src/animatesprite.cpp
# source/games/blood/src/misc.h
# source/games/blood/src/view.cpp
# source/games/duke/src/render.cpp
# source/games/sw/src/draw.cpp
# source/games/sw/src/game.h
# source/games/sw/src/jsector.cpp
# source/glbackend/glbackend.cpp
2021-04-11 14:38:56 +02:00
Christoph Oelckers
0ee28fb45e
- also handle SW's voxels.
2021-04-11 13:38:23 +02:00
Christoph Oelckers
9fd3ab6b5e
- fixed texture precaching.
...
After the migration to GZDoom's full backend this never created any textureds when precaching things.
2021-04-11 09:59:55 +02:00
Mitchell Richters
e76f63e2c0
- Consolidate all game interpolation code into inline functions.
2021-04-11 16:45:35 +10:00
Christoph Oelckers
0bdbf0f1cb
- fixed: alpha was never set for voxels.
...
Fixes #304
2021-04-11 08:26:36 +02:00
Christoph Oelckers
a5ed7ba8a3
- two more simple .def commands.
2021-04-10 16:35:29 +02:00
Christoph Oelckers
6b684e74ba
- migrated 'texture' .def command.
2021-04-10 14:09:08 +02:00
Christoph Oelckers
057b8a7354
- cleanup of bvectan family of functions.
...
This can be greatly simplified to a single bvectangbam function using atan2 directly.
2021-04-10 12:54:29 +02:00
Christoph Oelckers
b4d89cbac3
- got rid of the remaining occurences of gethiq16angle and all related tables.
2021-04-10 12:10:28 +02:00
Christoph Oelckers
92697686cb
- migrated a few more .def commands.
2021-04-09 19:59:03 +02:00
Christoph Oelckers
333581a084
Merge branch 'master' into newrenderer2
...
# Conflicts:
# source/build/src/defs.cpp
2021-04-09 19:57:56 +02:00
alexey.lysiuk
57c7a85d9f
- fixed compilation with Clang
...
source/build/src/defs.cpp:3198:56: error: cannot pass non-trivial object of type 'FString' to variadic function; expected type from format string was 'char *' [-Wnon-pod-varargs]
2021-04-09 15:55:30 +03:00
Christoph Oelckers
fb02b38279
- better .def loading logic.
...
To allow cumulative loading without interfering with other ports, Raze will now look for files called xxxx-raze.def, where xxxx is the default .def name (e.g. duke3d-raze.def for Duke3D.) and if that is found, cumulatively load all same-named files - it will fall back on the default name if no such thing is found.
-def still overrides both and will not cumulatively load.
2021-04-09 14:30:01 +02:00
Christoph Oelckers
778a75c097
- fixed rffdefineid handler passing a bad file name to the backend.
2021-04-08 21:36:52 +02:00
Christoph Oelckers
9f08f9786a
- consolidated a bit of dead content in .def parser.
2021-04-08 20:03:50 +02:00
Christoph Oelckers
794cab2d54
- removed some dead code.
2021-04-08 18:54:39 +02:00
Christoph Oelckers
cecd34efc7
- moved a bit more script parsing functionality into the backend and tried it out on the 'skybox' command.
2021-04-08 14:00:08 +02:00
Christoph Oelckers
38ecfc8fa5
- added handling for cubemapped skyboxes.
2021-04-08 12:47:31 +02:00
Christoph Oelckers
5c2335bbeb
- encapsulate setuptile(range) parsing in separate functions.
2021-04-06 16:22:24 +02:00
Christoph Oelckers
0b79649dc2
Merge branch 'master' into newrenderer2
2021-04-06 16:14:21 +02:00
Christoph Oelckers
d193e199f1
- reorganized hightile offset storage.
2021-04-06 15:55:33 +02:00
Christoph Oelckers
424c0ce3f4
- testing some script parser improvements.
2021-04-06 15:07:12 +02:00
Christoph Oelckers
7a9e58c31e
- removed redundant cstat.h file.
...
Constants are already defined in buildtypes.h
2021-04-05 18:05:43 +02:00
Christoph Oelckers
e30dc82676
- Cleanup of the voxel code.
...
* moving polymost_voxdraw into polymost.cpp.
* consolidated all remaining voxel code in hw_voxels.cpp. All original Build voxel code is completely gone now, except for polymost_voxdraw, so this got moved out of the build/ folder.
* integrate Blood's voxel init code into the main function.
* some further cleanup was allowed as a result of this, so engineInit is gone now because these parts can now be done outside the games' app_init functions.
2021-04-05 18:05:43 +02:00
Mitchell Richters
be8df3488d
- build.h: Remove function prototypes for now static functions within engine.cpp
.
2021-04-05 20:28:57 +10:00
Christoph Oelckers
8e31c34b06
- fixed tileImportFromTexture.
...
* the parser read numbers with leading zeros as octal, which is not wanted here
* texture lookup by file name must be forced for root directory entries.
2021-04-04 21:02:04 +02:00
Christoph Oelckers
8055ff1d86
- fixed tileImportFromTexture.
...
* the parser read numbers with leading zeros as octal, which is not wanted here
* texture lookup by file name must be forced for root directory entries.
2021-04-04 21:00:41 +02:00
Christoph Oelckers
c303884274
- better handling for Duke's scrolling cloudy skies.
...
* Using the Doom-style dome here because it looks better.
* this necessitated changes to the backend to allow both types of sky domes at the same time
* do not clamp panning fields for cloudy sky with the new renderer because this makes the texture jump.
2021-04-04 20:35:38 +02:00
Christoph Oelckers
55ad51ee1f
Merge branch 'master' into newrenderer2
2021-04-04 13:23:51 +02:00
Christoph Oelckers
97a0cb2a10
- handle voxel rotation in the backend to enable it for all games.
...
This was previously only present in the Blood module and missed in Exhumed from upstream so the entire option was rather pointless.
Fixes #290
2021-04-04 10:33:29 +02:00
Christoph Oelckers
952bccbf5f
- added a check for game-side-defined voxels when discarding one-sided wall sprites viewed from the back.
2021-04-03 21:49:28 +02:00
Christoph Oelckers
9c95c902c7
- added a check for game-side-defined voxels when discarding one-sided wall sprites viewed from the back.
2021-04-03 21:40:16 +02:00
Christoph Oelckers
638f19172a
- voxel rendering.
...
The stock voxels of Blood and SW seem to work so far, but not all edge cases have been tested.
2021-04-02 18:20:07 +02:00
Christoph Oelckers
c8a75a8664
- give each DrawInfo its own list of tsprites.
...
Since these do not fully get processed sequentially the contents need to be preserved until needed.
This required getting rid of the global tsprite array. Polymost still uses a static vatiable, though, but this is only accessed in polymost-exclusive code.
2021-04-02 10:28:40 +02:00
Christoph Oelckers
80e5cd0dc5
- fixed some automap issues:
...
* Blood's automap was not drawn at all.
* SW's automap always showed all sectors
* SW's player sprite was not rendered.
* Non-automap: Forward gotsector to the game code because there's still a few places in Blood that need it.
2021-04-01 20:47:05 +02:00
Christoph Oelckers
7bea8ad6ba
- fixed texture overlays for SW's sector portals.
2021-03-30 23:27:11 +02:00
Christoph Oelckers
4647a0b2bc
- fixed cases of small textures being used for the sky.
...
Case in Point: DukeDC uses a 64x64 texture with palette remap for the sky.
2021-03-29 23:25:43 +02:00
Christoph Oelckers
e7d73fd8e7
- fixed clipping code.
...
This seems to require the old code as-is - the latest refactoring broke some stuff again and had to be reverted.
2021-03-27 15:04:16 +01:00