Commit graph

8371 commits

Author SHA1 Message Date
Christoph Oelckers
39ca524185 - converted FuncRa to a class. 2021-10-15 22:57:53 +02:00
Christoph Oelckers
335ebe9272 - converted queen funcs to classes 2021-10-15 22:55:03 +02:00
Christoph Oelckers
93b0a35927 - converted FuncPlayer into a class 2021-10-15 22:19:07 +02:00
Christoph Oelckers
f13e1f2127 - converted all FuncObjects to classes. 2021-10-15 22:14:14 +02:00
Christoph Oelckers
3bda4d5b07 - converted FuncMummy into a class 2021-10-15 22:02:06 +02:00
Christoph Oelckers
008825fe32 - converted FuncCreatureChunk into a class. 2021-10-15 21:58:07 +02:00
Christoph Oelckers
b772200dd4 - converted FuncLion into a class 2021-10-15 21:29:24 +02:00
Christoph Oelckers
45e7b7c4d5 - converted FuncLavaDude(Limb) into classes 2021-10-15 21:25:53 +02:00
Christoph Oelckers
e73725a40e - converted FuncGrenade into a class. 2021-10-15 21:20:28 +02:00
Christoph Oelckers
cdc7fba8a0 - converted AIFish(Limb) into classes 2021-10-15 21:17:25 +02:00
Christoph Oelckers
8f9e9de4b4 - converted FuncBullets into a class. 2021-10-15 21:11:01 +02:00
Christoph Oelckers
832b394561 - converted FuncBubble into a class. 2021-10-15 21:07:58 +02:00
Christoph Oelckers
0fc490bf40 - converted FuncAnubis into a class. 2021-10-15 21:07:33 +02:00
Christoph Oelckers
ce78b23fb6 - converted FuncAnim into a class 2021-10-15 21:06:53 +02:00
Christoph Oelckers
d130a43aa0 - preparations for cleaning up Exhumed's event dispatcher. 2021-10-15 18:51:22 +02:00
Christoph Oelckers
b725adc426 - Exhumed: split up the message word for event messages. 2021-10-15 18:49:35 +02:00
Christoph Oelckers
2ee7be0382 - Exhumed: split up the value parameter of the run list. 2021-10-15 18:37:39 +02:00
Christoph Oelckers
719081824a - exhumedactor.h added. 2021-10-15 00:18:37 +02:00
Christoph Oelckers
d2beee587d - updated version.h. 2021-10-14 22:50:12 +02:00
Christoph Oelckers
2396c89fb9 - migrated EVENT to use its actor pointer. 2021-10-14 21:59:49 +02:00
Christoph Oelckers
f430c28f88 - split up evSend
# Conflicts:
#	source/games/blood/src/nnexts.cpp
2021-10-14 21:59:49 +02:00
Christoph Oelckers
efc791ee00 - route all remaining calls to evPost and evKill through type specific variants. 2021-10-14 21:59:41 +02:00
Christoph Oelckers
b64aede68e - made patrolBonkles local to the only function using this array. 2021-10-14 20:31:45 +02:00
Christoph Oelckers
71b144023d - renamed evPost to evPostActor and evKill to evKillActor for clarity. 2021-10-14 20:31:17 +02:00
Christoph Oelckers
0ab33b7ffe - need to pass the actor separately to getDataFieldOfObject.
We cannot use rxindex anymore.
2021-10-14 20:28:56 +02:00
Christoph Oelckers
e32ac93d96 - use the actor pointer in rxBuckets. 2021-10-14 20:27:36 +02:00
Christoph Oelckers
b449e0a43b - event redirectors for rxBuckets. 2021-10-14 20:26:42 +02:00
Christoph Oelckers
40a8cd7fa3 - playerQavSceneProcess handled for rxBuckets 2021-10-14 20:25:10 +02:00
Christoph Oelckers
db9d4efdc9 - handled 4 aiFight functions for rxBuckets. 2021-10-14 19:53:08 +02:00
Christoph Oelckers
0ef388538d - refactored 'mate' function for rxBucket. 2021-10-14 19:51:49 +02:00
Christoph Oelckers
1d04ce90e4 - first batch of rxBucket refactoring. 2021-10-14 19:49:18 +02:00
Christoph Oelckers
5d0086cb49 - renamed RXBUCKET.index to rxindex.
This will be needed for refactoring for easier lookup.
2021-10-14 19:41:22 +02:00
Christoph Oelckers
93e909dd58 - use actors in the CFX interface. 2021-10-14 19:41:01 +02:00
Christoph Oelckers
77c827e817 - renamed evKill and added an actor pointer to EVENT struct. 2021-10-14 19:37:53 +02:00
Christoph Oelckers
1e1764eda6 - got rid of fxSpawn. 2021-10-14 19:36:25 +02:00
Christoph Oelckers
085bd3a165 - replaced all fxSpawn calls with fxSpawnActor. 2021-10-14 19:35:05 +02:00
Christoph Oelckers
fbe2373972 - started cleanup of evPost calls by renaming the internal functions.
This just renames things - no changes in functionality.
2021-10-14 19:07:51 +02:00
Christoph Oelckers
2a1f31581c - added null pointer checks to all event callback functions. 2021-10-14 19:07:24 +02:00
Christoph Oelckers
add368433e - sanitized callback interface. 2021-10-14 19:07:00 +02:00
Christoph Oelckers
143e947839 - renamed variable for consistency. 2021-10-14 19:02:48 +02:00
Christoph Oelckers
562968262c - moved spriteMass into DBloodActor 2021-10-14 19:01:10 +02:00
Christoph Oelckers
5519596a94 - refactored global sprite index arrays into pointer arrays. 2021-10-14 18:43:56 +02:00
Christoph Oelckers
b60caa362e - fixed bad merge 2021-10-14 01:15:05 +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
88e86b4248 - added 0 checks to all divisions for calculating dudeSlope.
I had it happen once that an actor was targeting itself here which resulted in zero distance and a division by zero exception.
2021-10-14 00:06:34 +02:00
Christoph Oelckers
46d2c52b19 - use correct math to access a texel's center for rendering voxels.
No idea if this was causing problem, but it surely wasn't 100% correct.
2021-10-13 00:12:58 +02:00
Christoph Oelckers
8d9d3d5f8f - disabled palette emulation for the GLES backend.
Right now the shader does not support it and will require significant redesign to work well with the target hardware.
2021-10-13 00:09:18 +02:00
Christoph Oelckers
a358cf8516 - SW: eliminated all SPRITE_TAG# macros. 2021-10-12 22:21:08 +02:00
Christoph Oelckers
b1ac1ad585 - more changesprite* renaming. 2021-10-12 21:36:42 +02:00
Christoph Oelckers
2e37cc627c - function renaming for clarity and easier lookup. 2021-10-12 21:36:42 +02:00
Christoph Oelckers
895ecc81bc - const-ified some static arrays.
# Conflicts:
#	source/games/blood/src/nnexts.cpp
2021-10-12 21:36:42 +02:00
Christoph Oelckers
3ea4c94266 - removed a few static array references. 2021-10-12 21:36:42 +02:00
Christoph Oelckers
a318129ff3 - iterators in ambient sound code. 2021-10-12 21:36:41 +02:00
Christoph Oelckers
3454fc397e - a few target_i removed.
# Conflicts:
#	source/games/blood/src/ai.cpp
2021-10-12 21:36:41 +02:00
Christoph Oelckers
dc5d32f510 - two missed iterators. 2021-10-12 21:36:41 +02:00
Christoph Oelckers
13348ca428 - a tiny bit of code cleanup. 2021-10-12 21:36:41 +02:00
Christoph Oelckers
b240d2b5bd - aiunicult.cpp is done. 2021-10-12 21:36:41 +02:00
Christoph Oelckers
013eadfd9f - genDudePrepare 2021-10-12 21:36:18 +02:00
Christoph Oelckers
fb5916a3dd - canSwim et.al. 2021-10-12 21:29:12 +02:00
Christoph Oelckers
acec23e034 - ensure the 'slave' array in genDudeExtra is always free of gaps.
This will ensure that adding entries won't accidentally overwrite things.
2021-10-12 21:29:11 +02:00
Christoph Oelckers
6bee3b5ba0 - updateTargetOfSlaves, also storing the slave data as pointers and major cleanup of this function. 2021-10-12 21:29:11 +02:00
Christoph Oelckers
c42e26351e - genDudeSpawn, genDudeTransform and updateTargetOfLeech. 2021-10-12 21:29:11 +02:00
Christoph Oelckers
e41fcb92ab - cleanup and formatting noise again. 2021-10-12 21:29:11 +02:00
Christoph Oelckers
f4fd2a770b - dudeLeechOperate 2021-10-12 21:29:11 +02:00
Christoph Oelckers
e415d93283 - doexplosion 2021-10-12 19:23:25 +02:00
Christoph Oelckers
b1f55434a2 - getRecoilChance + getDodgeChance 2021-10-12 19:23:25 +02:00
Christoph Oelckers
b70368050a - getDispersionModifier and getRangeAttackDist. 2021-10-12 19:23:25 +02:00
Christoph Oelckers
9801ce25dd - scaleDamage 2021-10-12 19:23:24 +02:00
Christoph Oelckers
544145fe4b - reformatting noise split from a larger commit. 2021-10-12 19:23:24 +02:00
Christoph Oelckers
c715ded287 - dudeIsMelee 2021-10-12 19:23:24 +02:00
Christoph Oelckers
eb478ba580 - getNextIncarnation
Event queue handling not refactored yet.
2021-10-12 19:23:24 +02:00
Christoph Oelckers
d892efb78a - killDudeLeech 2021-10-12 19:23:24 +02:00
Christoph Oelckers
040049f83e - more leech stuff.
# Conflicts:
#	source/games/blood/src/ai.cpp
2021-10-12 19:23:23 +02:00
Christoph Oelckers
d2f16ec8ab - leechIsDropped, pLifeLeech 2021-10-12 19:23:23 +02:00
Christoph Oelckers
d907627156 - spriteIsUnderwater 2021-10-12 19:23:23 +02:00
Christoph Oelckers
75258c8b29 - playGenDudeSound. 2021-10-12 19:23:23 +02:00
Christoph Oelckers
ea63229251 - some minor cleanup in aiunicult.cpp.
# Conflicts:
#	source/games/blood/src/aiunicult.cpp
2021-10-12 19:23:22 +02:00
Christoph Oelckers
05571de93a - genDudeUpdate handled. 2021-10-12 19:23:22 +02:00
Christoph Oelckers
49f75e6f51 - 2 more function changed to use actor parameters. 2021-10-12 19:23:22 +02:00
Christoph Oelckers
805ae48607 - ThrowThing cleanup.
Mostly use of VS's rename function.
2021-10-12 19:23:22 +02:00
Christoph Oelckers
c848518746 - use actor parameter in all calls to aiGenDudeNewState.
# Conflicts:
#	source/games/blood/src/aiunicult.cpp
2021-10-12 19:23:22 +02:00
Christoph Oelckers
9de6c7df46 - reformatting commit.
# Conflicts:
#	source/games/blood/src/ai.cpp
2021-10-12 19:23:22 +02:00
Christoph Oelckers
062b3dbf76 - route all access to genDudeExtra through the method in DBloodActor 2021-10-12 19:23:21 +02:00
Christoph Oelckers
cdacf8e470 - fixed badly resolved merge conflict 2021-10-12 00:07:24 +02:00
Christoph Oelckers
64b67291bc - properly write out the genPatrolStates in savegames. 2021-10-11 23:41:44 +02:00
Christoph Oelckers
f370c0f22f - fixed bad null check in aiProcessDudes. 2021-10-11 23:41:04 +02:00
Christoph Oelckers
c6dc564788 - fixed bad target check (again.) 2021-10-11 23:34:49 +02:00
Christoph Oelckers
ff0c4359e0 - deleted unused inlines. 2021-10-11 23:03:11 +02:00
Christoph Oelckers
afce1aba88 - SW: eliminated the only use of the SPRITE_TAG1 macro. 2021-10-11 23:02:54 +02:00
Hugo Locurcio
91ce22931d Add cvars to control automap line alpha and thickness
This can be used to improve automap readability on high-resolution
displays.
2021-10-11 22:30:39 +02:00
Christoph Oelckers
83944a7191 - fixed uninitialized light index variable for floor sprites. 2021-10-11 22:28:26 +02:00
Christoph Oelckers
351dabdb90 - actFireMissile. 2021-10-10 22:36:12 +02:00
Christoph Oelckers
7eac8b71d5 - removed unused constants 2021-10-10 11:47:19 +02:00
Christoph Oelckers
2af688dd62 - replaced RANDOM_RANGE macro with direct calls to RandomRange 2021-10-10 11:47:19 +02:00
Christoph Oelckers
cc912fbf93 - removed pointless BOUND_4PIX macro 2021-10-10 11:47:19 +02:00
Christoph Oelckers
3220a6d786 - some SW cleanup 2021-10-10 11:47:19 +02:00
Christoph Oelckers
bbe49eee7c - reformatting commit 2021-10-10 11:47:18 +02:00
Christoph Oelckers
6f8a5ee2d2 - Exhumed: replaced a large amount of sprite array accesses with pointers.
No logic changes, this is mainly search & replace.
2021-10-10 11:47:18 +02:00
Christoph Oelckers
c485fce958 - reformatted the actor and ai sources. 2021-10-10 11:47:18 +02:00
Christoph Oelckers
0ee81b2bb8 - refactored the remaining pieces in the ai code to use actors. 2021-10-10 11:47:18 +02:00
Christoph Oelckers
d4439b879c - Blood: added checks to the SEQ code to handle situation where their attached object has been removed from the game. 2021-10-10 11:46:38 +02:00
Christoph Oelckers
62502439d7 - eliminated HITINFO.hitsprite.
This was one of the more annoying sprite index variables because it is part of static global data.
2021-10-09 23:09:09 +02:00
Christoph Oelckers
9b4ee3dc2c - some remaining sprite[] access in ai.cpp
# Conflicts:
#	source/games/blood/src/ai.cpp
2021-10-09 23:09:08 +02:00
Christoph Oelckers
f712a674ce - removed the few remaining uses of actDamageSprite_. 2021-10-09 23:09:08 +02:00
Christoph Oelckers
3ab636a13a - sfxPlay3DSound calls partially migrated. 2021-10-09 23:09:08 +02:00
Christoph Oelckers
741d24b9df - iterators in teslaHit. 2021-10-09 23:09:07 +02:00
Christoph Oelckers
ea7ff0b5eb - parameter stuff in a few weapon functions. 2021-10-09 23:09:07 +02:00
Christoph Oelckers
e64e359d07 - iterators in StompSeqCallback 2021-10-09 23:09:07 +02:00
Christoph Oelckers
39b9ddc04c - target stuff in aiInitSprite 2021-10-09 23:09:07 +02:00
Christoph Oelckers
b8d55feb1e - actor parameter substitution and a few bad constants. 2021-10-09 23:08:44 +02:00
Christoph Oelckers
fbae41ee0a - renamed the sprite variant of aiDamageSprite. 2021-10-09 23:08:43 +02:00
Christoph Oelckers
bbe3f333fa - replaced some GetSpriteExtents calls with GetActorExtents. 2021-10-09 23:08:43 +02:00
Christoph Oelckers
44b0e59127 - aiProcessDudes and aiInitSprite done, completing the main pass over ai.cpp. 2021-10-09 23:08:43 +02:00
Christoph Oelckers
29e245dfce - aiProcessDudes, getting rid of the global cumulDamage array and some reformatting 2021-10-09 23:04:29 +02:00
Christoph Oelckers
6968a072ae - another formatting-only commit.
# Conflicts:
#	source/games/blood/src/ai.cpp
2021-10-09 23:04:29 +02:00
Christoph Oelckers
fe92188b0c - removed the dudeIsPlayingSeq variant taking a sprite parameter. 2021-10-09 23:03:09 +02:00
Christoph Oelckers
890cc4947b - use actor parameters for aiSetTarget and aiActivateDude in several places. 2021-10-09 23:03:09 +02:00
Christoph Oelckers
61d9cd1b17 - switched all aiPlay3DSound calls to use actors. 2021-10-09 23:02:40 +02:00
Christoph Oelckers
bdba52aede - refactored aiDamageSprite. 2021-10-09 23:02:20 +02:00
Christoph Oelckers
10b0bba53e - fixed warnings in Exhumed. 2021-10-08 19:24:45 +02:00
Christoph Oelckers
948f194064 - fixed warnings in Duke. 2021-10-08 19:21:29 +02:00
Christoph Oelckers
8606b2ea5a - fixed warnings in Blood. 2021-10-08 19:09:26 +02:00
Christoph Oelckers
39319a9582 - fixed warnings in common code. 2021-10-08 19:07:56 +02:00
Christoph Oelckers
29769dd673 - fixed engine code warnings pointed out by XCode 13. 2021-10-08 19:06:41 +02:00
Christoph Oelckers
9b047c771c - reformatting of aiDamageSprite, no logic change here. 2021-10-07 22:54:18 +02:00
Christoph Oelckers
c8501f8ea6 - refactored aiSetTarget 2021-10-07 22:54:18 +02:00
carnivoroussociety
e6e9bac04b Add ifdef'd correct code for DUDEEXTRA struct saving 2021-10-07 22:51:43 +02:00
carnivoroussociety
8998d92688 Restore original savename variables for DUDEEXTRA struct 2021-10-07 22:51:42 +02:00
carnivoroussociety
8dbd0f10d3 Refactored DUDEEXTRA struct and correctly init state
# Conflicts:
#	source/games/blood/src/aiboneel.cpp
#	source/games/blood/src/aicerber.cpp
#	source/games/blood/src/aigarg.cpp
#	source/games/blood/src/aighost.cpp
#	source/games/blood/src/aitchern.cpp
2021-10-07 22:51:42 +02:00
Christoph Oelckers
8168c6f85c - use the vel() wrappers in a few more places. 2021-10-07 22:48:08 +02:00
Christoph Oelckers
595893a9a0 - added a few more ValidateTarget calls. 2021-10-07 22:48:08 +02:00
Christoph Oelckers
a3a5e7e90b - renamed aiSetTarget. 2021-10-07 22:48:08 +02:00
Christoph Oelckers
2348dd8848 - backend update from GZDoom
* GLES backend fixes.
* font colorization fixes.
* option menu spacing fix
2021-10-07 22:46:45 +02:00
Christoph Oelckers
49e0c461c2 - Backend update from GZDoom.
This is mainly bringing the GLES backend up to date.
2021-10-07 22:46:45 +02:00
Mitch Richters
61ba58c529 - Duke: Use DeferredGameStart() instead of ChangeLevel() in cheatLevel() to instantly warp to the targeted map, matching DOS behaviour.
* Fixes #529.
2021-10-05 08:50:05 +11:00
Mitch Richters
5732ea0233 Revert "- Blood: Use more precision for flicker, quake and tilt effects."
This reverts commit 3c09f41b43.

