The Dink Network

Spinning Attack

March 24th 2007, 02:22 AM
duckdie.gif
RadFrog
Peasant They/Them
 
Can someone help me understand this? In every INI I have looked at, the spinning attack for the goblin with the clubs is loaded by Dink.ini as sequence 780. Then the walk sequences are loaded as sequences 781 through 789. The Base Walk is 780, so it seems to me that there is a conflict.

Has anyone used the spinning attack successfully in their work? If so, what changes did you have to make to the dink.ini and properties file for the horned (horned?) goblin. It sounds kinda neat, so I would like to give it a whirl ('scuse the play on words).

RadFrog
March 24th 2007, 02:40 AM
wizardb.gif
Endy
Peasant He/Him United States
 
You're right there is a problem using it for "Dink" I had to modify it by changing the sequence it's loaded as. I made a playable version in the Goblin Fun dev file.

http://www.dinknetwork.com/file/goblin_fun/

It'd be cool if someone would find a use for it in a Dmod. My own is moving verrry slowwwly.
March 24th 2007, 03:07 AM
duckdie.gif
RadFrog
Peasant They/Them
 
After my original question, I thought about it some more and figured out how to make it work. I loaded the spin graphics into a new sequences as directions 2, 4, 6, and 8. It is kinda neat. Now I need to adjust it for distance, because that gobin is really swinging, but missing that cagey Dink.
March 24th 2007, 03:17 AM
spike.gif
There is no confilict... base_walk only uses 8 directions and xx5 for a death sequence, so 780 is a free slot.

There's no need to do anything to the sequence in dink.ini either, except give it set_frame_specials so the attack can actually hit something.

(EG.
set_frame_special 780 2 1
set_frame_special 780 3 1
set_frame_special 780 4 1
set_frame_special 780 5 1
set_frame_special 780 6 1
)

sp_seq(&current_sprite,780);
sp_frame(&current_sprite,1);

should work fine enough for enemies, though it could be fine tuned to work more perfectly.

sp_seq(1,780);
sp_frame(1,1);
sp_nocontrol(1,1);

should work nicely for dink.
March 24th 2007, 03:28 AM
wizardb.gif
Endy
Peasant He/Him United States
 
There was some sort of problem when I was using the horned goblin walking sequence for Dink. Whole program kept crashing on me.

At first I thought it was my codeing but I eventually narrowed it down to turning in a particular direction. For normal enemies it doesn't seem to matter much, but for Dink it sure does.

Kind of weird. It doesn't actually show up, but it seems improtant for the base sequence to be blank inorder for the walking sequence to work properly.
March 24th 2007, 03:34 AM
spike.gif
I'm sure it's a different problem... I've been using the spinning attack in a weapon script, and I think it was a spell in some dmod too- Birth of an empire IIRC. (though I'm not sure in which way he used it there.)

void use()
{
sp_seq(1,780);
sp_frame(1,1);
sp_nocontrol(1,1);
sp_kill_wait(1);
wait(1);
playsound(8,8000,0,0,0);
}

should work.

EDIT: Maybe you tried something like this?

&basehit = sp_dir(1,-1);
&basehit += 780;
sp_seq(1,&basehit);

That might make it crash when Dink is facing a certain direction. I haven't encountered any problems with using 780 as an attack at the same time as using it as a walking sequence, at least.
March 24th 2007, 09:56 AM
duckdie.gif
RadFrog
Peasant They/Them
 
In the spirit of consistancy, I made new sequence numbers for the spinning attack. Everything seems to be working fine and I don't deviate from the standard format.

I am also uploading a Dink.ini that is sorted numerically, including the spinning sequence as the 850 series.

Thanks for all the input.
March 24th 2007, 01:59 PM
spike.gif
I hope you're aware though that you only get 999 sequence slots. It's not a problem for most dmods but having to rearrange the dink.ini once all the slots are full is less than pleasant. So it's best to use the dink.ini as effectively as possible from the start... At least that's how I see it.