AGK for Pascal
ContentsIndexHome
PreviousUpNext
TAgkSprite.SetPositionByOffset Method (Single, Single)

Immediately positions the sprite to the given X,Y world coordinates.

Syntax
Pascal
procedure SetPositionByOffset(const X: Single; const Y: Single); overload;
Parameters 
Description 
const X: Single 
the X coordinate 
const Y: Single 
the Y coordinate 

The default world coordinate system has 0,0 as the top left corner, and 100,100 as the bottom right hand corner of the screen (this can be changed using TAgkApplication.SetVirtualResolution). 

This method always positions the sprite using its current offset (see SetOffset). For example if the current offset is the center of the sprite this command will place the center of the sprite at the given coordinates.

Copyright (c) 2012. All rights reserved.