Parallax Viewport for Ren'Py
A downloadable asset pack
Overview
This screen language add-on will let you create a special viewport which will scroll its contents using parallax depending on how large they are. Designed to require very little setup - just add your contents to the parallax viewport and it will figure out the rest. Useful for map screens, unique UI screens, scrolling credits, and more!
Features
- A ParallaxViewport class with a CDSL wrapper so you can easily add it to your screens (it's just parallax_viewport: instead of viewport:)
- Does all the regular things a viewport would, and can be scrolled in all the same ways (e.g. edgescroll, mousewheel, dragging, Scroll actions (see below))
- Handles events as you would expect, so button actions etc. will all still work within the viewport
- A special AnimatedScroll action with additional arguments for smoothly scrolling around your viewport with your warper of choice (you can use the regular Scroll action, too). Note: this feature is 7.6+/8.1+ only.
Instructions
Download parallax_viewport.zip and unzip it to get 01_parallax_viewport.rpy and parallax_vp_examples.rpy. Drop these files into your project's game/ folder. Several examples are provided in parallax_vp_examples.rpy, which you can try out by jumping to the label test_parallax_vp.
Compatibility
The parallax viewport has been tested for compatibility with Ren'Py 7.5-7.6 and 8.0-8.2, and is expected to be compatible with earlier Ren'Py versions but has not been tested. The special AnimatedScroll action is compatible with 7.6-7.7 and 8.1-8.2, but not 7.5/8.0 due to a lack of animated scroll in those versions (it will not cause any errors if included, but it does not animate). Leave a message in the stickied thread if you run into any bugs.
Terms of Use
You may:
- Use this code in commercial and noncommercial projects, provided you package the code into an rpa file for release - the code to do so is included in the files.
- Modify and edit this code to suit your needs.
You may not:
- Resell all or part of this code as-is or sell it with modifications
- Release any projects created using this code without providing attribution
Attribution must be credited as Feniks, with a link to either the page with this code or to https://feniksdev.com.
Credits
Mountain map from an unannounced game by Wind Chimes Games
Pixel art forest modified from Eder Muniz
There are no image assets included in the tool files.
Final Notes
You may be interested in my other utility tools for Ren'Py, like Marquee or Circular Bar!
I also have a variety of tutorials on my website, feniksdev.com.
Status | Released |
Category | Assets |
Rating | Rated 5.0 out of 5 stars (7 total ratings) |
Author | Feniks |
Genre | Visual Novel |
Made with | Ren'Py |
Tags | Graphical User Interface (GUI), Kinetic Novel, Ren'Py, User Interface (UI) |
Download
Click download now to get access to the following files: