What it does
LoadImageResized loads Resized on a Image object. It takes iImageID (an integer), szFilename (a string), scaleX (a float), scaleY (a float) and cache (an integer), and returns nothing. That is the first of 2 forms. iImageID is the id you are giving an Image object: every later call names it by that number.
Syntax
1
LoadImageResized(iImageID integer, szFilename string, scaleX float, scaleY float, cache integer)2
LoadImageResized(szFilename string, scaleX float, scaleY float, cache integer) → integerParameters
| Name | Type | In forms |
|---|---|---|
| iImageID | integer | 1 |
| szFilename | string | all |
| scaleX | float | all |
| scaleY | float | all |
| cache | integer | all |
What each form returns
| 1 | LoadImageResized(1, "assets/sprite.png", 1.0, 1.0, 1) | nothing |
| 2 | imageResized = LoadImageResized("assets/sprite.png", 1.0, 1.0, 1) | integer |
Example · generated
Form 1, you choose the id yourself
LoadImageResized(1, "assets/sprite.png", 1.0, 1.0, 1)DO Sync()LOOPForm 2, the command hands back the id
imageResized = LoadImageResized("assets/sprite.png", 1.0, 1.0, 1)DO Sync()LOOPLoadImageResized is called with values of the types its signature asks for. The DO … LOOP is not decoration: a classic BASIC program ends the moment it runs out of lines, and Sync() is what draws the frame.