HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Abilities help please

03-19-2007, 12:33 PM#1
Antinewb2503
1. I need help making some abilities which are passive (like critical strike) and have a chance on casting another (custom?) ability. Eg. The abillity gives you a 50% chance to cast War Stomp.

2.I made an ability which the ability "Soul Theft" is the base abillity. I want to make a trigger that when you have 5 souls (as in capturing 5 units) you gain some damage bonus or transform into another unit.

Kudos.
03-19-2007, 02:33 PM#2
StockBreak
Quote:
Originally Posted by Antinewb2503
1. I need help making some abilities which are passive (like critical strike) and have a chance on casting another (custom?) ability. Eg. The abillity gives you a 50% chance to cast War Stomp.

You should do as following (you will need a dummy caster, ask or made a search if you don't know what is it):

Trigger:
Critical Stomp
Collapse Events
Unit - A unit Is attacked
Collapse Conditions
(Level of War Strike (your custom ability) for (Attacking unit)) Greater than 0
Collapse Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Random integer number between 1 and 100) Less than or equal to 50
Collapse Then - Actions
Unit - Create 1 Dummy Caster for (Owner of (Attacking unit)) at (Position of (Attacking unit)) facing Default building facing degrees
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add War Stomp to (Last created unit)
Unit - Set level of War Stomp for (Last created unit) to (Level of War Strike for (Attacking unit))
Unit - Order (Last created unit) to Orc Tauren Chieftain - War Stomp
Collapse Else - Actions
Do nothing

I hope it helps. Cheers
03-20-2007, 01:26 AM#3
Pyrogasm
Just spreadin' the love: Putting a "Do Nothing" anyhere in a GUI script is completely and utterly useless.

Here's what the function looks like:
Collapse JASS:
function DoNothing takes nothing returns nothing
endfunction

Dumb, eh?
03-20-2007, 03:19 AM#4
st33m
Yeah I wondered why that was really... you know... real?

Anyway, you can also use the Lightnign Orb ability and hide it and use a dummy passive ability (or none if you want). You can also show it if you want, but it shows up kind of grayed out and looks funny. By hide it of course I mean use that spellbook trick.
03-20-2007, 11:38 AM#5
StockBreak
Quote:
Originally Posted by Pyrogasm
Just spreadin' the love: Putting a "Do Nothing" anyhere in a GUI script is completely and utterly useless.

Here's what the function looks like:
Collapse JASS:
function DoNothing takes nothing returns nothing
endfunction

Dumb, eh?
Yes I know, I just use it while in GUI because it makes the code more understandable, that's all