Reply to Re: Story scripts suck
If you don't have an account, just leave the password field blank.
Found a useful script:
void hit( void )
{
int &rcrap = compare_sprite_script(&missle_source, "dam-bomn");
if (&rcrap == 1)
{
//rock just got hit by a sprite with a script named dam-bomn, I'm gonna
//guess it was the bomb.
//remove rocks hardness and sprite
sp_hard(¤t_sprite, 1);
draw_hard_sprite(¤t_sprite);
sp_active(¤t_sprite, 0);
playsound(43, 22050, 0,0,0);
//kill this item so it doesn't show up again for this player
int &hold = sp_editor_num(¤t_sprite);
if (&hold != 0)
editor_type(&hold, 1);
}
}
It has a bug, though. If a bomb on the screen currently hits something other than the rock, and you hit the rock with your fists, then it'll also go away. There should be something to fix that, such as the sp_gold() trick and a simple modification in the bomb scripts, but I'm too lazy to make those now
void hit( void )
{
int &rcrap = compare_sprite_script(&missle_source, "dam-bomn");
if (&rcrap == 1)
{
//rock just got hit by a sprite with a script named dam-bomn, I'm gonna
//guess it was the bomb.
//remove rocks hardness and sprite
sp_hard(¤t_sprite, 1);
draw_hard_sprite(¤t_sprite);
sp_active(¤t_sprite, 0);
playsound(43, 22050, 0,0,0);
//kill this item so it doesn't show up again for this player
int &hold = sp_editor_num(¤t_sprite);
if (&hold != 0)
editor_type(&hold, 1);
}
}
It has a bug, though. If a bomb on the screen currently hits something other than the rock, and you hit the rock with your fists, then it'll also go away. There should be something to fix that, such as the sp_gold() trick and a simple modification in the bomb scripts, but I'm too lazy to make those now
