The Dink Network

Reply to Re: The Intro-duck-tion

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 17th 2018, 12:06 PM
spike.gif
SlipDink
Peasant He/Him United States bloop rumble
2nd generation. No easy way to be free. 
@toof:
> and the guy, never shows up...

Maybe part of the problem you are having with &narr not seeming to be created is that you tried to create it as a corpse, using brain #5(*) and sprite 343. So, that suggests to me that DinkC should display the red merchant animation, starting from frame 4 and then stop at the end of that animation. But in the next line, you use 370 as the parameter for sp_base_walk() for the newly created &narr sprite, which is actually the blue merchant. I understand why you'd think that should work. After all, Seth seemed to make changes sort of like this all the time, though they were different. Take this example where (as he often does), he uses alot of zeros for create_sprite() and then makes external assignments found in s3-tc.c in the source for the original game.

&pp8 = create_sprite(295, 50, 0, 0, 0);
sp_brain(&pp8, 16);
sp_base_walk(&pp8, 370);
sp_speed(&pp8, 1);
sp_timing(&pp8, 0);
//set starting pic
sp_pseq(&pp8, 373);
sp_pframe(&pp8, 1);
sp_script(&pp8, "s3-peeps");


But perhaps your code does not work because you chose brain 5 for your brain type in your create_sprite() function call and then changed the sprite? Anyway, if you decide to try any of these possible changes(see below), let me know if one of them helps.

int &narr = create_sprite(143,231,16,373,4);
sp_base_walk(&narr, 370);


int &narr = create_sprite(143,231,0,373,4);
sp_base_walk(&narr, 370);
sp_brain(&narr, 5);


int &narr = create_sprite(143,231,0,373,4);
sp_base_walk(&narr, 370);
sp_brain(&narr, 16);


(*)(from DinkC Reference v4.0 from sp_brain() description)
5 Sequence (Corpse) Plays through the current sequence and kills the sprite, but leaves the last frame drawn to the background.