* Fixes #554.
2021-10-05 08:43:32 +11:00
Christoph Oelckers
95acafdbac - manual update of NBlood commit 24908021f3b844a73de05632565d55d5b71b577c
- Fix kModernCustomDude is not inheriting sprite size if SEQ have zero repeats
- Damage scale tweaks for kModernCustomDude
- Fix hitscan kModernCondition
2021-09-19 16:35:02 +02:00
Christoph Oelckers
1732d206bd - Blood: fixed flare gun no longer being able to set trees on fire.
Somehow a bad damage type got in here...
2021-09-18 20:13:05 +02:00
Christoph Oelckers
0d4e0d72fb - fixed vertex generation when splitting walls by planes on old hardware. 2021-09-18 13:04:46 +02:00
Christoph Oelckers
01e9d8e5e1 - remaining parts of GLES. 2021-09-18 13:03:36 +02:00
Christoph Oelckers
a3d9cd9a68 - Backend update from GZDoom - mainly for GLES2 support. 2021-09-18 12:20:28 +02:00
Christoph Oelckers
11aea1c5d4 - more target replacements. 2021-09-17 20:49:27 +02:00
Christoph Oelckers
b9f6120380 - handle target validations in AI functions properly.
Now they will all print the function name along with the message and not rely on assert abuse.
2021-09-17 20:49:27 +02:00
Christoph Oelckers
261301bdea - replacing target_i, batch 1.
This was the simple stuff, mostly done by search&replacing common patterns.
2021-09-17 20:49:27 +02:00
Christoph Oelckers
90091965ba - replaced most occurences of target_i in already refactored code. 2021-09-17 20:49:27 +02:00
Christoph Oelckers
7a6629ce6a - renamed XSPRITE::target to target_i.
This is to make searching for it easier as 'target' is a very common word in the source.
2021-09-17 20:49:26 +02:00
Christoph Oelckers
774a015e6b - aiChooseDirection and its subfunctions. 2021-09-17 20:49:26 +02:00
Christoph Oelckers
a79d362b40 - dudeIsPlayingSeq + aiPlay3DSound. 2021-09-17 20:49:26 +02:00
Christoph Oelckers
7054313dd4 - formatting only. 2021-09-17 20:49:26 +02:00
Christoph Oelckers
00d0099333 - removed a few compatibility wrappers. 2021-09-17 20:49:26 +02:00