Document Category Item: Tutorial > Advance Background Sprite Animation!Back
Advance Background Sprite Animation!
Description

It is possible to animate the background using sprite animation.

There is 2 type of sprite animation.

"Frame by Frame" and "Atlas" animation.

Example:
vne_set_bg_sprite_animation(1, 3, 1, 1, 1, 4, 1, 0, 0, 0) // type 1, loop frame 4 to end

or

vne_set_bg_sprite_animation(1, 3, 2, 1, 1, 4, 1, 1920, 1080, 5) // type 2, loop frame 4 to end

If using type 2, the "Atlas" image has to be set using ""vne_set_bg()"!

 

For type 1, you need to manually set each frame.

Example:
vne_craft_bg_sprite_animation_frame(1, 3, 1, 0, "image/bg_animation/school_outside_1.png")
vne_craft_bg_sprite_animation_frame(1, 3, 2, 0, "image/bg_animation/school_outside_2.png")

 

NOTE: Basic and Advance Animation can be use at the same time!

Definition

vne_set_bg_sprite_animation(branchID, page, animation_type, has_loop, has_continuation, sprite_animation_loop_start, fps, atlas_width, atlas_height, atlas_amount)

function vne_craft_bg_sprite_animation_frame(branchID, page, animation_sequence, image_id, filename$)

Due to a Cookie law, We are required to notify you that our site is using Cookie(s).
Cookie(s) allow us to provide site services in order to serve you!
You may view our Privacy Policy @ https://visualnovelengine.com/Privacy-Policy/
You may view our Term of Service(s) @ https://visualnovelengine.com/Term of Service(s)/