The Dink Network

Enemy won't target Dink

March 19th 2015, 06:33 PM
boncag.gif
JugglingDink
Peasant He/Him United Kingdom
Streetfish 
Guys.

I made a dragon that shoots fireballs.

Annoyingly it refuses to target anything. sp_follow() works fine, but that's not really what I'm after, and sp_target() commands are completely ignored by it.

Any ideas on why that might be?
March 19th 2015, 06:37 PM
peasantmp.gif
Skurn
Peasant He/Him Equatorial Guinea duck bloop
can't flim flam the glim glam 
Paste the script.

I probably won't figure it out, but I dunno. Maybe.

Also, brain 10 doesn't target stuff, so. Maybe that's it.
March 19th 2015, 06:44 PM
boncag.gif
JugglingDink
Peasant He/Him United Kingdom
Streetfish 
Oh. Yeah, I'm using brain 10, had no idea it doesn't target things. The DinkC reference lied, it told me it works on both the 9's and the 10's.

Guess I'll make a workaround with the follow command or something. Cheers anyway
March 19th 2015, 06:47 PM
peasantmp.gif
Skurn
Peasant He/Him Equatorial Guinea duck bloop
can't flim flam the glim glam 
You could always make the fireballs fall from the sky based on where Dink is.
March 19th 2015, 07:30 PM
boncag.gif
JugglingDink
Peasant He/Him United Kingdom
Streetfish 
Actually, that's not a bad idea. If I had them launch upwards from the dragons first that might be able to make a pretty neat effect. Maybe I'll make two dragons.

For now I've sorted it out by having them use sp_follow, then put in a kind of manual attack procedure like this:

//NOTE: I cut out pretty much everything irrelevant
void main(void)
{
	int &counts = 0;
	int &mcounter = random(40, 60);
	goto loop;
}

void shoot(void)
{
	loop:
	&counts += 1;
	wait(100);
	if(&counts < &mcounter)
	{
		goto loop;
	}
	//This set-up means the wait-time isn't forgotten when interrupted
	
	&counts = 0;
	&mcounter = random(20,30);

	//Attack scripts go here
}

void hit(void)
{
	//Make noises 'n' stuff
	goto loop;
}


For some reason directly calling it as a shoot() command made it ignore the loop-cycle, which is why I've ended up using the goto tags instead. Not the neatest thing, but hey-ho.
March 19th 2015, 10:50 PM
spike.gif
Brain 10 should work for launching fireballs. It works for the dragons in the original game; they run the attack procedure after a random timer, just like brain 9 monsters do.

What brain 10 won't work for is physically chasing after Dink, but hey, there's no law that states dragons have to be brain 10.
March 19th 2015, 10:54 PM
peasantmp.gif
Skurn
Peasant He/Him Equatorial Guinea duck bloop
can't flim flam the glim glam 
I just thought he meant the fireballs wouldn't be shot towards Dink. In the original game, the dragons don't even launch fireballs.

I know the script for Dink from mayhem throws hellfire based on where player Dink is, so maybe just copy that stuff over?
March 20th 2015, 01:01 AM
custom_msdink.png
MsDink
Peasant She/Her New Zealand
Tag - Umm.. tag, you're it? 
put a bunny tail on it... see if that helps?
March 20th 2015, 01:12 AM
peasantmp.gif
Skurn
Peasant He/Him Equatorial Guinea duck bloop
can't flim flam the glim glam 
Or perhaps attach attack scripts to non-drawn sprites on the screen?
March 20th 2015, 02:13 PM
boncag.gif
JugglingDink
Peasant He/Him United Kingdom
Streetfish 
I was a little vague. The dragons shot at Dink and everything fine, I just meant that I couldn't get them to physically walk in his direction.

I had the attack procedure set up with the attack_wait thing like it is in the original, but it never ran it, I assumed using sp_follow instead of sp_target made them not bother trying to attack. Although now that I think about it, I could have probably used sp_follow and sp_target at the same time to fix it. Oh well

I've sort of got it working now, they just don't like animating whenever they walk diagonally. There's only really a few instances where they pop up though, so I'm thinking I might just leave them as is.
March 20th 2015, 03:00 PM
peasantmp.gif
Skurn
Peasant He/Him Equatorial Guinea duck bloop
can't flim flam the glim glam 
I was a little vague. The dragons shot at Dink and everything fine, I just meant that I couldn't get them to physically walk in his direction.

Ooooh. Yeah, brain 10 doesn't do that.

Time to see what a dragon and Seth look like on brain 9.

EDIT: Well, original Dank doesn't spawn Seth, apparently. Only original Milder can.

So we can blame that fight on Milder, not Seth. K.