[Release] Image Loader

Screenshot : https://img15.hostingpics.net/pics/982904imgloader.png
Animated image example : https://www.youtube.com/watch?v=OxxPY2QfJR8

fxserver-imgloader

FXServer Image Loader

Experimental image loader for FiveM using multiple copies of a specially crafted scaleform (imgloader.gfx).

Usage:

start imgloader

Then import wrapper in your script :

resource_manifest_version '44febabe-d386-4d18-afbe-5e627f4af937'

client_scripts {
	'@imgloader/client/wrapper.lua',
	'etc...',
}

You can test the example, it is a sample zone manager using imgloader.

API

local image = CreateImage({
  txd    = 'texture_dictionnary',
  name   = 'iamge_name',
  x      = 0.0,
  y      = 0.0,
  z      = 0.0,
  rotX   = 0.0,
  rotY   = 0.0,
  rotZ   = 0.0,
  scaleX = 1.0,
  scaleY = 0.5,
  scaleZ = 0.0,
  alpha  = 100.0,
})

image.set({
  txd    = 'texture_dictionnary',
  name   = 'iamge_name',
  x      = 0.0,
  y      = 0.0,
  z      = 0.0,
  rotX   = 0.0,
  rotY   = 0.0,
  rotZ   = 0.0,
  scaleX = 1.0,
  scaleY = 0.5,
  scaleZ = 0.0,
  alpha  = 100.0,
})

image.set('alpha', 100.0)

image.show()

image.hide()

image.play(txd, prefix, length, delay)

image.pause()

image.unload()

You can’t display more than 20 images at the same time so hide / unload your images as soon as possible.

12 Likes

Took a look on the screenshot looks really cool!

Wow! :smiley: Very nice!

(20Char)

1 Like

http://prntscr.com/hjz5z1 Now this is why I don’t use edge for the Forum But great work!

Looks better than the original :joy:

1 Like

LOL stop hating on yourself

pretty cool! :smiley: i need to write 20 characters tho

I’ve been following this project from the start (When you first mentioned that you’re gonna make it on discord) and I’m really glad that it’s finally here, GREAT!

V2 => Better scaling and centering, example modified to rotate depending on cam rotation.

ooooh great job!!! –

Updated imgloader to let users change the source of an image at any time + added animated image example. https://www.youtube.com/watch?v=OxxPY2QfJR8

Rewritten from scratch = new API

strange all i did is change the location of the image and it just doesnt work…
you’ve got discord ?

Yes I have discord but maybe we can solve it here to help other people. Can you post your code ?

Config              = {}
Config.DrawDistance = 50.0

Config.Zones = {
  zone1 = {x = 1615.0, y = 578.0, z = 40.0, size = 20.0, txd = 'custom_imgs', name = 'esx',   width = 5.0, height = 3.0},
}

this is all i changed

p.s image size has nothing to do with it, it was 3 in the original code

Let me run my server and test it

its in sandy shores at the motel

it works but it is under the map

Screenshot: https://img15.hostingpics.net/pics/788477Sanstitre.png

so… how do i get it up :stuck_out_tongue: z = 100 ?