Search Unity

iTS - Intelligent Traffic System [WIP]

Discussion in 'Works In Progress - Archive' started by rhodnius, Jul 28, 2014.

  1. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @Meceka I just did some tweaking on the super simple physics and the AI values and i think is better now for the oscillating issue, about the little jumps the rigidbodies do, hmm that one is weird, since we just push the rigidbody forward for movement, will look deeper into it.

    Rhod,
     
  2. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Just uploaded the update of the low poly super simple physics demo

    Rhod,
     
  3. HeadClot88

    HeadClot88

    Joined:
    Jul 3, 2012
    Posts:
    736
    I really like where this is going :)

    Would you consider adding a Pedestrian Add-on for this asset?

    As a city is nothing with out people walking and interacting on the sidewalks.

    That said keep up the awesome work. :)

    EDIT: Will this be upgraded to Unity 5 when it is made available?
     
  4. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @HeadClot88 yep it does already!, just that I dont have good peds models to put in the demo :D

    And yep for sure I'm going to make it compatible with unity3d 5, the thing that needs to be converted is actually the car physics, not much the actual traffic system.

    cheers! And thanks for the comments!

    Rhod,
     
  5. HeadClot88

    HeadClot88

    Joined:
    Jul 3, 2012
    Posts:
    736
    Maybe I can do something to help you out in terms of Pedestrian models?

    If not there is always boxes and Capsules. :p

    Cannot wait to get this asset for my next game. :)

    - Ben
     
  6. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @HeadClot88 that would be just great if you could! Or maybe just point out where some free ones could be found, I think I have seen some free ones on the asset store now that I think about it.

    Thanks again Ben!

    Jose,
     
  7. HeadClot88

    HeadClot88

    Joined:
    Jul 3, 2012
    Posts:
    736
    Check out blendswap :)

    http://www.blendswap.com/

    All models are free just double check the license :)
     
  8. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Thanks, will check just now!
     
    HeadClot88 likes this.
  9. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    I just tested and it's good to see oscilliation is fixed. But 2nd bug remains (spinning around on a crossroad)

    I wish to add an option in my options menu that will modify traffic physics quality. It will switch between simple and wheel collider physics, will it be easy to switch between them? They can use same waypoints and etc. , right?
     
  10. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @Meceka well that should be possible though, the spinning on the crossroads that you have seen is by themselves or when something else happens?

    Rhod,
     
  11. pated

    pated

    Joined:
    Jun 27, 2012
    Posts:
    31
    An automatic switch between simple physics and wheel collider physics with a distance threshold would be fantastic.

    Anyway, can't wait to test that android test app. ;)
     
    rhodnius likes this.
  12. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    +1 to the idea of switching between those physics.

    I've sent a video of that bug on my earlier comments, pm me if you don't understand which one it is.

    It happens if you disturb them somehow close to the traffic lights. Happened about 5 unique times when I was testing. And when it happens they just spin around for a long time about 1 minute. Just as in that video.
     
    rhodnius likes this.
  13. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Thanks! Would check that out.

    Rhod,
     
  14. Gooseman_1977

    Gooseman_1977

    Joined:
    Aug 15, 2013
    Posts:
    89
    oh sweet. Is it possible to combine this with your other package, Intelligent Race driver system? I'd love to have smart NPC cars that drive through the city avoiding traffic, like in Need For Speed.
     
    HeadClot88 likes this.
  15. HeadClot88

    HeadClot88

    Joined:
    Jul 3, 2012
    Posts:
    736
    +1 for this feature!
     
  16. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Thats the idea, we would do some adjustments on iRDS to make the avoidance better and more performace wise. So in short it would be like that ;)

    Rhod,
     
  17. Gooseman_1977

    Gooseman_1977

    Joined:
    Aug 15, 2013
    Posts:
    89
    sweet! good luck with that.. Hope to see it on the store soon.
     
  18. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Thanks!
     
  19. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    How does your asset compare to the Road & Traffic System asset currently on the asset store? Does it have any advantages over that asset? Thank you
     
  20. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @eridani for what I have seen on their demo, that one seems to use transform position amd rotation to move the cars, which doesnt look that realistic, iTS uses real physics, so the cars are actually driven NPC, also purs can be used on any surfaces and any roads, that one seems to use some roads pre made sections.

    iTS can be setup to have different type of vehicles on each lane, so you can setup real complex road systems.

    On iTS you can also add traffic volumes to manage the amount of cars per each volume, making some volumes have more traffic than others.

    You can also set a spawning radius to make the traffic cars get spawned on this radius, if they get outside of this radius they would be disabled and respawned on a new spot inside that radius. This makes the system be a lot more efficient about having actually less total cars on the scene but for the player it would feel like there are a lot more cars.

    These are some of the features, I would be posting them all today.

    Rhod,
     
  21. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    Thanks for your reply. So if all your cars are NPC-driven physics vehicles, that would also impact performance on mobile right?

    And by "any surface and roads," do you mean it can use roads generated by other assets such as EasyRoads, or go up and down and around mountains, etc. Thanks!
     
  22. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @eridani about the performance, it depends on the actual physics been used more than the NPC code, we have also the super simple physics to improve performane for mobile.

    About the any surface, yep you can do exactly that use it with road architec, easy roads or any other tool or 3d app that makes roads or any other surface that have collider on it.

    Let me know if you have any other question.

    Rhod,
     
  23. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @Gooseman_1977 I just saw that you are the guilty guy that made Counter-Strike! wowwww i spent a lot of time playing that game with a lot of friends! awesome to meet you :D

    Rhod,
     
  24. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi guys!

    Here is a demo with peds, i couldnt find really low low poly models, so this models are about 1500 tris aprox, the demos runs slower than only with the cars, so i think it has to do with using skinned meshes maybe? since the code is exactly the same as for the cars.

    Wed Demo low poly cars with peds
    Note: The demo is uploading, it would be available in a few mins.

    Any suggestions or thoughts are welcome about the performance drop when using peds.

    Rhod,
     
  25. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    Very cool demo with pedestrians! Some small things I noticed:

    1. While walking, pedestrians seem to stop too often for no reason, just standing there for awhile. Looks weird when a bunch of them do it at once.

    2. There seems to be something in the road at certain places that cause the cars to jump into the air slightly.

    3. The vehicles' tires aren't turning.

    4. Can you put actual colliders on the buildings and have pedestrians navigate around them? And maybe have pedestrians navigate around the player's car if parked on the sidewalk.

    This system is looking really nice overall.
     
    rhodnius likes this.
  26. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    I've just tested, and pedestrians just spawn on a location once really dense and they don't spawn again anywhere else.

    Buses are still turning on crossorads weirdly sometimes

    They are jumping as noted above and as I noted earlier. If there is a problem with demo scene's terrain or roads it's not an issue. But if they are jumping on a perfectly smooth road please fix it before releasing.
     
    rhodnius likes this.
  27. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334

    @Meceka About the turning, that's because of the way the super simple physics is, not really about the AI of the traffic system, to fix that is really more a tweaking of were the CoG is placed and maybe changing more the way that physics work, we could tweak that more after releasing the package. ;)

    About the pedestrians spawning on a dense location once, that was intentional hehe sorry, i just placed some pedestrians lanes on that corner just for testing purpose, not the entire scene have lanes for pedestrians. Will do that later on.

    About the jumping, i just noticed that is the mesh collider of the roads, since i build that city from a pack that have pieces of road that you need to put together, and at the end i merged it all into one single mesh, so i think i may have let some of them not perfectly aligned, also i did tested replacing it with a box collider (which is smooth surface) and the jumping is gone, i can upload a demo with that collider.

    Thanks for all the feedback! I really appreciate it!

    Rhod,
     
    Meceka likes this.
  28. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @eridani Thanks for the feedback.

    1. Yes i have noticed it too, we may need to do some tweaks for the pedestrians only i think.
    2. See the answer to Meceka, this is way it happens.
    3. The vehicles on that demos are made of a single mesh, since the idea is to make them as simple as possible, thats why they dont turn, you can check out the other demo on the first post, those are totally physics dependent, using wheelcolliders ;)

    4. This can be done, since the pedestrians would be traveling on the defined lanes for them, if you put lanes inside the buildings, they would follow it too, they wont be like a normal AI for humans though, they just would be going around on the defined lanes. We could add something to make them better on the future releases.

    Thanks for the feedback!

    Rhod,
     
  29. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Uploading the demo now, with smooth colliders, and no jumping any more for the super simple physics.

    Cheers!

    Rhod,
     
  30. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    One thing guys, is more like a question, do you know if legacy character animation is cheaper on performance than using mecanim? currently the demo is using mecanim characters animation, and it feels like a little heavier than just having cars, so i presume using either skinned mesh or mecanim is hitting the performance down, any advice it welcome!

    Rhod,
     
  31. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    One thing that i have to quote is that even with super simple car physics, you can get the visual wheels to rotate and turn :D (if the model have the corresponding individual meshes).

    Rhod,
     
  32. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi all,

    The demos for the super simple physics (both with and without peds) have been updated, now with no more jumping.

    Rhod,
     
  33. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    I was thinking exactly about the same thing today;

    They should rotate left/right when car is turning left and right, and they should spin based on cars velocity. I am thinking of making it so that it will only display those wheels when cars are really close, and also their scripts will hibernate when far. Are you wishing to work on this?

    I am not sure if I asked earlier, but is it easy to make trucks hinged with trailers on simple physics?

    Edit: For peds, try removing skinned mesh renderers without deleting mesh filter, and add mesh renderer to them. As I remember it was working that way.
     
    rhodnius likes this.
  34. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi Meceka!

    Yep thats already included, just that the actual super low poly cars doesnt have the wheel mesh separated hehehe. About the hibernation, well i have included 2 callbacks, one is OnCloserRange and the other OnFarRange, you can then use OnCloserRange to switch on those details and OnFarRange to disable them (same for switching physics).

    Yep you can make trucks with trailers for the super simple physics too.

    I will try that, thanks for the tip!

    Rhod,
     
  35. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @Meceka I just tried this way, but the peds now are not animated :confused:, is there something i'm missing maybe, or the idea was to make them not animated to improve performance?

    Thanks in advance :)

    Rhod,
     
  36. eagleeyez

    eagleeyez

    Joined:
    Mar 21, 2013
    Posts:
    406
    OH God! I really need this. any ETA? roughly, Beta, Intoduction price? And what wil it cost?
    Please give me a rough ETA as if it wil be to long I might just have to go with a more basic system which I don't want to.
    This looks just really FN great.
     
  37. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    @eagleeyez Thanks for your comment!

    We plan to release it at the end of this month or starting next month. The cost is still on review, we would let you guys know it before releasing it.

    Rhod,
     
    Last edited: Nov 20, 2014
  38. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    I didn't mean to disable their animations, I just remember doing something like that long time ago :) I don't have experience with animations, sorry. :)
     
  39. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Oh thanks for trying to help!
    Is ok, I have not much animation experience either :D

    Thanks my friend.

    Rhod,
     
  40. ZiadJ

    ZiadJ

    Joined:
    Sep 3, 2011
    Posts:
    62
    Last edited: Nov 20, 2014
    rhodnius likes this.
  41. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
  42. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi Guys!

    We are pretty much ready for the release, we are going to rig the new cars (some free cars for the demo scene of the package) and rig the roads of the dll version of iTS, the full source code version is closer to be ready, since there is no need to rig again the roads (we are going to use the same city scene as the one you have seen on the web demo).

    The prices we have thought for now are as follow:

    • iTS dll version (only the core is on dll, the simple car physics would be full source code, wont have any restriction on functionality): USD150.00
    • iTS full source code (all the source code included): USD450.00

    Let us know what you think about it! We really appreciate your feedback!

    Rhod,
     
    emergki likes this.
  43. Meceka

    Meceka

    Joined:
    Dec 23, 2013
    Posts:
    423
    "the simple car physics would be full source code, wont have any restriction on functionality"
    I didn't understand this sentence. Will simple car physics source code be available in dll version?

    Will there be an upgrade option from dll version to full source code?
    Price is higher then what I expected.
     
  44. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi Meceka,

    Yep the source code of the simple car physics would be available on dll version.

    About the upgrade, that's something we could, just that won't be something doable from the asset store. But yep we could do it. One thing to take into account is that the project itself wont be up-gradable directly (since dll version would have variables obfuscated), but we could think of something for it.

    Rhod,
     
    Last edited: Dec 3, 2014
  45. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hmm just thinking about it, i'm going to add just a road graph save and load option, this way you can save the road data of dll version and load it up on full source code version.

    Also, would be great to know what price you think full source code should be?

    Rhod,
     
    Last edited: Dec 3, 2014
  46. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    Does this asset generate buildings and roads procedurally? If so, can it do it at runtime and what is the performance on mobile? In any event the planned price is far too high for my budget for such an asset (especially with competing assets which cost less), but others might not mind the high price, I don't know. Anyway, thank you
     
  47. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi eridani,

    Thanks for the comment.

    iTS is about AI traffic simulation, not really procedural mesh creation, it does what trafX does and a little more. TrafX is priced at 3000.00+ ;)

    We have split into 2 versions trying to make a more affordable traffic simulation solution option :D

    Maybe there could be some confusion about what the system does, i would be listing all the features soon.

    Rhod,
     
  48. eridani

    eridani

    Joined:
    Aug 30, 2012
    Posts:
    655
    Thanks, I think it would be helpful to see all the features of iTS. Right now to me it seems like your asset does less than these two assets (which are far cheaper), except for a pedestrian system (which they are currently working on).

    https://www.assetstore.unity3d.com/en/#!/content/21626
    https://www.assetstore.unity3d.com/en/#!/content/24993

    I don't know what TrafX is but I was talking about other comparable assets in the asset store. It always surprises me when it seems some asset makers don't look at the asset store to see what their direct competition is?

    Anyway your asset looks good and I'm sure you will have buyers. But since you are the one who asked for feedback, for me personally it doesn't seem to offer as much as other "high end" assets such as UFPS or even iRDS, but is priced even higher. Thanks again!
     
    Last edited: Dec 2, 2014
  49. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi eridani,

    Thanks for the feedback, really appreciate it! :)

    The approach is really different on how iTS works, iTS uses complete physics cars, that are driven more naturally for a more realistic traffic simulation, here is a list of the features of iTS:

    • Physically driven cars for a more realistic simulation
    • The roads graph can be of any shape independently of the road mesh
    • Vehicles and pedestrians are managed by the system
    • Can be used to build really complex roads systems (not meshes but the lanes the traffic would follow)
    • Complete editor tools to easily add lanes, edit their shape, connect lanes to each other, etc.
    • Build intersections with the use of any number of traffic lights and sync them in different ways.
    • Build intersections of any number of intersecting lanes.
    • Can control how many cars you want per area using "Volumes" like on the Unity occlusion system so you can tweak the amount of cars you want per area on a city, to simulate different traffic density on different parts of the scene.
    • Can set the spawning area from the Traffic spawner, to control how near or far you want the cars to be spawned from the player or camera.
    • Can easily modify the already placed lanes shape, without having to redo your work.
    • Can have intersections without traffic lights and the system would handle the intersection crossing without having "accidents" from the traffic cars.
    • Can rig the cars with our rig wizard, which is a really time saver.
    • Can set different types of vehicles per lane, so you can have exactly the kind of vehicles on the exact parts of the scene.
    • Can set different types of vehicles on the lane connectors, this is helpful for designing different turns for different vehicles (like wider turns for Trucks with trailers, and normal turns for the other type of vehicles).
    • Vehicle types presets available to make it easier to set the vehicles types per lane when building the road graph.
    • Traffic cars detects the player and either stops or overtake (if possible).
    These are features, i might be missing any other, so i would update the list if i missed any.

    PS: Here is a link of TrafX, is made by the guys who made CarX too. And sure we had seen those assets, but as i explained early, the approach is different :)

    Link

    Thanks again,

    Rhod,
     
    Last edited: Dec 2, 2014
  50. rhodnius

    rhodnius

    Joined:
    Apr 11, 2012
    Posts:
    1,334
    Hi Guys,

    I have just implemented the save and load option for the road data for the inspector, so you could save and load all the road data into an XML file.

    Rhod,