Can we make monsters hate non-monster/player objects?

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked
User avatar
Macil
Posts: 2529
Joined: Mon Mar 22, 2004 7:00 pm
Preferred Pronouns: He/Him
Location: California, USA. Previously known as "Agent ME".
Contact:

Can we make monsters hate non-monster/player objects?

Post by Macil »

Can we make monsters hate non-monster/player objects using Thing_Hate or or NoiseAlert? I've already tried so far with Thing_Hate and dead cacodemons and lights.

I want to make it look like a bunch of monsters are attacking a plane.
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Post by wildweasel »

Your best bet would be to slap a bunch of hate targets in there, but I don't know the details.
User avatar
Grubber
Posts: 1031
Joined: Wed Oct 15, 2003 12:19 am
Location: Czech Republic
Contact:

Post by Grubber »

Conditions for hating a thing:
1. flag SHOOTABLE must be set
2. it can't be dead (health > 0)
3. flag DORMAT must not be set
User avatar
Macil
Posts: 2529
Joined: Mon Mar 22, 2004 7:00 pm
Preferred Pronouns: He/Him
Location: California, USA. Previously known as "Agent ME".
Contact:

Post by Macil »

Thanks!

Anyways, I solved my problem by using an invincible and invisible lost soul.

What's a hate target?
User avatar
Enjay
 
 
Posts: 27306
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Post by Enjay »

Agent ME wrote:What's a hate target?
Probably thing type 9076. An invisible, blocking actor that can be used (amongst other things) as a hated item. The actor just sits there, but can be used to provide an object for an enemy with thing_hate to head for. If the enemy sees the hated item, it will attack it. The angle that you set the thing at is used to determine its health.
Last edited by Enjay on Wed Jun 15, 2005 1:50 pm, edited 1 time in total.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Post by Graf Zahl »

An invisible shootable thing. Just what you created by hacking.
User avatar
Macil
Posts: 2529
Joined: Mon Mar 22, 2004 7:00 pm
Preferred Pronouns: He/Him
Location: California, USA. Previously known as "Agent ME".
Contact:

Post by Macil »

How do we set it to be invincible?
User avatar
Enjay
 
 
Posts: 27306
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Post by Enjay »

Angle = 0 I *think* Maybe making it dormant would work too. Not sure.
Costja
Posts: 188
Joined: Mon Oct 18, 2004 3:58 pm
Location: Russia, Moscow
Contact:

Post by Costja »

Enjay, you're wrong, hate targets are not blocking:

Code: Select all

IMPLEMENT_ACTOR (AHateTarget, Any, 9076, 0)
	PROP_RadiusFixed (20)
	PROP_HeightFixed (56)
	PROP_Flags (MF_SHOOTABLE|MF_NOSECTOR|MF_NOGRAVITY|MF_NOBLOOD)
	PROP_SpawnState (0)
	PROP_MassLong (INT_MAX)
END_DEFAULTS
User avatar
Macil
Posts: 2529
Joined: Mon Mar 22, 2004 7:00 pm
Preferred Pronouns: He/Him
Location: California, USA. Previously known as "Agent ME".
Contact:

Post by Macil »

Costja wrote:Enjay, you're wrong, hate targets are not blocking:

Code: Select all

IMPLEMENT_ACTOR (AHateTarget, Any, 9076, 0)
	PROP_RadiusFixed (20)
	PROP_HeightFixed (56)
	PROP_Flags (MF_SHOOTABLE|MF_NOSECTOR|MF_NOGRAVITY|MF_NOBLOOD)
	PROP_SpawnState (0)
	PROP_MassLong (INT_MAX)
END_DEFAULTS
Yes, they do block. NOSECTOR simply means it doesn't use certain physics checks and its invincible.

Is it possible to make it not block?
User avatar
Enjay
 
 
Posts: 27306
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Post by Enjay »

Oops, you're quite right. Shootable but not blocking. My bad. Thanks for the correction.

BTW, angle 0 does seem to make it fairly invincible. A load of SSG shots didn't destroy it. Mind you, an MDK did.

[edit]Argh! cross posting.

I put one in a map and was able to walk through it as if it wasn't there. However, I was able to shoot it.[/edit]
Costja
Posts: 188
Joined: Mon Oct 18, 2004 3:58 pm
Location: Russia, Moscow
Contact:

Post by Costja »

Agent ME, what flags means it fully non-blocking?
Do you create vehicles too? ;)
User avatar
Macil
Posts: 2529
Joined: Mon Mar 22, 2004 7:00 pm
Preferred Pronouns: He/Him
Location: California, USA. Previously known as "Agent ME".
Contact:

Post by Macil »

+NOCLIP makes it fully non-blocking.

And about vehicles, I've thought about it, but I haven't. Anyways, the player can already move very fast...
User avatar
Risen
Posts: 5263
Joined: Thu Jan 08, 2004 1:02 pm
Location: N44°30' W073°05'

Post by Risen »

Grubber wrote:3. flag DORMAT must not be set
Of course. Everyone loves door mats!
Locked

Return to “Editing (Archive)”