VectorScreen
From Liberty Unleashed Wiki
The VectorScreen type is a 2-dimensional vector used to indicate positions on screen. The origin is at the top-left corner of the screen.
Constructor
VectorScreen( int x, int y )
Values
- x - The X coordinate of the vector
- y - The Y coordinate of the vector
Example
VectorScreens originate in the top-left corner. This code makes a VectorScreen that starts 10 pixels down and 10 pixels to the right.
local screen = VectorSceen( 10, 10 );
This code makes a VectorScreen about 10 pixels down and 20 pixels from the right.
local screen = VectorScreen( ScreenWidth - 20, 10 );
This code creates a VectorScreen approximately in the middle of the screen.
local screen = VectorScreen( ScreenWidth / 2, ScreenHeight / 2 );
Types
- Colour
- ScreenSize
- Vector
- Vector2D
- VectorScreen