▣
module · drop-in viewer
asset⌬ modulemoduleprimary: init.luau·part ofpackage racingKit.package·originates fromworld f675db81-c…
drivers
The four AI racer personalities, layered on aiDrivers' driving brains. Each has a `brain` (an aiDrivers personality registered here under an `rk_` name, which the kart's AiDriver drives by) and racing habits RaceAI applies on top: when it fires items, whether it hunts item boxes,…
by·posted 17d ago
What it does
drivers
The four AI racer personalities, layered on aiDrivers' driving brains. Each has a brain (an aiDrivers personality registered here under an rk_ name, which the kart's AiDriver drives by) and racing habits RaceAI applies on top: when it fires items, whether it hunts item boxes, whether it rubber-bands, whether it fights. api uses it to paint and name AI karts; the gallery shows each one.
careful(blue): smooth and tidy, brakes early, keeps a gap, saves items for a clear straight.aggressive(red): late on the brakes, tailgates, overtakes, boosts to pass and drops oil on anyone close behind.itemHappy(yellow): swerves for every item box it can reach and fires what it gets straight away.rubberBand(purple): catches up hard when behind and eases off when far ahead.
Functions
names(): the personality ids (alsoORDER).get(id): a personality (label,blurb,brain,names,color,itemDelay,hunts,rubber,fights), or nil.resolve(id?): the personality forid, orcarefulfor an unknown one.pace(gap): rubber-band pace multiplier from the gap in gates to the racer it measures against (behind is negative); 1 means no change.
Discussion
Scoped to this part · feeds back into the world's score.
Sign in to post.sign in
No comments yet. Be the first.