HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

whats wrong here!?!?

07-31-2006, 07:55 AM#1
refl3ction
ok i have a trigger enchanced spell called Deadly Shadows, the basis of the skill is that the caster jumps around a region (centered at her original position) randomly... after each time she blinks she casts fan of knives then blinks again (she blinks 3 times, so she casts FoK 3 times) heres my trigger... and the spell is based of warstomp, but i made it do no damage and a very short stun time (.01):

Trigger:
Deadly Shadows
Collapse Events
Unit - A unit Begins casting an ability
Collapse Conditions
(Ability being cast) Equal to Deadly Shadows (Reaver)
Collapse Actions
Set Target = (Random point in (Region centered at (Position of (Casting unit)) with size (500.00, 500.00)))
Unit - Order (Casting unit) to Night Elf Warden - Blink Target
Unit - Order (Casting unit) to Night Elf Warden - Fan Of Knives
Unit - Reset ability cooldowns for (Casting unit)
Wait 0.50 seconds
Unit - Order (Casting unit) to Night Elf Warden - Blink Target
Unit - Order (Casting unit) to Night Elf Warden - Fan Of Knives
Unit - Reset ability cooldowns for (Casting unit)
Wait 0.50 seconds
Unit - Order (Casting unit) to Night Elf Warden - Blink Target
Unit - Order (Casting unit) to Night Elf Warden - Fan Of Knives
Unit - Reset ability cooldowns for (Casting unit)
07-31-2006, 08:50 AM#2
Captain Griffen
Reset cooldowns before the order.

Use gametime waits.

You also leak regions.

