Commit graph

47 commits

Author SHA1 Message Date
Sally Coolatta
2eff6d7fb5 Bots: Make them stay farther from the beam 2023-05-19 06:08:37 -04:00
Sally Coolatta
f66798f0a7 Bots: Nudge towards other Ring Shooters 2023-05-15 19:44:20 -04:00
Sally Coolatta
5ac7926e39 Prediction nudge is based on original WP radius
Previously based on prediction radius, which meant it was so low that it might barely even nudge at all. Now we try to nudge a lot, but clamp the radius to make it thinner if it goes off-road.
2023-05-13 01:59:07 -04:00
Sally Coolatta
7db53abdf7 Fix object nudge search being too small 2023-05-13 01:23:52 -04:00
Sally Coolatta
a8af5b7616 Improve general bot handling
- Their waypoint radius gets thinner quicker
- Waypoint distance is scaled with each ones' floor slope, instead of done once at the end of the prediction.
- Prediction is pulled back further when it goes through a wall
- Prediction starts earlier and goes less far
- Bots will brake at shallower angles (allows them to brake-turn more often)
- K_AddDodgeObject and K_AddAttackObject now adjust based on the radius of the object
- Fixed K_AddDodgeObject adding to the goto objects instead of avoid objects
- Optimized blockmap search size for K_FindObjectsForNudging
- Current waypoint is no longer cleared each frame
2023-05-10 22:25:24 -04:00
Sally Coolatta
d129422382 Bots can now see TERRAIN-based offroad / damage 2023-05-10 19:55:41 -04:00
VelocitOni
c5372f4ce3 Merge branch 'master' into capsules-improvement 2022-12-14 23:19:34 -05:00
Sally Coolatta
81cefa2697 Gachabom initial pass
They simply use Kitchen Sink's item icon and Orbinaut's sprites.

The forward toss behavior needs fine-tuning to use more MT_BANANA style behavior.
2022-11-28 02:41:42 -05:00
Sally Coolatta
bd337d1494 Bots treat all offroad as wall
Rather than only strong offroad.
2022-11-27 03:00:47 -05:00
MascaraSnake
3b971835ee Add Lua backwards compatibility for FOF flags 2022-10-09 01:56:50 -04:00
Nev3r
5c9599f0a9 "UDMF: The whole thing" merged
See merge request STJr/SRB2!1714

Barely any RR features reimplemented
2022-10-09 01:13:37 -04:00
Sally Coolatta
f9c4f66931 Add duel bomb objects
Basically a landmine, but strafes back and forth. Currently uses SPB sprites, IDK if we'll end up replacing it later.
2022-09-28 01:47:56 -04:00
Sally Coolatta
b0e3840550 Add jawz.c + new backwards behavior 2022-09-25 11:27:07 -04:00
Sally Coolatta
4a743369e4 Use K_IsBigger for more remaining old scale checks 2022-09-24 20:00:28 -04:00
Sally Coolatta
892863db05 Add bot support to new Shrink
They move towards lasers that belong to them, and steer away from ones that don't.
2022-09-11 21:52:53 -04:00
Sally Coolatta
7d67e02ea3 Bot perfstats
Show how long they take to think on all of their main tasks
2022-08-27 00:04:33 -04:00
Sally Coolatta
bfa3c40033 Improve bot traversal for the prediction
HatesSector was returning false positive for intangible FOFs, making them play really poorly in Desert Palace
2022-05-31 03:51:35 -04:00
Sally Coolatta
d053d5f8ba Fix blockmap WILD inconsistency when it's not PIT_CheckThing
An optimized error check was put into P_BlockThingsIterator for tmthing, but this meant that anything that was not using or even setting this variable (the supermajority of them) would exit after finding 1 thing in each block.

