• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Need Info] Allowing a unit to attack while preparing to cast an ability

Status
Not open for further replies.
Level 3
Joined
Jun 20, 2009
Messages
42
Hi, I'm working on modding the Battlecruiser to to have a brief charge time when casting Tactical Jump, and for it to be able to attack at any enemies in range while it is doing that. I modified the "Prepare Time" field just fine, but I have no idea how to allow a unit to attack and prepare a spell at the same time.

...Is it even possible?

And if it is, can you be selective about which abilities a unit can or cannot attack while preparing?
 
Level 3
Joined
Jun 20, 2009
Messages
42
Update: it seems that the Battlecruiser at least casts spells while attacking by default, as casting Yamato Gun applies a special "disable Battlecruiser weapons" behavior so it can't fight while charging.
 
@deepstrasz sure

The battle cruiser has weapons, 2 of them, one for air units and one for ground units, it has flags in the weapon its self under ummm settings (basic stats)[i think] and one of them is called "allowed movement" which can be set to one of 3 things moving slowing and none - the battle cruisers weapons can attack when slowing down hence whats called "deceleration" in the battle cruisers units movement stats but thats only co-incidence to the weapons flag setting which if i remember correctly is set to slowing. Meaning it cannot attack while moving but doesnt need to stop moving to attack.

So you need to make a weapons setting change, that or alter the behavior to make weapon changes during the tactical jump channel/initial effects, to make it so its weapons can work while casting jump. Which can be done. Id need to go look at it to better understand why it cant attack during jump - if it has a behavior to disable weapons similar to yamato cannon then youd also need to disable that.

Oh right also because tactical jump forces the battle cruiser to face a direction of the jump and so does the right click attack targeting - youl also need to change the weapons allowed attack angle to 360 so it doesnt have to turn to face targets you direct it to attack - you can make all these changes inside the behavior of tactical jump its self, so it behaves as a normal battlecruiser on normal days but has significant changes during the actual jump behaviour.

Oh right also dont forget to keep the behavior setting that prevents the battle cruiser from being allowed to turn, which is a unit setting, under flags called "turnable".
 
Last edited:
Status
Not open for further replies.
Top