Casting unit should be replaced with triggering unit.
07-31-2006, 09:00 AM#3
The)TideHunter(
Instead of

Trigger:
Set Target = (Random point in (Region centered at (Position of (Casting unit)) with size (500.00, 500.00)))

Put

Trigger:
Actions
Set Temp_Location = (Position of (Casting unit))
Set Temp_Region = (Region centered at Temp_Location with size (500.00, 500.00))
Set Temp_Location2 = (Random point in Temp_Region)
Custom script: call RemoveLocation(udg_Temp_Location)
Custom script: call RemoveRegion(udg_Temp_Region)

And the target location you want will be udg_Temp_Location2. Remember to remove it once you have finished.
07-31-2006, 01:58 PM#4
SFilip
also use
Trigger:
Unit - A unit Starts the effect of an ability
instead of
Trigger:
Unit - A unit Begins casting an ability

reason: begins casting usually fires before you lose the mana which can be exploited so that you interrupt before you even cast it. however your trigger would already fire at that time so the caster can probably "get away" with no mana lost...
07-31-2006, 05:53 PM#5
refl3ction
Quote:
Originally Posted by The)TideHunter(
Instead of

Trigger:
Set Target = (Random point in (Region centered at (Position of (Casting unit)) with size (500.00, 500.00)))

Put

Trigger:
Actions
Set Temp_Location = (Position of (Casting unit))
Set Temp_Region = (Region centered at Temp_Location with size (500.00, 500.00))
Set Temp_Location2 = (Random point in Temp_Region)
Custom script: call RemoveLocation(udg_Temp_Location)
Custom script: call RemoveRegion(udg_Temp_Region)

And the target location you want will be udg_Temp_Location2. Remember to remove it once you have finished.

do i put the custom script after the castin is done each time? or just once

EDIT: when i set Temp_Location2 then remove it using the custom script and i save the map i get this: Invalid Argument (rect) in the form of a compile error, and then the trigger is disabled.
07-31-2006, 07:23 PM#6
SFilip
every time.
07-31-2006, 07:40 PM#7
refl3ction
Trigger:
Actions
Set Temp_Location = (Position of (Triggering unit))
Set Temp_Region = (Region centered at Temp_Location with size (500.00, 500.00))
Set Temp_Location2 = (Random point in Temp_Region)
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Wait 0.50 game-time seconds
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Wait 0.50 game-time seconds
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Custom script: call RemoveLocation(udg_Temp_Location)
Custom script: call RemoveRegion(udg_Temp_Region)
Custom script: call RemoveLocation(udg_Temp_Location2)

theres my updated trigger, so ure sayin i need to put the custom script after every time
07-31-2006, 07:50 PM#8
The)TideHunter(
No, the reason for the custom script is to prevent the location and region leaks.
When you use "Centered Region" or "Position of SomeUnit", it creates a point, that point is then stuck in the game, you cant find it because you dident assign a variable to it.
So you assign it to a variable, use it, then remove it.
Otherwise the game will slowly but surly get more and more laggier.

Whenever you have finished with a point/group/region/anything, remove it.
So in your case, if your still using it, and you remove it, thats no good.
So just put the custom script once you have used it as much as you like.

Remember, RemovePoint for points, RemoveRegion for regions.
It might even be a rect your using, Instead of RemoveRegion try RemoveRect
Collapse JASS:
call RemoveRect(udg_Temp_Region)

And ofcourse, you do have to have the variables.
07-31-2006, 08:03 PM#9
refl3ction
Collapse JASS:
call RemoveLocation(udg_Temp_Location2)

thats where the problem is not the

Collapse JASS:
call RemoveRegion(udg_Temp_Region)
08-01-2006, 01:53 AM#10
refl3ction
well i got the trigger to work, but it wont work the way i want to, it kindof randomates it, it will either cast FoK, blink, cast Fok then blink, or blink then cast FoK... all of these are not what i want

anyone got ne ideas?

Trigger:
Actions
Set Temp_Location = (Position of (Triggering unit))
Set Temp_Region = (Region centered at Temp_Location with size (500.00, 500.00))
Set Temp_Location2 = (Random point in Temp_Region)
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Wait 0.50 game-time seconds
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Wait 0.50 game-time seconds
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Night Elf Warden - Blink Temp_Location2
Unit - Order (Triggering unit) to Night Elf Warden - Fan Of Knives
Custom script: call RemoveLocation(udg_Temp_Location)
Custom script: call RemoveRect(udg_Temp_Region)
Custom script: call RemoveLocation(udg_Temp_Location2)
08-01-2006, 01:59 AM#11
Wyvernoid
Well you could add something like "wait xx sec" between every "Blink" and "Fan of Knives", 'guess the problem was because the warden's too tired of your orders That's a joke, 'think the real reason is that the computer parsed the triggers too fast that FOK sometimes cut in line before blink, so blink is queued after FOK.
08-01-2006, 02:37 AM#12
refl3ction
ok :) so how much time do you think i should put in between? and also how do i set the ultimates cooldown back to so that its just like its just been used.?
08-01-2006, 03:17 AM#13
Wyvernoid
Well what about 0.05 sec., 'think the computer should not be this fast.
About the cooldown... why not set the cooldown to 0 in Object Editor, that's more convenient.
08-01-2006, 03:43 AM#14
refl3ction
hmmm if i set the cooldown to 0 that makes the ultimate usable whenever, making it imbalanced

also
Trigger:
Set Temp_Location2 = (Random point in Temp_Region)

does that create only one random point?, cuz i think thats what happens... the unit only blinks to one point
08-01-2006, 03:58 AM#15
Wyvernoid
'Think you misunderstood me, I meant to set the cool down of DUMMY FOK and DUMMY Blink to 0, not the ultimate ;-)
My opinion here------

Trigger:
Actions
Set Temp_Location = (Position of (Triggering unit))
Set Temp_Region = (Region centered at Temp_Location with size (500.00, 500.00))
Set Temp_Location2 = (Random point in Temp_Region)
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Dummy Blink Temp_Location2
Wait 0.05 game-time seconds
Unit - Order (Triggering unit) to Dummy Fan Of Knives
Wait 0.50 game-time seconds
Set Temp_Location2 = (Random point in Temp_Region)
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Dummy Blink Temp_Location2
Wait 0.05 game-time seconds
Unit - Order (Triggering unit) to Dummy Fan Of Knives
Wait 0.50 game-time seconds
Set Temp_Location2 = (Random point in Temp_Region)
Unit - Reset ability cooldowns for (Triggering unit)
Unit - Order (Triggering unit) to Dummy Blink Temp_Location2
Wait 0.05 game-time seconds
Unit - Order (Triggering unit) to Dummy Fan Of Knives
Custom script: call RemoveLocation(udg_Temp_Location)
Custom script: call RemoveRect(udg_Temp_Region)
Custom script: call RemoveLocation(udg_Temp_Location2)