Time script
K i am using this script to basically start on one screen then once dink goes to the designated player_map it activates. Instead once i get on the screen that has this script it just crashes dink. The way it should work is loop continuously until it reaches the designated screen in which it will run the if statement then kill the task.
void main(void)
{
int &isthisdone = 0;
if(&isthisdone == 0)
{
script_attach(1000);
&isthisdone = 1;
loop:
if(&player_map == 678)
{
wait(60000);
freeze(1);
say_stop("Wow i am so confused.... where... am... I", 1);
fade_down();
sp_x(1, 267);
sp_y(1, 242);
&player_map = 710;
load_screen();
draw_screen();
draw_status();
fade_up();
say_stop("Huh I am at the beginning again", 1);
kill_this_task();
}
goto loop;
}
}
void main(void)
{
int &isthisdone = 0;
if(&isthisdone == 0)
{
script_attach(1000);
&isthisdone = 1;
loop:
if(&player_map == 678)
{
wait(60000);
freeze(1);
say_stop("Wow i am so confused.... where... am... I", 1);
fade_down();
sp_x(1, 267);
sp_y(1, 242);
&player_map = 710;
load_screen();
draw_screen();
draw_status();
fade_up();
say_stop("Huh I am at the beginning again", 1);
kill_this_task();
}
goto loop;
}
}
It crashes because there's no wait command between loop: and goto loop;
Put wait(100); right before goto loop; and it should work.
Put wait(100); right before goto loop; and it should work.