Author Topic: Enemy Armour  (Read 5927 times)

rpc190

  • Posts: 44
  • Map Maker
    • View Profile
Enemy Armour
« on: June 06, 2014, 12:54:00 AM »
I'm very close to releasing a series of maps for HammerWatch but I have one thing I haven't been able to accomplish. If anyone can confirm that this either can't be done or advise a way to accomplish it I would appreciate it:

I'm looking for a way to temporarily give an enemy increased armour or make it invulnerable.

Before you suggest ideas note the following:
- I'm aware that you can create armour abilities for composite monsters but see no way to make it temporary.
- Using the toggle immortality script is not something I can do.
- I would prefer some sort of script to be added to a buff.

Kashlavor

  • Posts: 79
  • Spike Dodger.
    • View Profile
Re: Enemy Armour
« Reply #1 on: June 06, 2014, 07:34:55 AM »
You'll have to give a few more specifics about when and how you want it to happen.  Is it only on certain monsters? is it for a boss? What exactly are you doing is all I'm wondering.

I think the best that you could do would be to create a new actor with the buff ability to affect players, and have it set the player's damage multiplier to 0.0, rendering them unable to attack for a short time.  You could then use scripts to spawn and destroy (using a danger area perhaps) this actor as need be.  You would just need to make sure that its buff range was incredibly large (enough to cover the room) and if you wanted you could make its sprite invisible so it wouldn't interfere with gameplay.

You could also just use the passive armor skill, and only give it a certain number of uses if thats what you're after, but I feel like it is something else you're thinking of.

The only other idea I can think of would be to create a buff which gives all monsters an incredibly large amount of healing, rendering them essentially unkillable for a short time.

If what you're looking for is a way to make a single enemy temporarily unkillable for short periods, I cannot think of a direct way.  Why won't the toggle immortality script work?
Starting work on the Lair of the Archnecromantrix, a Hammerwatch campaign!

rpc190

  • Posts: 44
  • Map Maker
    • View Profile
Re: Enemy Armour
« Reply #2 on: June 06, 2014, 11:21:02 AM »
You pretty much summed up what I'm looking for in your last bit. Needs to be for 1 type of non-boss monster and only that monster, toggled on and off with use of an ability. I didn't consider the toggle immortality script an option because if there are hundreds on this monster on one map then it isn't very practical to use it.

The healing idea is decent, but it would mean that a partially damage monster would regenerate to full every time which I don't want, but wouldn't be the end of the world.

Kashlavor

  • Posts: 79
  • Spike Dodger.
    • View Profile
Re: Enemy Armour
« Reply #3 on: June 06, 2014, 09:08:15 PM »
You could make that particular monster and script setup into a prefab.  Just make the actor normally, include the ToggleImmortality on a Timer or something, and then save it is a prefab and then place down the prefab as opposed to directly placing the actor.
Starting work on the Lair of the Archnecromantrix, a Hammerwatch campaign!

rpc190

  • Posts: 44
  • Map Maker
    • View Profile
Re: Enemy Armour
« Reply #4 on: June 07, 2014, 12:55:31 AM »
That is a good idea, it comes with problems as I want to tie the effect to an animation and have it toggle on and off periodically, but I'll fiddle with it and maybe come up with something, thanks.

Kashlavor

  • Posts: 79
  • Spike Dodger.
    • View Profile
Re: Enemy Armour
« Reply #5 on: June 07, 2014, 10:22:03 AM »
Then you're in luck, you appear to be the lucky winner to have found a new and exciting use for the "Level Event" ability which Hipshot posted about.  You could use that to trigger the animation, and then have the Level Event be an event which actually triggers the Toggle Immortality script inside your prefab.  Its all on the composite skills post.

The only problem would be is that all of them would have their immortality triggered simultaneously, but this wouldn't be a problem so long as you didn't expect to have more than one of these crazy things on the screen at one time.  If you were very dedicated to this I think the only way you could really make it work to have an easy to place mob, having multiple at once, each capable of being invincible at different times, would be to make a number of different prefabs, each working off a different event, and then make sure that when you place down groups no two of them work off the same event trigger in the same room.

If you wanted to you could also make a tower looking actor, make it look big and scary, and have it be the one which plays the animation and triggers the event, making all its minions invincible.  This way it would seem more plausible when all its minions become unkillable simultaneously.
Starting work on the Lair of the Archnecromantrix, a Hammerwatch campaign!