Commit graph

208 commits

Author SHA1 Message Date
Sally Coolatta
02605a5ace Split bot code into multiple files & clean up 2020-05-24 15:08:10 -04:00
Sally Coolatta
56867fb203 Going above top speed makes radius smaller 2020-05-24 11:13:20 -04:00
Sally Coolatta
edfc14c506 Better steering
- If they're already turning in one direction, they are more likely to steer in that direction for objects
- Bots have to want to turn in 1 direction for a few frames in a row before it'll let them

Prevents twitching & makes them less indecisive in general
2020-05-24 11:12:38 -04:00
Sally Coolatta
38ec153e90 A bit redundant 2020-05-22 20:49:33 -04:00
Sally Coolatta
f442b934cc Adjust wall steer radius with speed 2020-05-22 20:20:17 -04:00
Sally Coolatta
19f352e4a4 Commentate K_BotReducePrediction better, use angle rather than distance for path split picking 2020-05-22 20:19:58 -04:00
Sally Coolatta
1ec651ff00 Combine K_FindRandomItems & K_FindEggboxes 2020-05-18 15:30:55 -04:00
Sally Coolatta
c3a5193150 Remove this code, it's in grand-pricks & functional now 2020-05-18 15:19:48 -04:00
Sally Coolatta
7bdb1e9458 Rival always rubberbands to the front of the pack 2020-05-14 02:23:03 -04:00
Sally Coolatta
482141a95f Reduce spacing between bots 2020-05-13 02:47:10 -04:00
Sally Coolatta
fa5fccffc5 Implement lives system
Lose a life & restart the current race if you place below the top half. Lose all of your lives, and you get kicked to the title screen.
2020-05-13 02:14:39 -04:00
Sally Coolatta
2282fa7452 Adjust bot rubberbanding distance with game speed 2020-05-10 00:17:36 -04:00
Sally Coolatta
4a3262da41 Initial GP commit
Has a rudimentary option in the menu, which spawns the specific bots & spawns you on Green Hills in singleplayer.
2020-05-09 03:42:51 -04:00
Sally Coolatta
9429ae80e1 Only do this if you're the server :VVV 2020-05-07 22:19:32 -04:00
Sally Coolatta
efc8ce335c Rubberbanding spacing was reworked
Instead of the spacing being completely difficulty dependent (which would cause them not to rubberband to 1st place if they were any difficulty lower than 9), it's based on their difficulty & overall race standings & a little bit of port priority instead. This enables you to see a pesudo "rival" even when every bot is the same difficulty.
2020-05-07 04:07:13 -04:00
Sally Coolatta
d2172fc54b Bot amount & difficulty is now controlled by cvars 2020-05-07 02:37:06 -04:00
Sally Coolatta
3b6a2fed77 Make the safe distance from the road farther 2020-05-04 21:46:00 -04:00
Sally Coolatta
cb34ea1388 Consider FOFs when figuring out sectors to be careful near 2020-05-02 02:01:39 -04:00
Sally Coolatta
69e5cf8205 Bots can use bubble shield and flame shield, albiet a bit simplisticly
This means they can now use ALL items!
2020-05-01 23:44:03 -04:00
Sally Coolatta
664a9528ed Eggbox stuff
- Bots can roll & use eggboxes now
- Bots can be "tricked" by eggboxes and treat them like normal items, depending on their difficulty and how many normal items are around them.
- If exploding and in 1st place, they'll slow down to try and find someone to explode next to.
- Item usage is difficulty dependent, and thus far more aggressive for the rivals
2020-05-01 22:55:58 -04:00
Sally Coolatta
b9e24d921c Bots reduce their rubberbanding top speed if they're facing the wrong way 2020-04-30 17:28:34 -04:00
Sally Coolatta
1fcfdd5bae Bot hints
Thing type 2004, adds a map-defined point for bots to gravitate towards or away from.
Angle: Changes radius, defaults to a 32 radius (or 64x64 area) without.
Ambush: When off, makes bots steer towards. When on, makes bots steer away.
Parameter: Changes how much the bot steers away/towards this point. If 0, defaults to 2.

(also, made bots ignore strong offroad if they could take a shortcut)
2020-04-30 14:15:10 -04:00
Sally Cochenour
c06c4049c4 Bots play more careful around damage, insta-kill, and strong offroad 2020-04-28 14:24:09 -04:00
Sally Cochenour
44334602e5 New "wall steering"
Rather than trying to steer away from walls (and failing), just pull the predicted point back and make the radius stricter.

