DxDrawRectangle

From Multi Theft Auto: Wiki
Revision as of 19:04, 2 March 2008 by Talidan (talk | contribs)
Jump to navigation Jump to search

This function draws a 2D rectangle across the screen - rendered for one frame. This should be used in conjunction with onClientRender in order to display continuously.


Syntax

bool dxDrawRectangle ( int startX, startY, float width, float height [, int color] )

Required Arguments

  • startX: An integer representing the absolute origin X position of the rectangle, represented by pixels on the screen.
  • startY: An integer representing the absolute origin Y position of the rectangle, represented by pixels on the screen.
  • width: An float representing the width of the rectangle, drawn in a right direction from the origin.
  • height: An float representing the height of the rectangle, drawn in a downwards direction from the origin.

Returns

Returns a true if the operation was successful, false otherwise.

Example

--TODO

See Also