it would be possible to create enemies fighting among themselves?

Status
Not open for further replies.

viniXD

Member
a wad that made crawlas, robots guards, and other badnicks as metal and brakeggman all fight among themselves, shooting each at the others as do with players.

something like this is possible? like the monsters of minecraft

---------- Post added at 04:27 PM ---------- Previous post was at 04:26 PM ----------

if so, it would be a very quick fight, because the robots die with one blow, but perhaps extending their life as the eggaman.
 
You can currently replicate this idea to some extent. If an enemy such as the eggmobile or crawla commander are attacked by a projectile such as a bullet or missile, they will make that attacker their new target. This means there will be instances where, say, a jettysyn gunner accidentally hits Robotnik and then Robotnik proceeds to laser the jettysyn in retaliation.

There's two problems however. First is that there's no currently coded mechanism that I'm aware of that will cause an enemy to target other enemies by default. The second is that there's no coded mechanism that will cause enemies to deal contact damage to each other. Even if two crawla commanders were to want to fight each other, they would simply spaz out in a circle amongst each other, dealing no damage.

I imagine that with some lua magic someone could fix those two issues. The first would probably have something to do with the SEE states, the second might just be a couple lines inclusion so that enemies deal contact damage to whoever they're targeting.
 
Lua can set an object's target directly by modifying mobj.target (mobj.tracer works in the same manner, too)
 
Neat, this feels a lot like DooM, with enemies getting mad at one another for friendly fire.

If you wanted to recreate this, you can set up a ShouldDamage hook and a MobjCollide hook. MobjCollide to determine melee attacks (Like the Sharp) and ShouldDamage to control what gets hurt. Also, in DooM, enemies of the same object type can't hurt one another normally. You could put a target changer in ShouldDamage to tell the object to immediately target the offending object until that object is dead.

Just bringing up ideas you could do with this.
 
Status
Not open for further replies.

Who is viewing this thread (Total: 1, Members: 0, Guests: 1)

Back
Top