SMunger Script AI Race Tutorial (BeamNG.drive)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello and welcome everybody to the songer channel this is your host Steve today I'm going to be going over a tutorial on how I make my uh bmng Drive script AI races for the songer cup series um it's pretty much going to be tutorial from start to finish on how I record my cars um how I line them up the the process and all of that and I'm also going to be giving you an inside look at my auto club race that's coming up race three of eight of season 1 um I'm pretty much going to be recording those cars while I'm making this video so it's going to be almost like two videos in one except not really in one so to start with I'm going to start by spawning in a car um I'm going to start up with the Camaro um because I have a pace car skin for my Series so I always start with the pace car that way so the first car off the Pit Road is the pace car everybody's following and line line I already know the general placement of where my cars should fall in line for when they roll off Pit Road but you want to start by pausing the game so the car isn't moving it's not idling it's just sitting there spawned in ready to go and you want to make sure you have some sort of speedometer on your UI you also want the road grip editor the replay editor the uh wind tool as well as the cruise control control tool the cruise control tool will help you the most in uh like the pace laps cuz you can set a specific speed and then watch the car just idle at that speed all the way around the track you don't have to do anything else with the controls besides just steering the car around and I'm going to set that to 90 M hour for autoc club that should be plenty of speed to get the car around the track but not too fast so I spawn it in I let it roll forward and then I respawn it before I start recording it that way so when the recording starts it's already got some wheel spin on it and then when I go to play it back later the car will always want to jump as soon as it spawns in and there's not much of a stalling issue so you see we're going to follow it up through turns one and turn two we're going to keep it around the middle Lane maybe weave in and out a little bit if you want it's not a big deal if it doesn't stay 100% straight but you do want it to be as close to the middle of the track as possible that way so you can form an inside Lane and an outside Lane with your next group of cars and with the p car as well since it's going to be the lead car you don't want the cars behind it to run it over so when we get up here into turn three I'm going to turn the cruise control tool up I'm going to set it at 92 M hour 91 yeah I think 91 will work so we're going to set it to 91 so that way it will it won't pull away but it won't shorten the distance for the car on the bottom one Lane it'll kind of balance itself out off turn four I'm going to pull off the track I'm going to pull down Pit Road and just let it keep going hit the brake hit the clutch let it free roll you want to slow down as naturally as possible coming down Pit Road maybe you want to set your cruise control at 50 so it keeps a constant uh speed for majority of the distance going down Pit Road you don't have to you you could even just just tap the throttle tap tap tap and hold the clutch in if you want either or is an option but now we're going to pull just past box one here we're going to park the pace car right here at the line and then we're going to hit f11 go back into the world editor and we're going to stop the recording there and then play it back so now the car should follow this red line this red line is the line that you put down now the AI is not exactly the smartest so sometimes it's going to go a little to the right the car goes a little tight it's just the way the car is set up and not only that it's also partially with how the AI in the game in general is also set up there's not really an easy way or a good way to fix that this is where your uh Road grip tool comes in cuz if you change the static friction up to like 1.6 1.7 they'll grip they'll see into the track a little bit better and they won't walk off this line near as much especially at Race speed same thing with the uh gravity if you turn that up to a 12.5 the gravity is pulling your car further down into the track so the static friction being higher and the ravity being stronger your car is going to want to sit better and it's going to sit more accurately on that line on the path line for your car that you've already recorded so now we're going to watch it come off turn four and I'm pretty happy with how the pace car is doing did a pretty good lap so I think we're going to keep this and then after it gets down to the end of Pit Road you want to make sure that it doesn't do anything silly doesn't do anything goofy it doesn't like turn into the pit wall and start throttling up or sometimes it does that the AI gets a little goofy right at the end of the recording so make sure once it comes to a stop that it stays at a stop and doesn't take off on you again um and should be all all good to go yep oh okay and it respawned itself so if you come in here and you hit the more button see where it says Loop turn that off and the car will not respond itself on its own like that again so we're just going to stop it here and I'm going to start working on the pole sitter's car next and I'm just going to jump to me having that that car spawned in all right so the next thing you're going to want to do is the pole sitter for autoc Club the pull sitter is Chad Jones in the 21 but you just want to have your pace car you want to have your pull sitting car and you uh first things first you want to set the cruise control that way so you can get the car to have a rolling start you let it roll forward a little bit pause respawn it then go into World editor play back your pace car start the recording for the pull sitter and make sure to turn the loop off that way so when the puler not the pulsor that way when the pace car pulls off the track and is done it doesn't respawn and roll back into traffic if you turn a loop off if it's on it'll just keep playing in a loop so um and I hit my brake coming off Pit Road so I'm going to have to reset that up my apologies so again put your uh cruise on first play the car respawn the car and then start the recording for the car and you want to keep about a car length and a half to two car lengths behind the pace car if possible preferably use your clutch because it won't shut off your cruise control if you hit your brake it will shut off your cruise control and then you'll have to turn it back on and the car won't keep rolling at the right speed you just have to keep you know playing around with that but if you want to utilize the cruise control to its full extent use your clutch I used the a button on my uh on my controller that I have plugged in so but but you could do that I believe I think it's C on the on the keyboard it's been a while since I've had the the right controls for that so you're going to pull your uh the pull sitter onto the inside Lane going in turn number three keep the inside Lane at 90 on these bigger tracks the outside Lane is actually going to be going slower at the same speed so if the inside car is 90 and the outside car is 90 the inside car is going to Gap him cuz he's going a shorter distance so put your outside Lane at like 92 just in the corner and coming off the corner put it back to 90 the they should line line up pretty good at that point when you get to those two lines on the inside at the very very start is where I like to hit the gas and then coming down the straightaway almost into turn one at the end of The Pit Road where the wall is uh where it ends that's when I clutch in attack my brake a couple of times let it roll through the corner nice and easy get back on the gas about halfway through two it's okay for the car to be a little bit slow because when you play with the camera and cinematic mode it doesn't look it really doesn't look that slow but but these cars really aren't going that fast because they tend to drift up higher than you really want them to they tend to be a little tight so we're going to go up high and three and four you don't really want to go above the second lane or else you will get into the wall and I'm going to go ahead and speed it up for the next few laps because we're just going to repeat the same thing for the next six laps that's how long we're going to be doing this race all right the damage isn't too bad I smacked the wall coming off of four there but it's driving straight right so we're going to leave it like that but we're going to put them back down on the bottom here for a few laps but at the end of six laps what you're going to want to do is you don't have to hit your brake uh but you can just stop uh you're uh playing on the gas I drive it on gas I don't actually set a set speed for the laps I'm just holding the gas puddle down I'm getting as much speed as I can on the cars but at the end of lap six whatever you want to do just let off the gas let it free Roll But set the cruise control back on to 90 it's not going to lock up your brakes or or make you make you slow down real fast but it will allow you to just Coast down to 90 and then stay at 90 and you don't have to worry about getting back on the gas so I'm going to go ahead and cut ahead that way so we can just watch the replay of the car going around making its laps but he should maintain about a lap or not lap about a car length and a half back and at this point is when I like to play around with the road grip editor some I only really do the static friction and I put that at about 1.6 1.7 it helps the car sink into the track a little better hi hydronic function is good at bringing the car more grip like a lot more grip but if you hit the wall with it at 0.01 the car is liable to do some wacky stuff sometimes so I I don't put it on for the sake of trying to keep it kind of realistic and turn your gravity up to about a 12 12 and 1 12 you could even go up to 13 13 and a half uh cuzz that's also pulling the car further down into the track so between that and static uh friction you should have enough grip in the car that it shouldn't want to walk up really above whatever the line is set for on it uh for the for uh Chad Jones case there going to be this red line here going to go ahead and speed it up here that way so we don't have to watch six laps in real time but he should pretty much stick to whever we originally recorded the line even where I hit the walls the two times where I did I believe it was once in three and four and then once getting into one and two I don't think I got it there I might have clipped it I definitely got it there but but he should sit right in the track the way I drove it and it's not a lot of change in the grip and it's not a lot of change in the gravity but it is a lot of driving the car like paying attention to how you run it into the corners you do want to let up early for the corners you do want to let it Coast into the corner you do want to let it free roll as much as physically possible cuz when you're on the brake it tends to lock up and when it locks up it gets tight and shoots into the wall so if you just clutch in on Entry maybe tap the break a couple of times before you start making your turn and free roll the corner most of the time it should stick to pretty much whatever you recorded it to be and it's staying pretty close to the lines for the most part here in this recording too at the end here he should slow down coming into turn one and Coast down to about 90 and then he will pull back down Pit Road and Coast down into box number one for the end of the race it's not it's really not a difficult process guys it's just super time consuming like I'm I'm speeding this up four times and for five six minutes of footage on end here and this is still almost a 20 minute video all right so he's going to go ahead and pull down into box number one and he should park it and not respawn play on his own just like how the pace car is down there and again it's just a long process so I'm going to skip ahead to where I have more cars spawned in I'll be right back all right guys so at this point you should have however many cars you want to spawn in and recorded it is the same process every single time for every car just drive it drive it as hard and as fast as you can but trying to keep it within one lane off the wall and certain distances off of each other try and keep it about a car length and a half is the easiest way to control it on these rolling starts you can use the clutch to slow down the lead cars and bring them towards the cars in the rear and then Bunch them back up for the start see how they're kind of they are in the right order first second third fourth fifth with the inside Lane slightly ahead and then coming down here into turn number one some of the cars have the ability to drive in a little deeper some of them are a little loose some of them are a little tight but they're making passes they're even hitting three wide here on exit but they have full range and full power to do whatever they want to do without running each other over and as long as you are attentive of your speeds especially on these bigger tracks you don't really want to be doing much more than 140 here at like Auto Club in Michigan much faster than that you'll shoot up into the wall 135 and you'll see the Top Lane pretty good cutting back to uh the leaders up here but they're making passes on each other they're able to change lanes they're able to drive in deep they're able they're able to do stuff and it's just it's a lot of attention to detail more or less the more you learn to and I use a controller because it's a lot easier to drive with a controller than it is with a keyboard uh especially if you don't have a wheel um that's all I've really got on there I I I have a wheel I just don't use it a whole lot but uh but I mean it's not difficult it's really not difficult it's just who really has all day to sit here and do it you know but you can make them change lanes you can make them slow down for the corings later you can make him slow down a little earlier you can make them get two wide three wide four wide but as long as you keep it within like just above that white line and about a a lane a lane and a half off the wall like where Cur is coming up on the outside right here you should have no problems being able to do that as long as you are just super attentive on your speeds coming into your corners and like your your grip settings the whole 9 yards it's just a lot of it's it's just a lot of detail okay I'm surprised it took him three laps to actually make enough contact to make him wreck okay all right well I think I'm going to end it here guys there's not a whole lot more I can add on to it you can do this with five cars you could do this with 15 you could do it with 18 however many you want to do or however many your system can handle but it's the same process over and over you're just driving a car around the track without hitting the wall as little as possible if you guys found this helpful give it a like and if you're not subscribed go ahead and drop a subscribe this is Steve I'll see you guys next time
Info
Channel: SMunger
Views: 1,591
Rating: undefined out of 5
Keywords: SMunger, Crashmandjaro, BeamNG.drive script ai, beamng drive, beamng, beamng nascar, beamng nascar race, beamng tutorial, nascar, nascar crashes, beamng nascar crashes, pawshore, snowburger
Id: 2msdNzZKJXA
Channel Id: undefined
Length: 18min 3sec (1083 seconds)
Published: Wed Sep 06 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.