The function randomly selects an angle (0:360) and moves the lobster. This is called when a lobster is outside the area of influence.
1 | randomMove(xLobster, yLobster, dStep)
|
xLobster |
current x coordinate of the lobster |
yLobster |
current y coordinate of the lobster |
dStep |
fixed length of movemnet in each timestep |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.