HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Reverse Evasion?

11-06-2004, 05:13 PM#1
Kalar
Is there any way to attach an ability to a unit that causes him to miss an attack at a certain % rate?

IE: Accuracy - This unit has a 60% chance to hit, therefore give him a .40 chance to miss?

Anyone, please?
11-06-2004, 06:03 PM#2
Guest
there is an ability called curse that gives a unit a percent chance to miss.
11-06-2004, 10:18 PM#3
Kalar
Quote:
Originally Posted by DirtyTricks
there is an ability called curse that gives a unit a percent chance to miss.
Right, but I mean a permenant ability that you can read like critical strike or evasion, not an effect from another unit's spell.
11-06-2004, 11:45 PM#4
cacophony
Quote:
Originally Posted by Kalar
Right, but I mean a permenant ability that you can read like critical strike or evasion, not an effect from another unit's spell.

You would probably have to do this with triggers and a dummy unit. Have it so when the skill is researched a dummy unit casts whatever miss % you want with Curse. Give it a long duration and order the dummy unit to cast it again when that duration is over. Another option would be to give all your enemy units some level of Evasion. You can also tweak chance to miss % for moving or high ground objects in Gameplay Constants.
11-06-2004, 11:48 PM#5
Guest
i dont know what you mean by reading critical strike or evasion. i assume you mean you want something passive.

the we lets me enter a negative value for evasion, see what that does.

also maybe make an ability based off channel and give it the curse buff. not sure if that would stuff have the effect of curse, or just the art though.

EDIT: just tested evasion with -1.00, and it does nothing at all.
11-07-2004, 03:42 AM#6
Squally425
I think he meant he wants an ability that his hero has which would make the HERO miss...
Kinda like the gamble hero I tried to make earlier in the year.

Your best bet would be to utilize the new "infinite duration/0" on curse, then create a dummy unit to cast curse on it.

Otherwise... you could try.. a trigger where when that hero attacks a unit, heal that unit for the damage u did and so it looks like you missed?

I don't know for sure.
11-07-2004, 04:35 AM#7
Kalar
Quote:
Originally Posted by Squally425
Your best bet would be to utilize the new "infinite duration/0" on curse, then create a dummy unit to cast curse on it.

Yeah, I suppose I'll have to do that---a bit complicated, but if that's all I've got...
11-07-2004, 02:55 PM#8
nctltsf
Quote:
Originally Posted by Kalar
Yeah, I suppose I'll have to do that---a bit complicated, but if that's all I've got...

You're right that is a bit complicated - If I understand you correctly then you should do what I do.

Use critical strike, set the percent chance to whatever you want. The damage multiplier should be .01 (.00 will not work) This way, you will get 0s or perhaps a 1 if the unit does a lot a damage, but it is much more simple than using dummy units.
11-07-2004, 06:32 PM#9
Squally425
In order for critical strike to work nicely, then you'll need floating text to show when it misses. Then you'll have to get into the triggering where it detects critical strike, and does a floating text. Without it, the miss doesn't show up and you might never know if you miss.

I think the curse method is easier.
Make a unit with a custom curse.
When your unit is created/trained make a dummy unit close to caster, cast curse, remove dummy unit. Just have two events in the event area, one is created ,and one is revived.
11-07-2004, 06:44 PM#10
duckduck
i just thought of this while reading and have no clue if it will work or not.

Make a spell critical strike
Make the percent the chance you want to miss
damage multiplier, make it 0

that will make it do 0 damage. but there will be no miss thing and there might be a red 0 that floats up
11-07-2004, 06:46 PM#11
duckduck
with WEU you could create a miss thing, but there is no event to pick it up
11-07-2004, 07:48 PM#12
nctltsf
Quote:
Originally Posted by Squally425
Without it, the miss doesn't show up and you might never know if you miss.

Not true. While you will not see the normal "miss" you will see a "0." It isn't perfect, but if you're feeling lazy about triggers it's the way to go.
11-07-2004, 10:53 PM#13
Vexorian
Events : A unit is attacked
Conditions :
Level of (reverse evasion for (Attacking unit)) greater than 0)
Math - Random Number between (0 and 100) less than or equal to (Level of (reverse evasion for (Attacking unit)) * 10

Actions:
set temppoint = Position of (attacking unit)
Create one cursecaster at temppoint for owner of Attacking unit)
Order last created unit to Curse (attacking unit)
Unit - add a 0.1 seconds expiration timer to last created unit
Custom Script: call RemoveLocation(udg_temppoint)