Mr.Meeseeks Posted December 21, 2018 Share Posted December 21, 2018 Heya! I'm quite new to Simio, At the moment, I am wondering in what way I should model the following: Im trying to model a simple roadway, with entities being able to catch up with one entity ahead and keeps following this entitiy to form a sort of "train". At the moment I am using decides steps such as: ModelEntity.NetworkDistanceTo.NextEntityAheadOnLink< "certain distance" --> if true ModelEntity.Movement.Rate +0.5. But this solution only sort of works when im using one path. I know there is something like ModelEntity.Location.X, which should work wherever the entity should be. So, is there any smart way to 'connect' the entities (with a maximum number of entities able to connect) And how to I make them accelerate so they are able to catch-up? Link to comment Share on other sites More sharing options...
dsturrock Posted December 26, 2018 Share Posted December 26, 2018 Any entity traveling on a path at a faster speed than the entity ahead of it with catch up to that lead entity, and continue following it as long as the path Passing property is False. I have used this as a quick way to model things like a vehicle that tows several carts around the model. You might also look to the Trains or Transportation library that is in the shared items folder. Link to comment Share on other sites More sharing options...
Mr.Meeseeks Posted December 28, 2018 Author Share Posted December 28, 2018 Thanks for your reply! That's something that worked indeed. Although I'd like to model it in a different way. At the moment I am trying to store the location.x of each entity in a vector, and keep this updated by using an add-on process with a loop. From there I would like to let every entity use the find step, to look for the lowest value in the list for location.x - (their own location.x). When this is done, they should switch to a boolean state in which they are trying to "couple". If this is true, these entities will not show up in the previous list with the lowest location.x. When this boolean state is active, I would like to let the entity behind speed up, until the distance between the targeted entity is for instance "1m", after that they should proceed with the same desired speed. I did find some interesting simbits which does something similar like "FindAMinimumStateValue.spfx", although. Instead of updating serverprocessing times, I would like to store the location.x of each created modelentity. Is there any way to do this? Link to comment Share on other sites More sharing options...
Recommended Posts