Document Category Item: Tutorial > Setting up a background!Back
Setting up a background!
Description

vne_set_bg() can be use to set a background.
You can also not use this variable for the current branch and page if there is no need for a background.

We will break down the following: "vne_set_bg(1, 1, 0, "image/bg/school_outside.png", 1920, 1080, 0, 0)".

The variable "vne_set_bg()" must be use for every page with a background.

The first 2 variable is for the current branch and page.
This tell the engine to load a background at this branch and page.

The next 2 variables are for loading a image, either an pre-loaded image id during loading screen or load on the fly a image file.

The last 4 variable is to set the size and position of the background.

The default size on screen is always 1920 x 1080p and fixed to screen at position 0,0.

 

vne_bg_has_transition() has to be use if the previous branch and previous page background is not the same!

 

NOTE: During gameplay, it does not keep reloading the background if the next branch and page is the same! However, the same "vne_set_bg()" must be use on all page with this image as well as the slight change to the branch and page!

Definition

vne_set_bg(branchID, page, image_id, filename$, sizeX#, sizeY#, pX#, pY#)

vne_bg_has_transition(branchID, page, has)

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)/