The Dink Network

s1-hole.c *Mystery Solved*

June 22nd 2011, 05:55 AM
custom_msdink.png
MsDink
Peasant She/Her New Zealand
Tag - Umm.. tag, you're it? 
S1-hole is driving me nuts
this is what I use
void main( void )
{
preload_seq(452);
}

void touch( void )
{
if (&life < 1) return;

freeze(1);
sp_x(1, 228);
sp_y(1, 302);
sp_seq(1, 452);
sp_frame(1, 1);
sp_nocontrol(1, 1); 
//dink can't move until anim is done!
sp_touch_damage(¤t_sprite, 0);
sp_brain(1, 0);
wait(2000);
sp_brain(1, 1);
&player_map = 161;
sp_x(1, 293);
sp_y(1, 298);
load_screen(161);
draw_screen();
}


Sometimes it works and others it doesnt - can you tell me how to set the prefs for this on the hole sprite so he crawls thru - usually he goes but it freezes at the end of the sequence then reboot time! Sorry spent ages on this and cant see whats missing... so maybe it is the preferences - hard, not, touch damage whaaaaaaat
June 22nd 2011, 06:48 AM
custom_magicman.gif
magicman
Peasant They/Them Netherlands duck
Mmmm, pizza. 
Touch damage should be -1 (you can set this in void main() if you want), and it shouldn't have hardness (better to do this in the map editor).
June 22nd 2011, 06:56 AM
custom_msdink.png
MsDink
Peasant She/Her New Zealand
Tag - Umm.. tag, you're it? 
Fiddled with the wait (added some) and the xy (I had set it to the middle of the hole not the very bottom) and bam All working fine now ta ! Thanks for the hint as well magic

Edit: yay the second one that he just stood at was not working cause he never got to touch it - was merely the depth it sat at YAY all fixed !
June 22nd 2011, 07:09 AM
custom_skull.gif
Skull
Peasant He/Him Finland bloop
A Disembodied Sod 
The script is always the boss over the map settings. If you want it to just act like a door without the sound, just change the sound to something more fitting, or remove it completely.

I understood your problem, that Dink doesn't crawl through the hole, but what exactly does he do instead, then?