pt's Profile
At the moment am I busy with getting the bugs out of the scripts and so.
one thing I cannot solve.
I have copied a script (see below) from a chest. I changed gold from 500 to 200.
but it doesn't work.
only 500 gold works, not 200.
what is the problem?
THE SCRIPT:
//script for chest with 200 gold in it
void main( void)
{
preload_seq(177);
}
void hit ( void )
{
//play noise
int &hold = sp_editor_num(&current_sprite);
if (&hold != 0)
{
//this was placed by the editor, lets make the chest stay open
editor_type(&hold, 4);
editor_seq(&hold, 177);
editor_frame(&hold, 6);
//type means show this seq/frame combo as background in the future
}
&save_x = sp_x(&current_sprite, -1);
&save_y = sp_y(&current_sprite, -1);
external("make", "gold200");
sp_seq(&current_sprite, 177);
sp_script(&current_sprite, "");
sp_notouch(&current_sprite, 1);
sp_nohit(&current_sprite, 1);
}
one thing I cannot solve.
I have copied a script (see below) from a chest. I changed gold from 500 to 200.
but it doesn't work.
only 500 gold works, not 200.
what is the problem?
THE SCRIPT:
//script for chest with 200 gold in it
void main( void)
{
preload_seq(177);
}
void hit ( void )
{
//play noise
int &hold = sp_editor_num(&current_sprite);
if (&hold != 0)
{
//this was placed by the editor, lets make the chest stay open
editor_type(&hold, 4);
editor_seq(&hold, 177);
editor_frame(&hold, 6);
//type means show this seq/frame combo as background in the future
}
&save_x = sp_x(&current_sprite, -1);
&save_y = sp_y(&current_sprite, -1);
external("make", "gold200");
sp_seq(&current_sprite, 177);
sp_script(&current_sprite, "");
sp_notouch(&current_sprite, 1);
sp_nohit(&current_sprite, 1);
}