• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Remove casting time?

Status
Not open for further replies.
Level 5
Joined
Nov 27, 2007
Messages
85
Here's the problem. There is an ability which needs to be targeted when used. The target is usually ground (like in attack-move).

The problem is, if u use this ability and make "move with right mouse button" very fast after it (and that what happens in my map all the time) - it gets canceled.

I guess casting time is somehow involved. How do i remove it?
In object editor i already set parameters "ability preparing time" and "On-hero casting time" to 0 and this doesn't help. (Sorry i translated these 2 terms into English from my lang but i hope they are clear).
 
Which skill are you using?
Normally you just have to set Stats - Casting Time to 0 and you're set.
If you want it more extreme you can even set the
Art - Animation - Cast Backswing and Art - Animation - Cast Point of the caster to 0.
This will affect every skill the unit uses. What it does is, it skips the casting animation of the unit when using a ability.
 
Level 5
Joined
Nov 27, 2007
Messages
85
Which skill are you using?
That's a skill to shoot the ball. It's done instantly (not channeling). So if you press the shooting hotkey and move right after that, the shooting doesn't happen.

If you want it more extreme you can even set the
Art - Animation - Cast Backswing and Art - Animation - Cast Point of the caster to 0.
Sorry, but where do i find these parameters? In Art - Animations i only have Names field.
 
That's a skill to shoot the ball. It's done instantly (not channeling). So if you press the shooting hotkey and move right after that, the shooting doesn't happen.
I meant the skill you have ur custom one based of.

Sorry, but where do i find these parameters? In Art - Animations i only have Names field.
It's not in the ability editor. With "of the caster" I meant the unit. So it's in the unit editor.
 
Level 5
Joined
Nov 27, 2007
Messages
85
I meant the skill you have ur custom one based of.
No idea, i'm fixing the bugs in this map. Does this matter?
I checked some field in Text and it says "ward" there. Probably this ability

It's not in the ability editor. With "of the caster" I meant the unit. So it's in the unit editor.
Yeah, i checked those and they were already set to 0. I tried setting to 0.001 and it didnt help :(

Any other ways to solve this?
Just to let you know the map seems pretty complicated as it's football simulator and has about 140 triggers inside.
 
Level 3
Joined
Jul 3, 2009
Messages
31
maybe try using :

A unit Begins casting an ability

in the event part of the triggers instead of "Finishes casting an ability". Would that be okay?
 
Level 5
Joined
Nov 27, 2007
Messages
85
It's not GUI, here's the code.

Code:
function Trig_Shoot_or_Sliding_Conditions takes nothing returns boolean
    if ( not ( GetUnitTypeId(GetSummonedUnit()) == 'osp1' ) ) then
        call DisplayTextToForce(GetPlayersAll(), "FALSE !")
        // this check returns false in case i change the event to FINISH or ENDCAST
        // i guess there's a problem with GetSummonedUnit in this case
        return false
    endif
    if ( not ( udg_HeroSlidingWait[GetConvertedPlayerId(GetOwningPlayer(GetSummonedUnit()))] == 0 ) ) then
        call DisplayTextToForce(GetPlayersAll(), "FALSE 2 !")
        return false
    endif
    return true
endfunction

// several small functions used in action function, no need to show them here
// U have to kknow they use GetSummonedUnit and GetSUmmoningUnit


function Trig_Shoot_or_Sliding_Actions takes nothing returns nothing
    // BIG function with actions, no need to show them here
    // Probably you should know that GetSUmmoned Unit is used in this function too
endfunction

//====================================================
function InitTrig_Shoot_or_Sliding takes nothing returns nothing
    set gg_trg_Shoot_or_Sliding = CreateTrigger(  )
    call TriggerRegisterAnyUnitEventBJ( gg_trg_Shoot_or_Sliding, EVENT_PLAYER_UNIT_SUMMON ) // SUMMON, NOT EFFECT OR CAST
    call TriggerAddCondition( gg_trg_Shoot_or_Sliding, Condition( function Trig_Shoot_or_Sliding_Conditions ) )
    call TriggerAddAction( gg_trg_Shoot_or_Sliding, function Trig_Shoot_or_Sliding_Actions )
endfunction

This is the trigger for that ability (shooting). It appears the original mapmaker used summon as an event. It's not "CAST" or "EFFECT". If i change this to ENDCAST or FINISH - then condition fuction returns false as it is unable to get summoned unit i believe. I think there's a viable solution here (probably involving creating an additional trigger) but i can not see it. What should i do?
 
Last edited:
Level 6
Joined
Aug 26, 2009
Messages
192
ok we found a solution for that "bug" (we call it x-bug)
we now changed it to the event "EVENT_PLAYER_UNIT_SPELL_CAST"
and changed the trigger itself so that we dont need the summoned unit anymore
till now it seems fixed but i cant say if it is really fixed
for that we need more testing!
 
Level 6
Joined
Aug 26, 2009
Messages
192
Summoned unit is used when you summon a unit (like from Summon Water Elemental) not when you create it via trigger(s).

there wasnt any problem in the spekll itself
it summoned a unit
we just have the problem that if u click to fast u interupt the casting right befor the trigger gets started

well we made this happen less often but it's not possible to fix it completly

edit:
Which skill are you using?
Normally you just have to set Stats - Casting Time to 0 and you're set.
If you want it more extreme you can even set the
Art - Animation - Cast Backswing and Art - Animation - Cast Point of the caster to 0.
This will affect every skill the unit uses. What it does is, it skips the casting animation of the unit when using a ability.
that's already done
 
Status
Not open for further replies.
Top