Wallpaper Engine

Wallpaper Engine

View Stats:
butcho Jan 20, 2021 @ 5:33am
Scripted image sequence
Don't have the slightest idea if this is possible but I want to play a sequence from let's say frame 1-50 then loop frame 51-100 two or three times and after that continue the sequence from frame 101 until the end.

Is this doable somehow?
< >
Showing 1-2 of 2 comments
Biohazard  [developer] Jan 20, 2021 @ 5:45am 
Yeah that's possible now. You would use an update function to check which frame is currently playing (getFrame) and then use setFrame() and play() to just make it repeat some frames. https://wallpaper-engine.fandom.com/wiki/SceneScript_Class_ITextureAnimation

You can access this object with thisLayer.getTextureAnimation()

Texture animations are guaranteed to display each frame at least once, so using getFrame in the update function is reliable. Timeline animations are different, since they are smooth and you are practically never exactly "on" any frame but rather between two frames (if that makes sense).

Maybe this is enough to get you started, but we can also help you finalize the script if you're stuck or something is unclear.
butcho Jan 20, 2021 @ 6:16am 
Originally posted by Biohazard:
since they are smooth and you are practically never exactly "on" any frame but rather between two frames (if that makes sense).
Hehe....guess I know what you mean. Binding the first animation to a property I was lilke: "Where d.a.f.u.q is the start and end frame?" but now I'll find it pretty usefull to kinda set a start and end frame for every animation independently. Really high flexibility.

Thanks for the offer to help me out. I'm going to check out if I can fiddle something together and if things go south I now where to find you guys to call for help. :lunar2019laughingpig:
Last edited by butcho; Jan 20, 2021 @ 6:18am
< >
Showing 1-2 of 2 comments
Per page: 1530 50

Date Posted: Jan 20, 2021 @ 5:33am
Posts: 2