Skip to content

Developer Info about this mod

firelightning13 edited this page Dec 17, 2018 · 6 revisions

This page explains you about the details and how-to's of my mod and hopefully, it will ease your confusion on how to take over my mod.

THIS PAGE IS UNFINISHED. WILL BE UPDATED SOON

Guides for Mod Developers

To get started, you should have learned a basic language called "Python" and "Renpy". The game uses Renpy as the main language, and it uses based on Python language. After you learned them things or two, you should good to go. If you still don't understand, there are some back-end mod developers that can help you getting started in DDMC Discord server.

Most people think that they should only learn Renpy rather than Python. It depends on what kind of mod what you want to develop. Most modders prefer that as they usually focused on stories and art styles. In this particular, this mod is mostly focused on functionality and modifying core mechanics.

Tables of Content

Before attempting to take over my mod

This mod is hugely complicated and time-consuming than any other mods. If I only focus on developing this mod in 2-3 hours a day, then the final release would be half a year after the initial phase of the development. I made a huge mess in my code, and cleaning them would take forever I think. Making this mod from scratch is a good idea. But if you don't want that, you are welcome to modify my mod from here.

General description of this mod

  • Story synopsis: MC is a self-aware, sentient being. He's going through a hard time after remembering that his best friend, Sayori has committed suicide. He attempts to avenge her through his power and fights whoever made her do so. (re-Act II)
  • Genre: Drama, Glitch, Horror(?)
  • Core mechanics used (so far): This game uses "save-and-load" and "skip" features. This is just like Life is Strange, but can go back and redo every time instantly to make things right.
  • Dozens of possibilities of the story path, since going back in time is possible.
  • Other cosmetic addition: Graphics and sounds glitched throughout the gameplay to make the atmosphere interesting.

Timeline, Ending Scene, and Story Plot

A rough timeline graph can be seen here: https://docs.google.com/drawings/d/1s7001xrDcHZzmLaQE0MsihgTjPdeNbdQ7lsAVNuWFdM

This mod initially has no direction. It is rather just a concept introduction than an actual finished mod. The start of the story is quite slow before introducing to core mechanics (IMO). There are paths that were blocked when reloading to previous save (consequently, it will be either automatically skipping to the next scene or simply crash the game) because I am simply lazy to make another dozen of "useless" routes. This is quite a blind move, where you fill up missing routes then you tend to forget the main direction of this mod and the ending scene that you are trying to achieve once it's done.

Ending scenes

Speaking of ending, this mod doesn't have a single thought out ending scene. I was thinking two or three endings that I want to achieve before, but that day it wasn't my huge priority (this is the biggest mistake I've ever made) and almost to none of my concern. Right now (as I'm writing this post), there are some endings that I could come up with, which is:

  • MC gets his best friend back and lives happily ever after, after game corrupts and start over. A cliche ending that I could think of; or
  • MC saved his best friend after going back in time (Act I). Or after successfully recovered her character file
  • MC takes over the whole game and do whatever he wants A typical character who has an ego trait
  • Monika and MC are now together forever as they both trapped in the game and other characters are already dead.
  • All girls, including Monika can be individually saved by MC. But he will forget his best friend, Sayori

These endings are just a suggestion, though that some ending scenes might contradict the synopsis of the story.

Main Features, and How to Handle Them

This game uses "save-and-load" and "skipping dialogues" concept, where you can relate it to time travel. I'm pretty sure no one ever does these or overlooked these feature. Usually, visual novels don't like this method, as it is usually focused on art styles and/or story-wise (sometimes they can add some kind of minigame inside them).

Save-and-load

"Save-and-load" concept is possible with the variable called persistent, where it stores variables and can be accessed at any time (any saves), while normal variables only store at the current state of the game (only related saves). This persistent variable usually used for settings purposes, such as "enable skipping unseen text" or it can be used for "secret ending".

  • Normal variable: $ i_met_monika = 1
  • Persistent variable: $ persistent.i_met_monika = 1

An example script that I can come up with (based on the variable above):

# Declare the variable first on any .rpy you want
default persistent.i_met_monika = 0

label time_travel: # label inside game script on any .rpy you want
    m 5a "Hi, [player]!"
    if persistent.i_met_monika == 1:
        "I think I met Monika before"
        mc "Did I see you before though?"
        jump other_scene #jumps to any scene you want (alternative route)
    mc "Hi, Monika!"
    $ persistent.i_met_monika = 1
    m "Want to hang out with me?" # this is just an example
    jump main_scene #jump to any scene you want (main route)

Save the game when Monika says "Hi, [player]!" to you, then you continue until it jumps to the main scene. After that, you can reload to the previous save, and the MC will recognize Monika from the start, then it jumps to another alternative scene.

persistent variables are not easy to take care of. It will store whatever value that you've changed, even when you reinstall the game. To prevent this, you need to include some sort of "reset button" everytime players reinstall the game. In splash.rpy, I use mod_firstrun (only resets mod data, and not the main game itself) to combat this problem. From line 262:

if not mod_firstrun: #renpy.loadable("10"):
        if persistent.first_run: #and not persistent.do_not_delete:
            $ quick_menu = False
            scene black
            menu: # The players will be given an option
                "{cps=400}A previous save file/updates for this mod has been found. Would you like to delete your save data and start over? {i}If you have previous update from this mod, you should do so, or else it will break my mod!{/i}{/cps}"
                "Yes, delete my existing data.":
                    "Deleting save data...{nw}"
                    python: # Will delete all persistent data and resets everything
                        delete_all_saves()
                        renpy.loadsave.location.unlink_persistent()
                        renpy.persistent.should_save_persistent = False
                        renpy.utter_restart()
                "No, continue where I left off.":
                    pass