Not an ideal solution compared to what the other method was trying to go for, but this has a better success rate -- and even in cases where false positives come up (like many instances Ezo pointed out), they will no longer be incapacitated by it.
2020-04-27 17:06:36 -04:00
Sally Cochenour
be70afcbbd Object steer polishing
Notably, looks in an oval area instead of a circle
2020-04-27 13:42:01 -04:00
Sally Cochenour
80b59382f4 Tighten up radius slightly 2020-04-26 22:41:00 -04:00
Sally Cochenour
6846d7c3a1 Bring back strong rubberbands now that they can properly predict 2020-04-26 20:36:57 -04:00
Sally Cochenour
6b3e7c8e16 Adjust prediction future sight based on the bot's handling 2020-04-26 20:36:40 -04:00
Sally Cochenour
4ec61a2e11 Subtract your distance to the nextwaypoint from the distance to predict ahead
Helps the GHZ turn out a LOT, and other instances with waypoints far apart from each other
2020-04-26 13:06:53 -04:00
Sally Cochenour
f920dd026d Minor things 2020-04-22 21:53:52 -04:00
Sally Cochenour
4bd88e47e3 Polishing turn stuff 2020-04-22 21:53:41 -04:00
Sally Cochenour
99cf835078 Improved banana usage 2020-04-22 19:13:14 -04:00
Sally Cochenour
422f528056 Remove prints, adjust things 2020-04-19 10:12:02 -04:00
Sally Cochenour
21bab775b1 Add difficulty settings 2020-04-19 09:07:29 -04:00
Sally Cochenour
39964491e2 Don't steer toward rings when you have Thunder Shield 2020-04-19 05:27:44 -04:00
Sally Cochenour
d0a6c43c89 Minor things 2020-04-09 02:52:41 -04:00
Sally Cochenour
fe376a388b Slight adjustments 2020-04-07 00:53:43 -04:00
Sally Cochenour
3f639b4f8a Rubberbanding! 2020-04-07 00:40:44 -04:00
Sally Cochenour
dbb52e4aa5 Use bananas, orbinauts, jawz, mines, and ballhog
Yaaay

Bananas and mines could definitely be improved, but works for now
2020-04-05 02:14:40 -04:00
Sally Cochenour
6ecad2e73a Reduce steering code duplication 2020-04-05 02:13:39 -04:00
Sally Cochenour
b983031587 Yet more misc polish since I can't focus on orbis
- Massive improvements to object steering -- they do it more often and more strongly
- Steering towards hurtable players is now weighted on acceleration, and steering away from painful players is weighted on handling
- Bots now can get & use Thunder Shield
- Bots now know how to detontate Eggman Item explosions early
- Top speed gets a buff to make up for them losing lots of speed without drifting, weighted more heavily towards low acceleration characters
2020-04-04 01:42:56 -04:00
Sally Cochenour
ccc7ac8cad More misc polish
- Steer against objects more often
- Reduce steering toward rings
- Only steer towards items/rings in front of them
- Be slightly less trigger happy with using rings/shoes while boosting
2020-04-03 16:39:43 -04:00
Sally Cochenour
578f4ae2c1 Slight tweaks to object dodging 2020-04-03 13:42:27 -04:00
Sally Cochenour
5dec13c848 Fix ring values being flipped 2020-04-03 13:36:33 -04:00
Sally Cochenour
ec9a023814 Object steering
Bots will steer *towards* rings, items, ring-stingable players, and players with lower weight. They will steer *away* from projectiles, traps, players using damaging items (such as invincibility), players with shields, and players with higher weight.
2020-04-03 00:38:24 -04:00
Sally Cochenour
52960459a3 Minor variable changes 2020-04-02 15:08:48 -04:00
Sally Cochenour
ebbcf8d7fd Make bots slow down on turns less often 2020-04-02 14:54:00 -04:00
Sally Cochenour
425220a109 Remove print 2020-04-02 00:45:01 -04:00
Sally Cochenour
08fab7e274 Merge branch 'pet-robo' of https://git.magicalgirl.moe/KartKrew/Kart into pet-robo 2020-04-02 00:44:40 -04:00
Sally Cochenour
8f450f2128 Steer bots away from walls 2020-04-02 00:43:42 -04:00