Automatic Location/Minimap System

A place for Ren'Py tutorials and reusable Ren'Py code.
Forum rules
Do not post questions here!

This forum is for example code you want to show other people. Ren'Py questions should be asked in the Ren'Py Questions and Announcements forum.
Post Reply
Message
Author
User avatar
Syrale
Regular
Posts: 100
Joined: Sun Oct 25, 2015 10:28 am
Completed: Robot Daycare, Deep Sea Valentine, Locke(d)
Projects: Artificial Selection, rei_carnation
Github: kigyo
itch: kigyo
Discord: kigyo#2564
Contact:

Automatic Location/Minimap System

#1 Post by Syrale »

Image Image

I made a location system that updates the player's location completely by itself!
It comes with both a minimap and a new page for your game menu - all you need is a map image (and optionally a "you are here" indicator):

My old approach to update the player's location was the following:

Code: Select all

scene hallway with dissolve
$ current_location = "hallway"
That's very straightforward, but a hassle to do after every single scene statement, on top of being prone to errors/forgetfulness.

The cool thing about the new location system is that manually setting "current_location" won't be necessary.
The location will change automatically with every scene statement, which is fool-proof and saves a ton of tedious work!

It simply grabs the location from the currently displayed background image. This requires some extra setup to work, but it will be immensely worth it in the long run.


Let me know if you have any questions or additional feature requests!

Post Reply

Who is online

Users browsing this forum: No registered users