SpexxDev
|
  |
| Joined: 14 Jan 2011 |
| Total Posts: 231 |
|
|
| 20 Jun 2016 08:42 PM |
| Does anyone have any idea how one would make a self driving NPC car? I have car models dont need that I just need a car that will move and turn on streets and all of that. If someone wanted to script that for me I would be willing to pay 1k covering tax. |
|
|
| Report Abuse |
|
SpexxDev
|
  |
| Joined: 14 Jan 2011 |
| Total Posts: 231 |
|
|
| 20 Jun 2016 08:43 PM |
| Or give me ideas on how to script that^ |
|
|
| Report Abuse |
|
|
| 20 Jun 2016 08:46 PM |
| I would script it for you for 1k but there are a few restrictions to how smart I can make the AI for just 1k robux message me |
|
|
| Report Abuse |
|
Zeranoc
|
  |
| Joined: 23 Aug 2014 |
| Total Posts: 492 |
|
|
| 20 Jun 2016 08:53 PM |
There are a few ways I could see this being done.
The first is to make pre-set trails that the car would follow. A random path would be chosen and that car would take it. This would all add up to a system of paths that the car could choose to go. For example, if you reached an intersection, then you would have some paths and the car would choose a random one which would make them turn, go straight, or whatever it may be. You would use parts as detectors to tell the car when to stop and go and things like that.
Another way I would see it working is a little more difficult. Roads have lines, so you could use those to create a path instead of just making pre-setup ones. For example, say you were going down a straight road coming up on an intersection. The lines on the road tell the car how the road is shaped and it would basically just follow that curve. Then, you would make it look like the wheels are turning and spinning and such depending on the rotation of the car. When the line stops at the intersection, then the car would stop, knowing there isn't a line anymore. Then you would have to make some sort of script telling whether it is green or not and tell the car to choose a random way.
Hope I helped a little or got your brain going on the right track. Perhaps you could look up some sort of pathfinding or AI tutorial on another engine and try to replicate it on roblox. Good luck! |
|
|
| Report Abuse |
|