To keep this error check & keep it optimized, the PIT_ functions were expanded to three options instead of two: BMIT_CONTINUE lets the search continue. If used as the last mobj, it will return true when the iterator finishes. BMIT_ABORT ends the search and forces the iterator to return false.
BMIT_STOP ends the search and forces the iterator to return true.
2022-05-23 17:37:29 -04:00
Sally Coolatta
04aa8259cb Merge branch 'master' into rewrite-lightning 2022-05-21 03:56:12 -04:00
Sally Coolatta
6e8e0ad0f5 Lightning Shield fixs
- Rename to Lightning Shield (it keeps fucking me up when I want to kartgiveitem it to myself)
- Fix inflictors causing damage being considered damage hitlag. Fixes the player using Lightning Shield being in damage hitlag state (most notable in the DI branch because hurting someone with it lets you DI afterwards, which also fucks with your turning)
- Rewrote attack function to use custom blockmap search instead of P_NukeEnemies.
- It can no longer attack below you, only above & around you.
- Increased the attack radius, so that it actually lines up with the sprites...
- Fixed extremely inconsistent ring blockmap search by moving it to playerafterthink (don't ask me why)
- Rings get joulsted by Lightning Shield when you pass by them without
- Added MAXRADIUS to the blockmap checks for lightning shield & mines, to reduce blockmap inconsistencies
2022-05-20 18:12:34 -04:00
Sally Coolatta
46dad4b7dd Start on better bot position 2022-03-30 20:28:08 -04:00
toaster
52d2472ed7 "Drop Target" item initial commit.
Most of the way there, but still a bit left to do.
2022-03-21 23:40:30 +00:00
Sally Coolatta
436b6d50ea Bot predict nudging scale is based on the prediction's radius 2021-12-18 16:31:08 -05:00
Sally Coolatta
19463d6b20 New bot prediction wall detection
Instead of searching for walls around the player, and then deciding to make the radius tighter if it found anyway, it instead checks if the waypoint it's trying to predict towards was blocked by any walls / hazards.

Needs adjusted some, I think its being pulled back too hard sometimes, but I am optimistic about some of the improvements I already saw.
2021-12-10 17:42:00 -05:00
Sally Coolatta
3536c73b66 Fix eggbox stealth being bugged and never being used... 2021-11-28 15:08:54 -05:00
toaster
00972a83d2 remove the prefix since everything seems to function 2021-04-17 11:30:08 +01:00
toaster
b3d006b093 structs gunched 2021-04-17 00:27:13 +01:00
Sally Coolatta
cb655f863c Reduce object distance by its radius
Just gives bot hint size a purpose again, even if it's minor.
2021-02-26 22:43:10 -05:00
Sally Coolatta
03c13052e8 Fix bot hint weighting 2021-02-26 22:37:46 -05:00
Sally Coolatta
ebaef5d0af Flip side properly for objects to go towards. 2021-02-26 19:46:52 -05:00
Sally Coolatta
00227ee7f0 Don't ever go too far behind the bot 2021-02-26 19:42:08 -05:00
Sally Coolatta
9f91c2dcdc Buff the object nudging now that wall detection doesn't step on its toes :) 2021-02-26 19:28:49 -05:00
Sally Coolatta
bbfad3a544 Adjust wall detection
Wall detection range was doubled, how much the prediction is adjusted was halved. This is a much nicer middle-ground compared to what it was doing before.
2021-02-26 19:04:24 -05:00
Sally Coolatta
59fa615cc8 Update comment 2021-02-26 06:12:19 -05:00
Sally Coolatta
c7e061155a Add weighting system back into prediction nudging
Simply adds the same object to the list several times. Necessary because otherwise rings are over-prioritized.
2021-02-26 05:44:57 -05:00
Sally Coolatta
ffaa4e2aa2 Differentiate between which side an object is on
This means that if there's objects on both sides of the bot, then the tie is broken by which side has the most objects. Before, it would average out to the middle, so they wouldn't swerve at all, which is kind of stupid for rings, but can ruin the bot's performance for dodging items & players especially!
2021-02-26 04:26:50 -05:00
Sally Coolatta
7eac54a749 Adjust nudging to values that feel nice 2021-02-26 03:21:33 -05:00
Sally Coolatta
0fb97a1b16 Use the proper variable for the average position 2021-02-26 02:50:20 -05:00
Sally Coolatta
43a92892e9 New turning towards objects style 2021-02-26 01:58:13 -05:00
Sally Coolatta
e16c7d722f Cherry-pick e1b265df2 2020-11-16 19:55:28 -05:00
Sally Coolatta
3e446a167c Restructure how damage works in kart COMPLETELY
Instead of doing its best to avoid P_DamageMobj, it embraces it, using the damagetype system to decide how the player takes damage. Overall less stupid.
2020-08-19 00:55:36 -04:00
Sally Coolatta
51aef1ce75 Fix some of the dehacked tables, change doomednums of haunted heights stuff to not conflict with items/waypoints, use "rings" variable instead of "kartstuff[k_rings]" 2020-08-16 01:46:54 -04:00
Sally Coolatta
9efdc98de6 Makes it through all kart files
All that's left is SDL, OGL, maybe also Lua
2020-08-15 04:42:56 -04:00
Sally Coolatta
42419f7bc6 Add comments for functions 2020-06-04 17:14:14 -04:00
Sally Coolatta
896c6b3952 Rewrite K_BotHatesThisSector slightly
Fixed a lot of its false positives, as well as some copy-paste errors
2020-05-28 17:58:35 -04:00
Sally Coolatta
dbc30da69f Dial back the bot steering changes a bit 2020-05-24 15:55:10 -04:00
Sally Coolatta
02605a5ace Split bot code into multiple files & clean up 2020-05-24 15:08:10 -04:00