The Dink Network

Reply to Re: WDE 2 crash

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:
 
 
July 28th, 07:27 PM
death.gif
Seseler
Peasant He/Him Heard Island And Mcdonald Islands
 
At least "vanilla" Dink Smallwood comes scripts on file called source.zip on develop folder (HD seems to not include it).

For bombs:

For checking if bomb hit something you usually do something like this in the intended target's hit procedure:
void hit( void )
{
  int &rcrap = compare_sprite_script(&missle_source, "dam-bomn");
  if (&rcrap == 1)
  {
    //do stuff
  }
}


see e.g. s4-rock.c on main game.

To do something if bomb doesn't hit stuff...
The best I can think is to modify dam-bom.c with something like this at the end:
//Wait for the bomb hit sequence to end
wait(1400);

//&foo here is some global variable - the intended target should set it to 1 when hit with the bomb
if(&foo != 1)
{
  //bomb did not hit
}


Note: if you do modify dam-bom.c, please add a "script_attach(0);" at the start of the main(). This will fix an annoying bug in bomb use.