GXEntityMove - boxgaming/gx GitHub Wiki
Move the specified entity relative to its current position.
Syntax
GXEntityMove entityId%, dx%, dy%
Parameters
- Entity to move is specified by the entityId% parameter. This id is returned by the GXEntityCreate function or can be accessed by its user id by the GX function.
- The number of pixels to move the entity horizontally from is current position is specified by the dx% parameter. A positive value will move the entity to the right. A negative value will move the entity to the left.
- The number of pixels to move the entity vertically from is current position is specified by the dy% parameter. A positive value will move the entity down. A negative value will move the entity up.
Examples
Example1: Move the entity to the right 3 pixels and up 5 pixels from its current position.
GXEntityMove warhog, 3, -5