Vida Marcell Posted July 14, 2022 Share Posted July 14, 2022 I mean, how did they manage to creat those road systems, whit those pavement islands and other stuff, i dont understand the logic. Quote Link to comment Share on other sites More sharing options...
SpiderPig Posted July 14, 2022 Share Posted July 14, 2022 I never played GTA5, but perhaps spline paths and procedural placement was used? Quote Link to comment Share on other sites More sharing options...
wadaltmon Posted July 15, 2022 Share Posted July 15, 2022 Create graph nodes at each intersection/along the roads' curves. This is oftentimes able to be done automatically with many game engines; although RS's is proprietary, I expect they have such a tool. Give each person a start node and a destination node (or start point and end point, and determine the route to/from the nearest node for each), run the A* or another pathfinding algorithm to find the shortest path from one place to another, save that succession of nodes as some kind of structure on each driver (linked list works best conceptually imo). Do all that serverside for the online play so you always have plenty of processing power. In single player, do that solely for the ones that are visible on screen. Add in some graphical smoothing for the driving so it's not choppy, add in some handling for when you attack or threaten them (start a running away procedure when attacked, after a certain amount of time, assess if there's still a threat, continue running away or go back to trying to get to the destination if not). That's probably just about the basics of it. There's certainly a lot of little nuances that RS took to make it more realistic. Stuff like using a weighted graph system for allowing pedestrians to run in the street, but not prefer to, perhaps. And I expect a complex state machine to govern their mood, current objective/destination, etc. Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 3, 2022 Share Posted August 3, 2022 Yes there are professional tools created for simulation that are just excellent For Leadwerks, the best is the spline tools, it allows a car to follow the road, including physics possibilities. I made with this a little race car game, that was one of my testing with the spline tool: Quote Link to comment Share on other sites More sharing options...
Vida Marcell Posted August 3, 2022 Author Share Posted August 3, 2022 I was thinking about to make a middleware about this, and i like the idea of it, because you only need to write algorithms and rules. You dont need complex ai networks. Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 3, 2022 Share Posted August 3, 2022 I would say not too complicated, but it's quite fascinating to look at a good traffic simulation, something between (not) robotic moving with no accident and fluently cars moving, each at its own velocity. There are the rules and then the traffic goes its own way, yes great thing to create. Quote Link to comment Share on other sites More sharing options...
Thirsty Panther Posted August 3, 2022 Share Posted August 3, 2022 Nick Ace released a traffic system sometime ago. Not sure if it works with the current Leadwerks build but it might be worth having a look at. https://steamcommunity.com/sharedfiles/filedetails/?id=364622139 Quote Link to comment Share on other sites More sharing options...
Yue Posted August 4, 2022 Share Posted August 4, 2022 3 hours ago, Thirsty Panther said: Nick Ace released a traffic system sometime ago. Not sure if it works with the current Leadwerks build but it might be worth having a look at. https://steamcommunity.com/sharedfiles/filedetails/?id=364622139 I have never managed to download something like this, I don't see the download link. Quote Link to comment Share on other sites More sharing options...
Thirsty Panther Posted August 4, 2022 Share Posted August 4, 2022 https://www.leadwerks.com/learn?page=Tutorials_Editor_Workshop 1 Quote Link to comment Share on other sites More sharing options...
Vida Marcell Posted August 4, 2022 Author Share Posted August 4, 2022 C:\Program Files (x86)\Steam\steamapps\workshop it will be somewhere here Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 4, 2022 Share Posted August 4, 2022 You access to the workshop published items through the LE editor -> Marketplace -> Workshop. 1 Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 4, 2022 Share Posted August 4, 2022 23 hours ago, Thirsty Panther said: Not sure if it works with the current Leadwerks build but it might be worth having a look at. Probably not working anymore, as Josh changed the physics - if I good remembered - with Update LE 4.4 And Nick Ace set the cars prefabs from Shadmar as requirement, so probably will the cars not be able to drive, except you go back to build LE 4.3 But yes it might be worth having a look at it for how he managed the simuilation. 1 Quote Link to comment Share on other sites More sharing options...
Vida Marcell Posted August 4, 2022 Author Share Posted August 4, 2022 Someone needs to make an Ultra community lore 1 Quote Link to comment Share on other sites More sharing options...
Vida Marcell Posted August 4, 2022 Author Share Posted August 4, 2022 Just now, Vida Marcell said: Someone needs to make an Ultra community lore There are so many things happened here in the past decade Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 4, 2022 Share Posted August 4, 2022 22 minutes ago, Vida Marcell said: There are so many things happened here in the past decade That's right and so much more before I joined. But I have the feeling the leadwerks community was and is one of the nicest, because never trolling anybody and cool people and so, well sadly a lot of active nice and helpful members are gone, waiting for the ultra engine, or whatever why I don't know. 1 Quote Link to comment Share on other sites More sharing options...
Thirsty Panther Posted August 4, 2022 Share Posted August 4, 2022 The Community here is one of the reasons I stuck with Leadwerks. Lots of different people from different backgrounds all helping each other with their projects. None of the trolling that is present in many of the other forums I visit. Quote Link to comment Share on other sites More sharing options...
SpiderPig Posted August 4, 2022 Share Posted August 4, 2022 I've been waiting for ultra for my project, Leadwerks wasn't powerful enough for its scope. I've been here for at least 13 years and the community here is the best I've seen. Quote Link to comment Share on other sites More sharing options...
Yue Posted August 5, 2022 Share Posted August 5, 2022 I think the traffic system for both pedestrians and cars has the same concept. Mark a route using pivots and set it to move to a certain point and when it is there evaluate its subsequent movement to the next. I think this also has to do with the AI of the enemies in Leadwerks. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.