Game
Untitled Deltarune Mod/Fangame
1 year ago

Development Update

<< content in article below >>


The original dialogue format of TobyFox games is quite convoluted and cryptic. How cryptic? Check the code below for an incomplete translation function, to get a feel of what I mean. I will therefore try to copy over the dialogue in a more human readable format. YarnScript. It's easier to change and better for translating if I want to do that at some point.

On another note. GameMaker (the program that is used to develop Deltarune and Undertale) has added most of their features to their free license. So if you ever wanted to mess around with that kinda stuff now would be the time.

		
			// YARN EXAMPLE
Gaster: ARE YOU #before:[x,110][y,80][speed,0.25][delay,8000] #after:[delay,1334]
        THERE? #after:[delay,1334][fade_out,1.334][go_to_next_page][/page]
Gaster: ARE WE #before:[speed,0.25][delay,1334] #after:[delay,1334]
        CONNECTED? #after:[delay,1334][fade_out,1.334][go_to_next_page][/page]

Gaster: EXCELLENT. #before:[x,110][y,50][speed,0.25] #after:[delay,667][fade_out,1.334][go_to_next_page][/page]
Gaster: TRULY #before:[speed,0.25][delay,1334] #after:[delay,667]
        EXCELLENT. #after:[delay,667][fade_out,1.334][go_to_next_page][/page]
<<jump now_we_may_begin>>

		
	
		
			// CRYPTIC_OG_COMMAND_REPLACER - INCOMPLETE
