I need to either make a script generate a ability or edit a command card after initialization. Currently running into a bug that prevents me from doing it via data editor which results crash on map load.
So is this possible to do?
Are you sure that having all the abilities on the command card pre-start with some requirements or validators doesn't work for what you wanna accomplish?
I do not think it is possible to change the actual command card in game. As fr0d0b0ls0n has stated validators and having all abilities on the card at the start can work if you can fit within these constraints. This was not possible for the map I was working on however due to the 32 ability limit (I have 77 abilities for 10 command card slots). How I got around it was to give each command card slot 2 dummy abilities (an instant and a a targeted) then alter the catalog associated with the dummy abilities and their associated buttons. Then, I triggered each dummy ability so when they are fired the appropriate effect is created. The only thing I was not able to easily change was the icon for each button, so I made a custom UI dialog as an overlay on the command card that displays the icons. The downside with using this approach is that the command card changes are applied to all units using the dummy abilities owned by the same player (because the catalog is altered). Oh, and the icon overlay stays visible when using a targeting ability.
Long story short - No it's not possible. But you can make it look like it is (with about a couple hundred lines of script).
@xrit: Go
Are you sure that having all the abilities on the command card pre-start with some requirements or validators doesn't work for what you wanna accomplish?
yes i am positive it will not work. I keep on getting a crashes when i have the ability associated to the unit, btw error failed to read memory is what i get. I have also remade the units 3 times, and each time it is a different unit few units that cause the issue. that is why i am looking for a script to add it after the game has started.
I do not think it is possible to change the actual command card in game.As fr0d0b0ls0n has stated validators and having all abilities on the card at the start can work if you can fit within these constraints.This was not possible for the map I was working on however due to the 32 ability limit (I have 77 abilities for 10 command card slots).How I got around it was to give each command card slot 2 dummy abilities (an instant and a a targeted) then alter the catalog associated with the dummy abilities and their associated buttons.Then, I triggered each dummy ability so when they are fired the appropriate effect is created.The only thing I was not able to easily change was the icon for each button, so I made a custom UI dialog as an overlay on the command card that displays the icons.The downside with using this approach is that the command card changes are applied to all units using the dummy abilities owned by the same player (because the catalog is altered).Oh, and the icon overlay stays visible when using a targeting ability.
Long story short - No it's not possible.But you can make it look like it is (with about a couple hundred lines of script).
so let me get this straight the G.E. has a 32 ability limit? because i am pushing around 135 as is, would this cause the error on load?
Couple hundred lines of script isn't a issue, learning G.E. api is going to be a pain however.
I almost positive the hard limit is that each unit can have up to 32 abilities assigned to it in the data editor. Again, these abilities cannot be changed at run time, but they can be enabled/disabled or have their catalog data altered to give the illusion they are being changed. I don't know what the upper end of how many units/abilities the game can have is, but I would assume it is more than 135 / 81. Also, you may just have some invalid data in some of your abilities which are causing the map to crash (you can do this by editing raw values). The reason your map might be crashing is that abilities are not loaded until a unit assigned with them is loaded. I would try testing the abilities in groups to see if the problem is related to some specific abilities.
Yes, 32 abilities per unit at max (at least it's 32 buttons).
If you try to add more you get an error saying 32 is the maximum.
It does not crash the map (at least it didn't do for me), so the cause is probably within some abilities, not just because of the sheer amount.
Warcraft easily supported hundreds of custom abilities. If GE gives up at a mere 135 I'm really going to kill some Blizzard employees.
Ok this is killing me i just remade the units and nothing changed expect for the units crashing it. I know i am kind of ask a lot and showing a little but is any thing out of the norm in those picture from what you can tell.
First off, try to add just one abilmorph ability to a unit and see if it crashes. If it does, you probably have your abilimorph set up wrong. If it doesn't, keep adding them until you find the ones that do, and remove them.
If your abilmorph is set up wrong, that probably means they all are. I would try to find a tutorial showing the proper configuration of said ability and remake them all.
You used to be able to add/remove abilities via triggers in wc3 didn't you? I'm kinda surprised that you can't in the new editor.
Hopefully they add it in and the ability to setup command cards via triggers. Not a big deal for what I'm doing, I ended up placing them on the CC first then use upgrades & requirements to enable/disable them.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I need to either make a script generate a ability or edit a command card after initialization. Currently running into a bug that prevents me from doing it via data editor which results crash on map load. So is this possible to do?
@xrit: Go
Are you sure that having all the abilities on the command card pre-start with some requirements or validators doesn't work for what you wanna accomplish?
@xrit:
I do not think it is possible to change the actual command card in game. As fr0d0b0ls0n has stated validators and having all abilities on the card at the start can work if you can fit within these constraints. This was not possible for the map I was working on however due to the 32 ability limit (I have 77 abilities for 10 command card slots). How I got around it was to give each command card slot 2 dummy abilities (an instant and a a targeted) then alter the catalog associated with the dummy abilities and their associated buttons. Then, I triggered each dummy ability so when they are fired the appropriate effect is created. The only thing I was not able to easily change was the icon for each button, so I made a custom UI dialog as an overlay on the command card that displays the icons. The downside with using this approach is that the command card changes are applied to all units using the dummy abilities owned by the same player (because the catalog is altered). Oh, and the icon overlay stays visible when using a targeting ability.
Long story short - No it's not possible. But you can make it look like it is (with about a couple hundred lines of script).
yes i am positive it will not work. I keep on getting a crashes when i have the ability associated to the unit, btw error failed to read memory is what i get. I have also remade the units 3 times, and each time it is a different unit few units that cause the issue. that is why i am looking for a script to add it after the game has started.
so let me get this straight the G.E. has a 32 ability limit? because i am pushing around 135 as is, would this cause the error on load?
Couple hundred lines of script isn't a issue, learning G.E. api is going to be a pain however.
@xrit: Go I belive its 32 abilities per unit is the limit which one guy said he found a very odd work around for
Try not doing what your doing with the abilities. Does your map still crash?
And from what i have read on mapster is that, you are not allowed to change the command cards at run time.
Per unit, are you sure? because i have 135 ability's split between 81 units.
"Try not doing what your doing with the abilities. Does your map still crash? "
I talked about how a few units abilities caused the crash and of course when abilities are not associated with they units do not crash.
@xrit:
I almost positive the hard limit is that each unit can have up to 32 abilities assigned to it in the data editor. Again, these abilities cannot be changed at run time, but they can be enabled/disabled or have their catalog data altered to give the illusion they are being changed. I don't know what the upper end of how many units/abilities the game can have is, but I would assume it is more than 135 / 81. Also, you may just have some invalid data in some of your abilities which are causing the map to crash (you can do this by editing raw values). The reason your map might be crashing is that abilities are not loaded until a unit assigned with them is loaded. I would try testing the abilities in groups to see if the problem is related to some specific abilities.
Yes, 32 abilities per unit at max (at least it's 32 buttons).
If you try to add more you get an error saying 32 is the maximum.
It does not crash the map (at least it didn't do for me), so the cause is probably within some abilities, not just because of the sheer amount.
Warcraft easily supported hundreds of custom abilities. If GE gives up at a mere 135 I'm really going to kill some Blizzard employees.
Ok this is killing me i just remade the units and nothing changed expect for the units crashing it. I know i am kind of ask a lot and showing a little but is any thing out of the norm in those picture from what you can tell.
This picture shows how i have the building set up http://img340.imageshack.us/img340/8743/img1a.png
And this one shows how i use abilmoph (the problem abilities) http://img714.imageshack.us/img714/1296/img2w.png
All of the abilities are made the exact same, every time it crashes i get a memory read error.
@xrit:
First off, try to add just one abilmorph ability to a unit and see if it crashes. If it does, you probably have your abilimorph set up wrong. If it doesn't, keep adding them until you find the ones that do, and remove them.
If your abilmorph is set up wrong, that probably means they all are. I would try to find a tutorial showing the proper configuration of said ability and remake them all.
Ok i think i am running into the 32 ability issue after further tests it doesn't make any sense to me why the upgrade chain is registering like this.
Got a work around going thank you all for the help.
You used to be able to add/remove abilities via triggers in wc3 didn't you? I'm kinda surprised that you can't in the new editor.
Hopefully they add it in and the ability to setup command cards via triggers. Not a big deal for what I'm doing, I ended up placing them on the CC first then use upgrades & requirements to enable/disable them.