Reply to Re: Help with spikes...
If you don't have an account, just leave the password field blank.
void main( void )
{
//-1, so it uses the script instead of damaging the player no matter what sp_touch_damage(¤t_sprite, -1)
}
void touch( void )
{
//Prevent touch-loop lockup
sp_touch_damage(¤t_sprite, 0);
int &boots = compare_weapon("item-boots");
if (&boots == 0)
{
//Don't have the boots? Die, fetcher!
hurt(1,100000);
}
//Again some touch-loop lockup prevention.
wait(100);
sp_touch_damage(¤t_sprite, -1);
}
That should work...
About the touch-loop lockup, if you don't set sp_touch_damage to 0 in the touch script, the engine will keep detecting a touch, and run the touch procedure, effectively getting nowhere.
{
//-1, so it uses the script instead of damaging the player no matter what sp_touch_damage(¤t_sprite, -1)
}
void touch( void )
{
//Prevent touch-loop lockup
sp_touch_damage(¤t_sprite, 0);
int &boots = compare_weapon("item-boots");
if (&boots == 0)
{
//Don't have the boots? Die, fetcher!
hurt(1,100000);
}
//Again some touch-loop lockup prevention.
wait(100);
sp_touch_damage(¤t_sprite, -1);
}
That should work...
About the touch-loop lockup, if you don't set sp_touch_damage to 0 in the touch script, the engine will keep detecting a touch, and run the touch procedure, effectively getting nowhere.







