Skip to content

move_to_location

Syntax

move_to_location(<place_name>, <latitude>, <longitude>)
move_to_location(<latitude>, <longitude>)

Parameters

<place_name>
Optional. Name of place for which the agent's site is to be moved. If omitted, the acting agent itself will be moved.
<latitude>
Latitude of target location.
<longitude>
Longitude of target location.

Description

This action moves an agent's site for a place to a location, specified as a latitude and longitude. If there are only two arguments, then the acting agent is moved to the specified latitude and longitude.

Examples

The following moves an agent's site for a place named Car to 40.44° N, 79.96° W

move_to_location(Car, 40.44, -79.96)

The following moves the acting agent to 40.44° N, 79.96° W

move_to_location(40.44, -79.96)

See Also