Entities have the ability to change their location. Players can input movement commands in a variety of ways. Often, it is directly mapped onto an input device where there is a one-to-one mapping between the player input and how the player-controlled entity moves. Another common way to input movement is through a point-and-click interface. In such an interface, the player specifies where the entity should traverse towards. The entity uses path-finding techniques to discern the best path to traverse. Entities controlled by an artificial intelligence usually use a similar path-finding technique to move to their location goal.
There are many reasons to change location. Often, the entity may need to change their location in order to reach a location goal. In this case, the new location is the motivation behind the decision to change location. Other times, the previous location may be detrimental to the player, and the goal of leaving a bad location is the motivation behind the decision to move. There are many other reasons to change location, each with a specific goal in mind.
Some entities move without a goal. In these cases, the entities are not making any decisions (and are not agents). Instead, they move because the rules of the world dictate that they move. Most of the time, their movement is highly predictable and patterned, or completely random and erratic. Sometimes, movement may appear random at first, but after careful study (or a look into the code), patterns or intention in the movement will appear.
Agent movement can also be dictated by the game or game world. In many shooters, the player moves along a "rail" through a level. Many times, they have some freedom of movement along the rail. In the game 1942, the player-controlled entity has freedom of movement within the current screen space, but the screen space is constantly moving over a terrain. In Panzer Dragoon Orta, the player's progression through a level is forced along a rail, but the entity can move along two other axes to avoid enemy fire. In other cases, the agent may have complete control over movement until they use a specific ability. For example, an agent may choose to jump, and once airborn, they have no control over the trajectory of the jump. Games can either give an agent complete control over movement, partial control, or no control.
In Pac-man, the player controls the movement of Pac-man by point the joystick in the direction he wants him to go. Pac-man will continue to move in that direction until he collides with another entity, or until the player changes the direction.
In Space Invaders, the aliens move along a predetermined path. They continue to move on this path until they are removed.
In Diablo, players use a mouse cursor to point-and-click on a location to which they wish their player-controlled entity to move. The game uses path-finding techniques to automatically move the player-controlled entity to that location.