Fuze Arena Logo
  • Forum
  • Creations
    Catalogue Showcase
  • Help

loadImage()

Purpose

Load an image from a file

Description

Loads an image from the file specified into memory ready for display

Syntax

handle = loadImage( filename )

handle = loadImage( filename, filter )

Arguments

handle variable which stores the desired image file

filename relative path of the image to load

filter set filtering on or off - generally on for real images and off for pixel art

Example

roll = 0
clear()
image = loadImage( "Colin Brown/Dice", false )
size = tileSize( image, 0 )

for i = 1 to 10 loop
    clear()
    roll = random( 6 ) + 1
    x = size.x - ( size.x * ( roll % 2 ) )
    y = size.y * ( ceil( roll / 2 ) - 1 )
    drawimage( image, { x, y, size.x, size.y }, { 0, 0, size.x, size.y } )
    update()
    sleep( 0.3 )
repeat
printAt( 0, 15, "You rolled a ", roll )
update()
sleep( 3 )

Associated Commands

clear(), createImage(), drawImage(), drawImageEx(), drawQuad(), drawSheet(), update(), uploadImage()

logo

©2019 FUZE Technologies Ltd. FUZE is a registered trademark of FUZE Technologies Ltd. All rights reserved.

Useful links

  • Fuze Main Site
  • Fuze Arena on Twitter
  • Fuze Arena on Youtube
  • Download Buyer

Contact Information

  • FUZE Technologies Ltd
    15 Clearfields Farm
    Wotton Underwood
    Aylesbury, Buckinghamshire
    ​England, HP18 0RS

  • +44 (0) 1844 239 432

  • contact@fuze.co.uk

© Copyright FUZE Technologies Ltd. All rights reserved.