Change image sprite at runtime

I think what you should probably do it set them to webp


I tried using the canvas ui scale mode “scale with screen size” but it made the content disappear. Not sure if it’s a bug or I’m using it wrong

by user 401167615826984963

Its not implemented yet

ah ok

by user 401167615826984963

What you could do as well is set images on a <img> tag instead too

if you want to go screenspace only :slightly_smiling_face:

There’s a special type for this: TextureReference

it will copy the images to the output directory instead of including them in the glb

that way your scene should load pretty quickly (because its basically empty) and you can create/update an img src path only

Ah sorry its ImageReference

I don’t see the needle tab on my texture settings

by user 401167615826984963

in your typescript code it will end up as a string (the path to th exported file)

You declare it like this:

//@type Needle.Engine.ImageReference
public images : string[];

Nice, I was wondering about that

by user 401167615826984963

Is it this one? Which editor version do you use?

That one is for “dedicated server”

by user 401167615826984963

ah ok :slightly_smiling_face:

2021.3.16f1 personal

by user 401167615826984963

Can you try opening the Build Settings Window and send a screenshot?

it should contain this