Reply to Re: Help with script please
If you don't have an account, just leave the password field blank.
I got it to work!!
I went with this:
void main( void )
{
int &dumb = create_sprite(360, 300, 0, 64, 1);
sp_hard(&dumb, 0);
draw_hard_sprite(&dumb);
sp_disabled(&dumb, 1);
sp_base_walk(¤t_sprite, 370);
sp_speed(¤t_sprite, 3);
sp_timing(¤t_sprite, 0);
}
void hit( void )
{
say("`3Wimp!", ¤t_sprite);
}
void talk( void )
{
freeze(1);
choice_start();
set_y 240
set_title_color 9
title_start();
"A tall man with brown hair and a sly grin stands here"
title_end();
"Pay the toll"
"Argue"
"Leave"
choice_end();
if (&result == 1)
{
if (&gold < 100)
{
wait(500);
say_stop("`3You don't have enough gold!", ¤t_sprite);
unfreeze(1);
return;
}
if (&gold > 99)
{
wait(500);
say_stop("`3Thanks. See ya.", ¤t_sprite);
&gold -= 100;
move_stop(¤t_sprite, 4, -50, 1);
&story = 4;
force_vision(0);
unfreeze(1);
return;
}
}
if (&result == 2)
{
wait(500);
say_stop("How come I have to pay?",1);
wait(500);
say_stop("`3Just doing my job, kid.", ¤t_sprite);
wait(500);
say_stop("Well, 100 gold is a little high!", 1);
wait(500);
say_stop("`3Then leave!", ¤t_sprite);
wait(500);
say_stop("Jerk!", 1);
}
unfreeze(1);
}
Plus I had a vision script on the base.SO it's all good.
In fact, my game is now playable right through.Just want
to add some more 'new graphics' and then I guess I'll
submit it.YAY! I probably won't win but I'm glad I finally
worked out the glitches.Heh.
Thanks redink1 and magicman!
I went with this:
void main( void )
{
int &dumb = create_sprite(360, 300, 0, 64, 1);
sp_hard(&dumb, 0);
draw_hard_sprite(&dumb);
sp_disabled(&dumb, 1);
sp_base_walk(¤t_sprite, 370);
sp_speed(¤t_sprite, 3);
sp_timing(¤t_sprite, 0);
}
void hit( void )
{
say("`3Wimp!", ¤t_sprite);
}
void talk( void )
{
freeze(1);
choice_start();
set_y 240
set_title_color 9
title_start();
"A tall man with brown hair and a sly grin stands here"
title_end();
"Pay the toll"
"Argue"
"Leave"
choice_end();
if (&result == 1)
{
if (&gold < 100)
{
wait(500);
say_stop("`3You don't have enough gold!", ¤t_sprite);
unfreeze(1);
return;
}
if (&gold > 99)
{
wait(500);
say_stop("`3Thanks. See ya.", ¤t_sprite);
&gold -= 100;
move_stop(¤t_sprite, 4, -50, 1);
&story = 4;
force_vision(0);
unfreeze(1);
return;
}
}
if (&result == 2)
{
wait(500);
say_stop("How come I have to pay?",1);
wait(500);
say_stop("`3Just doing my job, kid.", ¤t_sprite);
wait(500);
say_stop("Well, 100 gold is a little high!", 1);
wait(500);
say_stop("`3Then leave!", ¤t_sprite);
wait(500);
say_stop("Jerk!", 1);
}
unfreeze(1);
}
Plus I had a vision script on the base.SO it's all good.
In fact, my game is now playable right through.Just want
to add some more 'new graphics' and then I guess I'll
submit it.YAY! I probably won't win but I'm glad I finally
worked out the glitches.Heh.
Thanks redink1 and magicman!






