The Dink Network

Re: New Sprite - Errors

April 13th 2010, 03:26 AM
sob_scorpy.gif
DinkDude95
Peasant He/Him Australia
The guy with the cute D-Mod. 
I've got this sprite, it's touchable, when you touch it, a new sprite is created in it's place and it's made invisible. However, for a split second, the sprite appears in the wrong place. Towards the bottom right of the screen. Here is the touch procedure, does anyone know what's wrong?

void touch( void )
{
  sp_touch_damage(&current_sprite, 0);
  freeze(1);
  &climb = create_sprite(445, 135, 7, 38, 1);
  sp_nodraw(1, 1);
  sp_seq(&climb, 38);
}
April 13th 2010, 03:41 AM
dinkdead.gif
If in doubt, try a wait(1)

Stick it after the freeze and see if it helps. Also did you mean to make Dink invisible or &current_sprite?
April 13th 2010, 05:25 AM
wizardb.gif
Kyle
Peasant He/Him Belgium
 
It looks like he's making Dink do a climb animation, but with a dummy sprite to represent Dink, so he makes the real one invisible. You could also try preloading the climb animation, similar to how indeed a wait(1) can solve things
April 13th 2010, 05:55 AM
sob_scorpy.gif
DinkDude95
Peasant He/Him Australia
The guy with the cute D-Mod. 
The sequence is preloaded and I tried adding a wait(1); but still no dice. Anything more?
April 13th 2010, 06:44 AM
sob_scorpy.gif
DinkDude95
Peasant He/Him Australia
The guy with the cute D-Mod. 
Aha! I've fixed the problem; really weird problem though.
I loaded the graphics in sequence 39 instead of 38. Yeah, seriously, now it works perfectly. I don't know what the hell is with that, but that's it. Sequence 38 was the problem.
April 13th 2010, 07:12 AM
wizardb.gif
Kyle
Peasant He/Him Belgium
 
Well, what matters is you fixed it Well done!