Christoph Oelckers
a2e280e188
- use wallsofsector in 4 more places.
...
# Conflicts:
# source/build/src/polymost.cpp
2021-12-26 23:09:57 +01:00
Christoph Oelckers
d3b1e34d78
- moved sprite[], spriteext[] and spritesmooth[] into DCoreActor.
...
Also removed the last remaining sprite pointer in saveable data.
2021-12-26 23:09:55 +01:00
Christoph Oelckers
f855b1020f
- actor lists refactored.
...
No more shorts, no more static arrays.
This was one of the biggest blockers for unlimiting the engine.
2021-12-26 23:09:54 +01:00
Christoph Oelckers
87ac9bee44
- refactored the owner index in tspritetype.
...
This is now a separate type from spritetype which contains an actor pointer instead so that sprite display can be handled without requiring a static sprite array.
# Conflicts:
# source/build/src/polymost.cpp
2021-12-26 23:09:54 +01:00
Christoph Oelckers
eaff9e359f
- refactored the owner index in tspritetype.
...
This is now a separate type from spritetype which contains an actor pointer instead so that sprite display can be handled without requiring a static sprite array.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
793dd032b0
- getzrange cleanup.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
bcc532d36f
- eliminated the getzrange wrapper.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
2541425b9d
- getzrange is free of hack values, too.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
9d85859a80
- finally got rid of the 16 bit hack return value of clipmove.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
d34a5179f1
- sprite cleanup in clip code.
...
Just using already available data instead of the indices.
2021-12-26 23:09:53 +01:00
Christoph Oelckers
19236b2526
- removed compatibility handling for the oldest level from hitscan.
...
This stuff isn't even slope aware so the only legitimate reason for keeping it would be demo playback.
2021-12-26 23:09:52 +01:00
Christoph Oelckers
183f554733
- hitscan cleanup.
...
Also removed a bit of leftover TROR code.
2021-12-26 23:09:52 +01:00
Christoph Oelckers
8c90f48b61
- cleanup of neartag, plus direct return of a HitInfoBase struct.
2021-12-26 23:09:52 +01:00
Christoph Oelckers
a3493048e7
- refactoring of spawn code to prepare for the other games.
...
Map hacks do not work in this commit!
2021-12-26 23:09:51 +01:00
Christoph Oelckers
379c4f1a60
- merged the cansee wrapper into the actual function and added sector validation.
2021-12-26 23:09:50 +01:00
Christoph Oelckers
2654a19cfd
- got rid of setspritez(x) and moved the implementation to SetActor(Z) without referencing the sprite array.
2021-12-26 23:09:49 +01:00
Christoph Oelckers
f9b1164747
- use point2Wall wherever possible.
2021-12-26 23:09:48 +01:00
Christoph Oelckers
83cf2f3baf
-more index stuff.
2021-12-26 23:09:48 +01:00
Christoph Oelckers
ee1b574830
- engine stuff
2021-12-26 23:09:48 +01:00
Christoph Oelckers
a22634f228
- sectnum reduction.
2021-12-26 23:09:47 +01:00
Christoph Oelckers
ed659df9d8
- pass sector pointer to Polymost's SectorVisibility function.
2021-12-26 23:09:47 +01:00
Christoph Oelckers
d33ae89c4a
- minor backend cleanup.
2021-12-26 23:09:45 +01:00
Christoph Oelckers
befc4572e9
- minimal backend array removal.
2021-12-26 23:09:45 +01:00
Christoph Oelckers
12f6b05cbe
- use access functions, all done by search & replace.
2021-12-26 23:09:44 +01:00
Christoph Oelckers
6748a39c8f
- deprecate the sector index variant of pushmove
2021-12-26 23:09:43 +01:00
Christoph Oelckers
2aefe4398b
- sector[tspr->sectnum] globally replaced.
2021-12-26 23:09:43 +01:00
Christoph Oelckers
70d7e81f4f
- adapted getzrange to the new interface.
...
This was mainly removing game side solutions in favor of a common one in the backend.
2021-12-26 23:09:42 +01:00
Christoph Oelckers
91e2391911
- adapted neartag in Duke.
2021-12-26 23:09:42 +01:00
Christoph Oelckers
4788c7ba5e
- made Collision derive from a common base class and refactored clipmove to a single engine-side entry point.
...
Done for Doom so far.
2021-12-26 23:08:57 +01:00
Christoph Oelckers
9380819e4e
- initialize actorArray for all games.
...
- the foundation for an actor aware backend.
2021-12-26 23:08:56 +01:00
Christoph Oelckers
69a7b4d0bc
- final cleanup before replacement
2021-12-25 21:28:55 +01:00
Christoph Oelckers
d30bf8c8bb
- fixed Blood's mirror render hack for Polymost.
...
This adds 4 walls and 1 sector without counting them, so we must adjust allocations and array access to handle OOB access and temporarily increase the counter for the mirror render pass.
The new renderer does not need this stuff.
2021-12-25 21:28:50 +01:00
Christoph Oelckers
8cca55c24a
- made wall a TArray.
2021-12-25 21:28:50 +01:00
Christoph Oelckers
fded90c491
- SW: deleted SECT_USER.
2021-12-25 21:28:49 +01:00
Christoph Oelckers
7d2404ce76
- made sector a TArray.
2021-12-25 21:28:49 +01:00
Christoph Oelckers
999ec3c95a
use validSectorIndex checks where appropriate.
...
Let’s hope that this sloppiness doesn’t have negative effects with broken maps.
# Conflicts:
# source/games/sw/src/sprite.cpp
# Conflicts:
# source/games/duke/src/prediction.cpp
# source/games/duke/src/render.cpp
2021-12-25 21:28:37 +01:00
Christoph Oelckers
ae8e642785
- templated updatesectorneighborz to eliminate redundancy with updatesectorneighbor
2021-12-25 21:28:36 +01:00
Christoph Oelckers
4daad25e5c
- use WORDS_BIGENDIAN directly in place of B_BIG_ENDIAN
2021-12-14 12:27:41 +01:00
Christoph Oelckers
7daa501a4d
- removed all #include "compat.h" except the one in build.h
...
Still all compiles fine.
2021-12-14 12:24:10 +01:00
Christoph Oelckers
7e2431ebd8
- replaced the remaining content from compat.h
2021-12-14 10:15:58 +01:00
Christoph Oelckers
016a907c20
- replaced vec2_t with FVector2.
2021-12-14 10:07:06 +01:00
Christoph Oelckers
7546cf3a4b
- replaced vec3f_t with FVector3.
2021-12-14 09:58:01 +01:00
Christoph Oelckers
64cad55d73
- fixed updatesector and changed updatesectorz to use the same search algorithm.
...
The initial distance check in updatesectorneighbor had a far too low threshold which would skip the breadth-first search for relatively small distances already.
Exhumed's LEV1 and Duke's Lunatic Fringe were the most obvious candidates where this could cause problems.
Changed to use a mixture of the original updatesector with the revised algorithm so that all immediate neighbors of the start sector will get visited unconditionally.
updatesectorz was still the original function from Shadow Warrior, this also was changed to use the same algorithm as uodatesector.
2021-11-30 00:15:25 +01:00
Christoph Oelckers
f765783437
- various small bits of cleanup.
2021-11-29 00:57:11 +01:00
Christoph Oelckers
35c2d6d14e
- fixed translucent voxel rendering.
2021-11-29 00:57:10 +01:00
Christoph Oelckers
7d3b604361
- fixed sky rendering in paletted sectors for Polymost.
2021-11-29 00:57:10 +01:00
Mitchell Richters
5630fd8763
- Repair other possible OOB access issues with spriteext[]
.
2021-11-29 00:57:09 +01:00
Mitchell Richters
8c679f2e17
- Repair OOB access to spriteext[]
array accidentally introduced in d572e56839
. This repairs stability issues with models enabled under Linux environments.
2021-11-29 00:57:09 +01:00
Christoph Oelckers
adf3133fdc
- use sectnum and wallnum to get an index from pointers instead of subtracting the array base.
2021-11-29 00:56:26 +01:00
Christoph Oelckers
3a259c9c46
- use BFSSearch in cansee and deleted the old variant originally used by Exhumed.
...
This old variant is only useful for demo compatibility, its main difference is that it does not handle slopes, which even for Exhumed is wrong with some custom maps.
2021-11-29 00:56:25 +01:00