function replace_legacy_typewriter_commands(_string) {
    // NOTHING
    string_replace(_string, "|", "")
    string_replace(_string, "`", "")
    // NEWLINE
    string_replace(_string, "&", "\n")
    string_replace(_string, "#", "\n")
    // COLOUR
    string_replace(_string, "\\cR", "[c_red]")
    string_replace(_string, "\\cB", "[c_blue]")
    string_replace(_string, "\\cY", "[c_yellow]")
    string_replace(_string, "\\cG", "[c_lime]")
    string_replace(_string, "\\cW", "[c_white]")
    string_replace(_string, "\\cX", "[c_black]")
    string_replace(_string, "\\cP", "[c_purple]")
    string_replace(_string, "\\cM", "[c_maroon]")
    string_replace(_string, "\\cS", "[#16744703]")
    string_replace(_string, "\\cV", "[#8454016]")
    string_replace(_string, "\\c0", "[c_white]") // -> mycolor FROM TEXTSETUP
    // SPRITE
    for (i = 0; i < 10; i++) {
        var _command = quot;\\I{i}"
        if (!string_count(_command, _string)) { continue }
        string_replace(_string, _command, quot;[{sprite_get_name(WRITER_IMAGE[i])}]")
    }
    // BUTTON_SPRITE
    var _values = ["A", "D", "W", "S", "Z", "X", "C"]
    for (var i = 0; array_length(_values); i++) {
        var _command = quot;\\*{_values[i]}"
        if (!string_count(_command, _string)) { continue }
        string_replace(_string, _command, quot;[scale,2][{sprite_get_name(scr_getbuttonsprite(_values[i], true))}][/scale]")
    }
    // AUDIO
    for (i = 0; i < 10; i++) {
        var _command = quot;\\S{i}"
        if (!string_count(_command, _string)) { continue }
        string_replace(_string, quot;\\S{i}", quot;[{audio_get_name(WRITER_SOUND[i])}]")
    }
    // DELAY
    string_replace(_string, "^1", "[delay,167]")
    string_replace(_string, "^2", "[delay,334]")
    string_replace(_string, "^3", "[delay,500]")
    string_replace(_string, "^4", "[delay,667]")
    string_replace(_string, "^5", "[delay,1000]")
    string_replace(_string, "^6", "[delay,1334]")
    string_replace(_string, "^7", "[delay,2000]")
    string_replace(_string, "^8", "[delay,3000]")
    string_replace(_string, "^9", "[delay,5000]")
    // SKIPPABLE
    string_replace(_string, "\\s0", "[variable,skippable,bool,false]")
    string_replace(_string, "\\s1", "[variable,skippable,bool,true]")
    // STOP
    string_replace(_string, "/%", "[variable,halt,number,2][/page]") // halt = 2
    // DESTROY
    string_replace(_string, "/", "[variable,halt,number,1][/page]") // halt = 1
    // SMALL_FACE
    for (i = 0; i < 10; i++) { string_replace(_string, quot;\\f{i}}", quot;[smallface,{i}]") }
    // MINI_FACE
    for (i = 0; i < 10; i++) { string_replace(_string, quot;\\m{i}", quot;[miniface,{i}]") }
    // DRAWSTAR
    string_replace(_string, "\\m", "[variable,drawaster,bool,false]")
    // CHOICER
    for (i = 1; i <= 4; i++) { string_replace(_string, quot;\\C{i}", "[choice,{i}]") }
    // FLAG20
    for (i = 0; i < 10; i++) { string_replace(_string, quot;\\M{i}", "[flag,20,{i}]") }
    // TYPIST
    string_replace(_string, "\\T0", "[dialoguer,narrator]")
    string_replace(_string, "\\T1", "[dialoguer,narrator][silent]")
    string_replace(_string, "\\TA", "[dialoguer,asgore]")
    string_replace(_string, "\\Ta", "[dialoguer,alphys]")
    string_replace(_string, "\\TN", "[dialoguer,noelle]")
    string_replace(_string, "\\TX", "[dialoguer,noelle][speed,0.5][silent]")
    string_replace(_string, "\\Tn", "[dialoguer,noelle,tiny]")
    string_replace(_string, "\\TB", "[dialoguer,berdly]")
    string_replace(_string, "\\TS", "[dialoguer,susie]")
    string_replace(_string, "\\TR", "[dialoguer,ralsei]")
    string_replace(_string, "\\TL", "[dialoguer,lancer]")
    string_replace(_string, "\\Tr", "[dialoguer,rudolph]")
    string_replace(_string, "\\TT", "[dialoguer,toriel]")
    string_replace(_string, "\\TJ", "[dialoguer,jevil]")
    string_replace(_string, "\\TK", "[dialoguer,king]")
    string_replace(_string, "\\Tq", "[dialoguer,queen_2]")
    string_replace(_string, "\\TQ", "[dialoguer,queen_1]")
    string_replace(_string, "\\Ts", "[dialoguer,sans]")
    string_replace(_string, "\\TU", "[dialoguer,undyne]")
    string_replace(_string, "\\Tp", "[dialoguer,spamton_neo]")
    // FACE
    string_replace(_string, "\\F0", "[speaker,none]") // fc : 0
    string_replace(_string, "\\FS", "[speaker,susie]") // fc : 1
    string_replace(_string, "\\FR", "[speaker,ralsei]") // fc : 2
    string_replace(_string, "\\FN", "[speaker,noelle]") // fc : 3
    string_replace(_string, "\\FT", "[speaker,toriel]") // fc : 4
    string_replace(_string, "\\FL", "[speaker,lancer]") // fc : 5
    string_replace(_string, "\\Fs", "[speaker,sans]") // fc : 6
    string_replace(_string, "\\FU", "[speaker,undyne]") // fc : 9
    string_replace(_string, "\\FA", "[speaker,asgore]") // fc : 10
    string_replace(_string, "\\Fa", "[speaker,alphys]") // fc : 11
    string_replace(_string, "\\FB", "[speaker,berdly]") // fc : 12
    string_replace(_string, "\\Fr", "[speaker,rudolph]") // fc : 15
    string_replace(_string, "\\Fu", "[speaker,rouxls]") // fc : 18
    string_replace(_string, "\\FK", "[speaker,king]") // fc : 20
    string_replace(_string, "\\FQ", "[speaker,queen]") // fc : 21
    // EMOTION
    for (var i = 48; i <= 122; i++) {
        if (i >= 48 && i <= 57) {
            string_replace(_string, quot;\\E{chr(i)}", quot;[face,{i}]")
        } else if (i >= 65 && i <= 90) {
            string_replace(_string, quot;\\E{chr(i)}", quot;[face,{i - 55}]")
        } else if (i >= 97 && i <= 122) {
            string_replace(_string, quot;\\E{chr(i)}", quot;[face,{i - 61}]")
        }
    }

    return _string
}
		
	


1 comment

Loading...

Next up

Great Board Progress

Battle Message Sprite Font (WIP)

Feel free to use this sprite font if you want or point out if a symbol looks out of place.

Making Progress with Overworld Attacks

Overworking the Control System to use the Input 6.0 Library to accommodate the additional controls as well as to show the alternative input mappings. (screen also switches between keyboard/gamepad automatically depending on what is connected)

If you are wondering, I am still working on the game.

I will add a badge mechanic (Paper Mario). Each character will receive badge points on level up. Badges apply a continuous effect to the equipping character and cost badge points to equip.

I am experimenting with allowing different aspect ratio settings. Unsure yet how much effort it would take to fully implement this.

Overworld X-Slash

Variable Tension Bar – supports overhealing – the bar is full when current_tp == max(100% tp, current_tp)

Apparently I can make the game upscale certain things like Jevil's arena

Damage Reflection Spell