The Dink Network

Reply to Re: Why does the grunt wav sound super-low?

If you don't have an account, just leave the password field blank.
Username:
Password:
Subject:
Antispam: Enter Dink Smallwood's last name (surname) below.
Formatting: :) :( ;( :P ;) :D >( : :s :O evil cat blood
Bold font Italic font hyperlink Code tags
Message:
 
 
January 5th 2013, 05:24 AM
anon.gif
shevek
Ghost They/Them
 
pillbugs don't do any damage to the player at all.

That is correct. Pillbugs hurt Dink through touch damage. If you set that to -1, they will no longer hurt him. However, because your script is run, you can make them hurt Dink in there:

void touch()
{
    sp_touch_damage(&current_sprite, 0);
    hurt(1, 5);
    sp_seq(&current_sprite, <insert dying sequence here ;
    sp_frame(&current_sprite, 1);
    sp_brain(&current_sprite, 5);
}


This first makes sure touch() is only called once, then hurts Dink, then sets the sprite's animation to its way to die, which is then run and left at the background with brain 5. If you don't want a death animation, you can simply use sp_active(&current_sprite, 0); instead.

Note that with the above script, they will always do exactly 5-defense damage, which isn't equivalent of touch damage 5. If you want that, you should compute random (5/2, 5/2) (a random value from the upper half of the touch damage) and use the result.