LiminaliaLiminalia
How-to: Show images over the screen

Show images over the screen

Open in Claude (new tab)
On this page

With the “Image” part, you can show images such as photos, maps or letters over the background and sprites. An image stays until you place the “Remove image” part. A full-screen illustration (an event CG) is shown with the “Background” part.

The examples on this page use the project you make in the tutorial, “Shiori of the Library.”

Show an image over the screen

Here, a photo (photo.png) put in “Images” on the “Assets” screen is shown over the library background.

  1. Select the text block just before where the image should appear (here, “A photo slipped out from between the pages of a book.”).
  2. Type “image” in the search box at the top of the parts panel, and double-click “Image” in the results.
  3. In the parameter panel on the right, set folder to “image.” When you choose the asset folder that holds the image, the choices for file become the images in that folder.
  4. Click the file field, and choose photo.png from the list.
  5. So that you can remove it later, enter a name in name (here, photo).
The Image part, with photo.png chosen in file.
  1. Set where it goes by the position of the image’s top left corner. Enter 404 in x and 120 in y (px). Enter 500 in time, and it appears over 0.5 seconds.
Set folder to image, and set the position with x and y.

With the next text, the photo appears over the library.

The photo shown over the background.
ParameterWhat it sets
folderThe asset folder that holds the image (fgimage is sprites, image is images, bgimage is backgrounds; fgimage by default)
x, yPosition of the image’s top left corner (px)
width, heightWidth and height (px; the image’s own size if left out)
layerLayer to place it on (fg0, fg1, fg2; fg1 by default)
zindexStacking order within the same layer
flipFlip horizontally

Remove the image

  1. Select the text block just before where the image should be removed (here, “It was an old photo of the hill in the morning.”).
  2. With “image” still in the search box, double-click “Remove image.”
  3. Set layer to the layer the image is on (here, the default “fg1”).
  4. Enter the name you gave it, photo, in name. Enter 500 in time, and it disappears over 0.5 seconds.
The Remove image part. Set layer to fg1 and name to photo.
The photo has disappeared.

If you leave name empty, every image on that layer is removed.

Show a full-screen event CG

A full-screen illustration is handled the same way as a background.

  1. Put the illustration in “Backgrounds” on the “Assets” screen beforehand. Here, stills/morning_akari.png, in a stills folder, is used.
  2. Select the block just before where the illustration should appear (here, “I put the photo back in the book and closed my eyes.”), and double-click “Background” in the parts panel.
  3. Choose the illustration in image, and enter 1000 in time.
Choose the illustration in image of the Background part.
The illustration is shown.

If sprites are on screen, hide them before the illustration (to fade out, hide the sprites and switch to the illustration, a single Scene change part does it all). You can change how it transitions the same way as in Change how backgrounds transition.

To make the illustration viewable as a CG in the extras, register the image in the CG list. To make it viewable in the extras without showing it on screen, use the “Unlock CG” part (@cg-unlock). For details, see Extras.

In code

A photo slipped out from between the pages of a book.
@image photo.png folder=image name=photo x=404 y=120 time=500ms
It was an old photo of the hill in the morning.
@free-image fg1 name=photo time=500ms
I put the photo back in the book and closed my eyes.
@bg stills/morning_akari.png time=1s
That morning, on top of the hill, Akari had been smiling.

For details, see @image, @free-image and @cg-unlock.

Commands used on this page

@cg-unlock@image@free-image@bg