0
votes

I have recently started working with Anylogicfor school. I have to simulate the operations of an oil terminal that loads oil tankers of different sizes at three different docks. https://i.imgur.com/mKqlaRF.png

1- A tug goes out to the see and pushes the tanker to the dock and, once the tanker is loaded, he pulls them back to the sea. The pushing animation looks fine in the standards needed but once it's time to pull him back out, the tug gets to the tanker's node, stays right there as the tanker float away to destination (not following the pathes even tho straight movement is unchecked). https://i.imgur.com/UwnTfb6.png

Here is what i have in "on prepare unit" of the seize block(which works fine on the push phase) :

unit.setSpace( agent ); unit.setRotation( -PI/2 ); unit.jumpTo( agent.pushingPoint.remove( 0 ) );

Any ideas on how to fix this ?

2- In that model, there are occasionnal storms that force the tug to stay at home location. I have added a rectangle with a blue color and transparency to give the storm a visual aspect in the simulation, but that rectangle (even though I gave it a considerable Z-height) doesn't show in 3D. Is there anything I can do to simulate a storm in 3D?

3- Since I have three different boat sizes, I would l ike to visually differentiate them in the simulation. Is there anyway to change the color of an agent or it's size depending on a Variable?

1

1 Answers

1
votes

All your questions lack a lot of details and require a lot of guessing, so I will guess potential answers.

  1. The reason why it doesn't follow the path is because it wasn't positioned in the network in the first place. Please check the help documentation here to understand how movement works: https://help.anylogic.com/index.jsp?topic=%2Fcom.anylogic.help%2Fhtml%2Fmovement%2FMovement_Network.html. The path may also be straight if the agent that is moving belongs to a different hierarchy.
  2. I can see 2 possibilities: either you made it so transparent that you can't even see it, or maybe you clicked on the rectangle properties, in advanced you have the option "show in" selected in "2D only".
  3. In all 3D objects, in the properties you have a parameter "additional scale" that as a default is 100%. If you set that up to 50% the boat will be half the size. You can use a variable for that parameter if you want.