Deltarune script viewer

← back to main script listing

gml_GlobalScript_scr_healallitemspell

(view raw script w/o annotations or w/e)
1
function scr_healallitemspell
scr_healallitemspell

function scr_healallitemspell(argument0) //gml_Script_scr_healallitemspell { scr_healall(argument0) for (i = 0; i < 3; i += 1) { with (global.charinstance[i]) { ha = instance_create(x, y, obj_healanim) ha.target = id dmgwr = scr_dmgwriter_selfchar() with (dmgwr) { delay = 8 type = 3 damage = argument0 } if (global.hp[global.char[myself]] >= global.maxhp[global.char[myself]]) { with (dmgwr) specialmessage = 3 } tu += 1 } } global.spelldelay = 20 }
(argument0) //gml_Script_scr_healallitemspell
2
{
3
    scr_healall
scr_healall

function scr_healall(argument0) //gml_Script_scr_healall { for (i = 0; i < 3; i += 1) { if (global.char[i] != 0) scr_heal(i, argument0) } }
(argument0)
4
    for (i = 0; i < 3; i += 1)
5
    {
6
        with (global.charinstance[i])
7
        {
8
            ha = instance_create(x, y, obj_healanim)
9
            ha.target = id
10
            dmgwr = scr_dmgwriter_selfchar
scr_dmgwriter_selfchar

function scr_dmgwriter_selfchar() //gml_Script_scr_dmgwriter_selfchar { return instance_create(x, (y + myheight - 24 - tu * 20), obj_dmgwriter); }
()
11
            with (dmgwr)
12
            {
13
                delay = 8
14
                type = 3
15
                damage = argument0
16
            }
17
            if (global.hp[global.char[myself]] >= global.maxhp[global.char[myself]])
18
            {
19
                with (dmgwr)
20
                    specialmessage = 3
21
            }
22
            tu += 1
23
        }
24
    }
25
    global.spelldelay = 20
26
}