I usually keep track of some variables that I need so I won't forgot what those variables for. Here's how I did it with persistent.monika_secret array.

Skipping dialogues

"Skipping dialogues" concept is very easy to make. When players skipping, instead of going to the main route, they will go to the other route instead.

An example script that I can come up with:

label speed_up:
    $ preference.skip_unseen = 1 # enable skipping unseen text
    n "Where are my cupcakes?"
    y "I-I don't know."
    if config.skipping == 1: # detects if player is skipping
        jump other_scene # main route
    n "Sayori, have you seen my cupcakes?"
    s "A-ah. I guess? hehe"
    jump main_scene

label other_scene: # i made this just in case if you don't know how to reset everything to normal
    $ preference.skip_unseen = 0 # disable skipping unseen text
    $ config.skipping = 0 # stop skipping
    "I skipped everything. Now I don't know if Natsuki has found her cupcakes..."
    return

* Before executing the script above, you have to add $ preferences.skip_unseen = False in splash.rpy, under label after_load to disable "skip unseen text" when players going to other saves/quit the game after preference.skip_unseen is enabled, which is not intended by them. An example can be seen here

Skip the text where Natsuki ask Yuri about her cupcakes (you will see the "Skip" button highlighted at the bottom text box). Then it will continue to the alternative scene and stops the skipping automatically. Note: For some low-end devices, it may lag a little bit, and it may "accidentally" skips some dialogue that you already made (hit-or-miss, per se). For low-end devices compatibility, use this method instead (after you finished skipping the dialogues). (where I use cps(character appears per second) to "act" like the dialogues were skipping)

The Game Atmosphere, and How-to Glitch Stuff

This game's atmosphere relies on disturbing music and sounds when the game is "glitched". A set of glitched music and sounds are already in game/SFX folder, and you are free to use them as you like. Please read notice before using them, at the bottom of this page

I'm using FL Studio 12 (now 20) as an audio tool (and I suck at composing musics), and I used a plugin called Illformed's dBlue Glitch v1.3 to "glitchify" them. Unfortunately, you have to pay to get FL Studio 12 for $99 (Fruity Edition). I got lucky as my cousin is a part-time musician and he has one installed into his computer, and I use it. There are probably other ways to glitch the sounds that I don't know.

Also, this game uses glitching images to make the atmosphere worse even further. Use any tool that can glitch out the images for you. I used a website called Glitchy3bitDither most of the time, and sometimes I used Adobe Photoshop to do some touch-ups effects, and a bit of vector shapes using Adobe Illustrator.

There are other things that glitch stuff can be achieve using codes. You can use already used glitch effect in the original DDLC such as glitching sounds from the start of the Act II, easter egg menus, glitched dialogues, etc. Use random number generator to make things more interesting.

Other things to consider

Convenient things: Custom editors, packaging methods and others

Visual Studio Code/Notepad++ over Editra

When you install Renpy, there is a built-in editor that you can work with (usually Editra). But, I find that using Visual Studio Code or Notepad++ is more convenient than what Renpy offers. Reasons:

  • Better autofill
  • Dark mode VSC
  • Able to see changes (when editing inside Github folder, if you have GitHub Desktop installed) VSC
  • Other great features that I don't know

There is nothing wrong using Editra, as it is usable than a normal notepad. Use any code editor whatever it suits you. I recommend Visual Studio Code

Renpy's build distribution over RPATool

* This guide is entirely optional, you can proceed to pack your mods with whatever method you like. This method can be somehow confusing and can be lead to wrong things.

I use a "normal" way to pack this mod in zip form. Note: I said "normal" because it was supposed to be, but people don't use it very often. I find that people often use rpatool instead to repack their mods. It's a nice way to train yourself to use CMD, but there is another way to pack them. Using "build distribution" method already in Renpy makes your life easier. It would be a hassle at first setting them up, but in the end, it will be worth it. More info on build distribution: https://www.renpy.org/doc/html/build.html

In options.rpy, from line 221 in options.rpy:

build.package(build.directory_name + "source",'zip','source',description='Source Code Archive')
build.package(build.directory_name + "Mod",'zip',build.name,description='DDLC Compatible Mod')

This code sets up/declare package(s) that need to be distributed in .zip form. Source Code Archive is optional, you can remove it if you want

##Optionally include a zip file with all source code
build.classify('**.rpy','source')

## These files get put into your data file
build.classify("game/mod_assets/**","mod_assets") # packs every file inside mod_assets folder in form of .rpa
build.classify("game/core.rpyc",build.name) # the file that is not packed, but will be included in zip file
build.classify("game/options.rpyc",build.name) # the file that is not packed, but will be included in zip file
build.classify("game/script.rpyc",build.name) # the file that is not packed, but will be included in zip file
build.classify("game/splash.rpyc",build.name) # the file that is not packed, but will be included in zip file
build.classify("game/**.rpyc","mod_assets") # packs every .rpyc file inside game folder in form of .rpa
build.classify("README.html",build.name) # the file that is not packed, but will be included in zip file

This will packs every files necessary inside your working folder and distribute in .zip file automatically. You can pick which file you want to be packed or leave any file as-is. Note: You might want to name/update your mod with proper version in the same file (options.rpy)

After setting up everything inside options.rpy, you can go ahead and pack everything up.

* There will be pictures coming soon