[Solved] Spellbook and multiple buildings

Status
Not open for further replies.
Level 5
Joined
Jun 12, 2018
Messages
149
Hi & long live to the Hive!:infl_thumbs_up:

I've ran into a weird problem when I was trying to make an alternate building menu.
I created a custom spellbook ability and some custom building abilities based on the "Build X Tiny" (one different per building to get different order IDs:fp::xxd:).

Problem is that even if I can see my different building abilities with their own descriptions the built unit will still be the same:pird:

I'm posting some screenshots of my custom spellbook and custom build abilities to clear things up.
Thanks for helping :witch_doc_sad:

anmrcK.png


t5u4J3.png
 
Level 5
Joined
Jun 12, 2018
Messages
149
Changing order ID of same spell will not work unless it's "Channel" spell. Maybe there's a workaround but I don't think it would be perfectly possible until Blizz makes Order IDs not overlapping :]

You might want to take a look at this: Advanced Building

Thanks for the reply, I didn't know about the "Channel" thing but I've read that you could have two different order ID for two spellbooks...
I've also already read the topic you've mentioned and one guy was facing the same problem :(

If I don't find a solution with the spellbook I'll go for a dummy builder that replace the existing one.
 
Level 5
Joined
Jun 12, 2018
Messages
149
Spellbook is the only other spell that can have its orderid changed. But the spells inside the spellbook cannot be changed, and they can still cause collisions if multiple spells inside have the same base orderid.

Good to know ! What would you suggest me to achieve my goal ? Make a dummy alternate builder ?
Although my spells have different order IDs coz I'm using one "tiny build" ability (there are about 10 in native) per custom building...
 
Last edited:
Level 13
Joined
Mar 21, 2014
Messages
893
Good to know ! What would you suggest me to achieve my goal ? Make a dummy alternate builder ?
You could use "Bear Form" to transform to another worker with different buildings. I'm not sure it work :p so give it a try
Although my spells have different order IDs coz I'm using one "tiny build" ability (there are about 10 in native) per custom building...
AFAIK, item abilities don't have OrderIDs. And different spells that do same thing doesn't still mean that they have different OrderIDs. For example, let's take a look at Warstomp. This spell has 4 versions(TC's, Centaur's, Hydra's and Sea Giant's). If you give these spells different effects and add these to a unit and order him to cast 1 of these spells, the result would be 4 spells being cast at once. :]
 
Level 24
Joined
Oct 18, 2008
Messages
942
You could use "Bear Form" to transform to another worker with different buildings. I'm not sure it work :p so give it a try

I have a setup like this, which I think is slightly faster than transformations

  • worker switch
    • Events
      • Unit - A unit Begins an upgrade
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Unit-type of (Triggering unit)) Equal to Builder
          • (Unit-type of (Triggering unit)) Equal to Military Builder
    • Actions
      • Unit - Set (Triggering unit) upgrade progress to 99%
check "is a building" on your unit to reveal the "upgrades to" field. it will still work after you hide it again later.
 
Level 41
Joined
Feb 27, 2007
Messages
5,237
Good to know ! What would you suggest me to achieve my goal ? Make a dummy alternate builder ?
Although my spells have different order IDs coz I'm using one "tiny build" ability (there are about 10 in native) per custom building...
There really isn't a solution. If you want the build ability to show the preview of the built structure and take ground pathing into account you can only have 1 build ability 'available' at a time. You can use multiple different dummy abilities that target points and then dummy-cast the correct 'build tiny X' ability if you want but it won't show the hover preview. This method can also place buildings with pathing maps that overlap, so you could use some logic on the targeted location to find the closest truly buildable location if you wanted.

The only 'solution' is to put each "build tiny X" ability inside its own independent spellbook. Then the user clicks the spellbook for the structure they want to build and has to also click on the ability within that spellbook (could have a standardized hotkey though).
 
Status
Not open for further replies.
Top