Hi, I have been looking for a tutorial but can't seem to find a way to make a custom ability , here is what i would need as examples:
1. a simple damage ability (like snipe)
2.a splash damage ability (ex: a grenade)
3: an area boost that can be toogled on/off (ex: a time slow in an area around player)
I know that some ability like these already exist but i cant seem to find what to change to make mine work as I want it to (cause I'm a noob at the editor)
so can you explain to me what to change or how to create an ability from scratch.
Two questions:
Do you want this ability to have multiple levels?
Do this ability level up based on a requirement, for instance hero level?
Edit:
Sniper ability
Sniper ability, only one level, with effects,models, actors. Contains:
One button, one ability, one unit, two actors and two effects, in steps 1-11 below.
Note: no steps (apart from Step 8 ) nor any sentences can be skipped. Read one line/sentence and do what it tells you to do, within 30-60 minutes, you have the ability completed.
PS: Whenever you create or change the name of any object in data editor (unit, ability ,effect, actor, etc.) click "Suggest" so you give the object a decent unique ID, mentioning it here, in case I've forgotten it somewhere.
Reference:
"Multiple Levels": Some fields that are being modified below, is for level 1 of the ability. If you add more values to some fields, each represent another level of the ability.
Step 1: Button-Tab
Right click and add a new button, give it a name, I named it "Snipe", click OK.
Skip adding tool-tips, icons etc. for now.
Step 2: Ability-Tab
Right click and add a new ability, give it a name, I named it "Snipe", ability type Effect - Target, click OK.
Select "Snipe"-ability, fields:
"Ability: Commands" - double click the value of it, not the "Ability Commands"-text, so you get a dialog up, select "Execute button", and set the Default Button to "Snipe", click OK [Optional, not really required for it to work]
"Ability: Progress" - double click the value of it, find the "Prepare" index and set its value to "Snipe"-button.
"Ability: Target Filters" - double click the value of it, add new filter, select "enemy", click OK. Then set things to allow or deny. I've set Excluded on air and heroic and structure (not allowing cast on heroes or air or structures, but all other enemies) [Reference "Multiple Levels"]
"Stats: Prepare Time" - double click the value of it, this is the casting time of ability, I've set it to 0.25 (seconds). [Reference "Multiple Levels"]
"Stats: Range" - double click the value of it, cast range of the ability, I've set it to 5.0 [Reference "Multiple Levels"]
Step 3: Unit-Tab
Search for "photon cannon weapon" [this will be our so called "Ammo Unit", is required]
Right click the Photon Cannon Weapon and chose Duplicate, select Model, Actor and Mover, click OK.
Go to the "object explorer", if it is not shown, or unsure what it is, go to View > "Show Object explorer" and see what changes, the view that changes is the object explorer.
Object Explorer:
Double click Movers - Photon Cannon Weapon Copy, change the name to "Snipe Movement" and click Suggest, and click OK.
Double click Models - Photon cannon weapon copy, change the name to "Snipe Weapon Model", click suggest, click OK.
Double click Actors - Photon cannon attack missile copy, change the name to "Snipe Attack Missile", suggest, click OK.
Double click "Weapon - Photon cannon weapon copy", the first Node, rename it to "Snipe Ammo", remove the prefix "weapon", suggest and click OK.
Step 4: Actor-Tab:
Search after "Photon Cannon Attack" right click it (not the missile, but the Action-Attack, we already got the missile duplicated).
Choose duplicate and select Model - Photon Cannon Attack Impact and Sounds - PhotonCannon_AttackLaunch, click OK.
Object Explorer:
Double click Photon Cannont Attack Impact Copy, change name to "Snipe Attack Impact", click Suggest and OK.
Double click PhotonCannon_attackLaunch Copy, change the name to "SnipeLaunch", click suggest and OK.
Doucle click "Photon Cannon Attack Copy", the first node, rename it to "Snipe Attack", suggest and OK.
Select "Snipe Attack", fields:
"Combat : Impact Map", double click the value of it. Select the index "none" and remove the Impact Sound by clicking the "-" sign next to it. Removing impact sound, since we did not duplicate it and don't want it.
Step 5: Effect-Tab
Right click and add a new effect, give it a name, I named it "Snipe Damage", click suggest, choose type "Damage", click OK.
Right click and add another effect, give it a name, I named it "Snipe Missile", click suggest, choose type "Launch Missile", click OK.
Select Snipe Damage, fields:
"Combat - Amount", this is the damage done by our ability, I set it to 100. Be aware that for each level of an ability, a new effect Snipe Damage is required.
"Effect - Validators" and remove them all, if there are any.
Select Snipe Missile, fields:
"Effect Ammo Unit", and chose our "Snipe Ammo", click OK.
"Effect - Impact effect", set it to be our "Snipe Damage", which is the impact effect.
"Effect - Validators" and remove them all, if there are any.
Step 6: Actors-Tab
We have created our effects, lets set our actors' token:
Select "Snipe Attack", and at the bottom of the "Fields" in your window, there shall be a few "Tokens".
Token:
Impact Effect - To be our "Snipe Damage"
Launch Effect - To be our "Snipe Missile"
Select the "Snipe Attack Missile"-actor
Token:
Unit Name - Set this to be our ammo unit, "Snipe Ammo".
"Effect: Effect", if an effect is there, remove it, then add our "Snipe Missile", click OK.
Step 8: (OPTIONAL)
Adding mana cost or cooldown Ability-Tab
Select Snipe-ability, fields
"Cost: Cost", edit this field to control mana/energy and cooldown. Image shows 10 seconds cooldown and 3 seconds cooldown from "start", whenever the unit was created. So the ability starts in a cooldown...[Reference "Multiple Levels"]. Do note that if the image was able to be scrolled down, the mana/energy cost is also shown, which is 5. Optional: You can set the cost of the ability to be life/shield instead or both!
Do note, for the cooldown to work, you need to select your ability. Sometimes the link is blank by default, chose your ability.
Step 9 Button-Tab:
Select the Snipe button we created, fields:
UI - Icon, select any icon you want as the button-image.
UI - Tool-tip, insert a TextKey, I am using things on the format: "Text\Ability\<ability name>", so I am using Text\Ability\Snipe as the key, and text:
"Sniper deals damage from a long distance, dealing " and there I stop, then I click "Choose field" just below the tooltip I've wrote, and I remember that the effect "Snipe Damage" was dealing the damage, so I chose effect and chose my snipe damage ability, then click OK, then click "Insert" and suddenly this text appears:
<d ref="Effect,SnipeDamage2,Amount"/>, which is a reference to the 100 damage amount in our ability. If we change 100 damage to 105, tool-tip is auto-updated.
UI - Hotkey :Here you can also set the hotkey
Step 10: Unit Tab
Search for SCV
Select SCV, fields:
"Stats: Energy Maximum" - 25
"Stats: Energy Regeneration rate: " - 2
"Ability: Abilities: " - removed repair, build, etc, except move, attack and stop, then add our own ability "Snipe", click OK.
"Ability: Command Card" - removed all useless buttons (repair, build, etc. but kept move and attack, etc...), adding a new button in any of the open button-spaces/slots: Chose "Snipe"-button
The type is "Ability Command", the ability is "Snipe", and the ability command again is "Snipe".
Again select the SCV-unit and click CTRL+P, takes you to terrain editor. Start placing 10-20 SCV's. While still in the terrain editor, select half of the SCVs, then click "1" on your keyboard (this will make units belong to player 1), then select the other half of the SCV's and click "2". Now you have some enemies to cast the ability on.
Step 11:
Triggers, remove the melee triggers, if this was created in a new map.
Final notes:
Attached a map following the steps above.
To change the model of the ability, or impact, go to "models"-tab and search for "Snipe". There you have the two models.
There are other ways to Rome. I could have duplicated the effects too, but wanted the user to create the effects from scratch.
It might look like a tutorial at first glance, or the second, but in fact, it is a response to the post above. :)
Get your ability to use a Switch effect and Unit Compare Veterancy Levels validators. Instead of all effects neing in each level of the ability they are all used by the switch that the ability uses. Based on level the switch then decides what branch of the tree to use.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
It is an effect type. Look at Changeling - Disguise (Switch Based On Unit Target Type) for an ingame example. The wiki also explains what each field does.
I just looked at the changeling but i don't get how the effect works and where the switch actually is, sorry for being such a noob but i just can't get how to make it.
Ok, I will explain exactly how the changeling works. Although the data navigator function of the editor (ctrl + space) should make it pretty obvious.
The changeling unit has a behaviour on it called Changeling Disguise that uses a periodic Search Area effect. This area effect removes the disguise behaviour and uses a Switch effect when it finds a target. The switch uses validators that use Unit Compare Field type validators to check what race the target units of the search are (and the upgrades they have using other validators). Based on what validators return true the switch uses the corresponding Set effect that uses an Issue Order effect to order the changeling to use a Morph ability to change into a marine/zealot/zergling mimic and a Modify Unit effect to give it the mimic flag.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
So, I've took myself the time to continue from my previous post, to answer your further questions, how to make the ability not castable before, say, level 3 of the unit.
Note 1: for all names, objects, that will be created/duplicated, please remember to click suggest, even though I forget to mention it.
Note 2: whenever I say "CTRL + Q" below, it is a hotkey for the "plus sign [green plus sign]" within the current dialog, or you could also right click and click "add new..." whenever I say "CTRl + Q".
Note 3: Within 20-60 minutes, following these steps, you should have it "all done".
Step 1:
Download the map from the PREVIOUS post by me, further up in this thread, so you can proceed following the steps below, then open the map in the editor.
Step 2:
Enter Data Editor, open the Behavior tab and right click the tab-button itself, select "Close all other tabs".
Also set the "Data source:" to the map "tutorialAbility", so we are not bothered/distracted by other default objects during the process.
Step 3:
Behavior Tab:
Right click and add new Behavior.
Name: "SCV Experience"
Sugesst
Behavior Type: "Veterancy", click OK.
Select last created behavior, fields:
Behavior: Share Filters +, edit its values
Select the filter "Kills", and right click on "Air - Allowed", and set its state to "Excluded".
Now air units with this veterancy level, do not share our experience if we kill a unit, all other heroes will share though.
- Click OK
Behavior: Veterancy Levels, edit its values
CTRL + Q, to create a new level. First level is "level 0", which we will set its minimum experience (the required experience) to be 0, so our SCVs all start at level 1.
CTRL + C, CTRL + V while the newly created level is selected.
Set "Level 1"'s minimum experience to 15
Select the "Level 1" row, which has set its exp. to 15, click CTRL + C, CTRl + V, then repeat CTRL + V 4-5 more times.
Ive pasted so the last row is at "Level 7".
Note: 15 experience is required for each level. So from level 1 to 3, it requires 15*2 = 30 experience.
Click OK
Step 4:
Actors Tab
Right click, add new Acotr
Name "SCV Experience Level Up"
Suggest
Actor Type "Model"
Parent "Buff One Shot"
Click OK
Select newly created actor, fields:
Art: Model, chose a model for the effect you want displayed on the unit, when it levels up. Ive chosen: Hero Nuke Exlpode
Art: Scale: Ive set it to 1.5
Event: Events+, edit its values
Within the Events+-dialog , right click at the left panel, below "Actor Orphan", chose "Add new event"
Change the newly added event msg type from "Action Damage", to "Behavior Level"
Set the new events "Source Name" to be our "SCV Experience"
Sub Name: leave alone.
Again, look to left panel, below "behaviorLevel.SCVExperience", there is another field, select it:
Set msg type to "Create"
Click OK
Step 5:
Units Tab
Select our SCV, fields:
Behavior: Behaviors +, edits its field and CTRL + Q, find our "SCV Experience"-behavior. Now our SCV can level up.
Combat Experience Amount: 15, set it to 15.
Stats Life Maximum: Set to 1
Stats Life Starting AMount: Set to 1
Step 6:
Effects Tab
Right click, add new effect:
Name "SCV Snipe Switch"
Type "Switch"
Click OK
Step 7:
Abilities-tab
Select Snipe-ability, fields:
Effect: Effect+, edit its value, replace "Snipe Missile" with our newly Switch Effect, click OK.
Step 8:
Validators-Tab
Right click, add new validator:
Name "SCV Snipe"
Suggest
Validation type "Unit Compare Veterancy Levels"
Click OK
Select our newly created validator, fields:
Validator: Behavior, edit its value, set it to our "SCV Experience".
validator: Compare, set it to "Greater than or equal to"
Validator: Unit+, edit its value, change value "Target" to "Caster", click OK.
Validator: Value, the required level of our SCV, before he is allwoed to cast our Snipe ability, ive set it to 4, so when our SCV is level 3, it has the fourth level of our behavior [level 1 is actually no experience, so when our scv is level 1, it is actually the second level of the behavior.].
Step 9:
Effect Tab
Select Switch-effect, fields:
Effect: Cases+ [important, Cases, not the effect field] edit its value, set it to "Snipe Missile".
Select another effect, Snipe Missile, fields:
Effect: Validators+, edits its value, CTRL + Q, search for "SCV Snipe" and select it, click OK.
Step 10: [Optional]
Abilities-tab
Select Snipe, fields
Cost, change time use to 4.
Step 11:
We are now done, SCV's are leveling up upon killing other units. Once they reach level 3, our spell is throwable.
Step 12 [OPTIONAL, NOT WITHIN THE MAP, NOT PART OF THE ANSWER]
If you want the ability to be hidden on the SCV's command card, untill it is level 3:
Requirements tab, add new requirement, name it something.
Fields, basic: requirements+, edit its values:
Add a new node under "Show", type "Greater than or equal to"
First find "Count Behavior Level", select the SCV Experience
Second right click and add new node, set this type to be Constant, and set it to level of SCV requires to view the ability.
Questioning why I chose "Sum" as a node, to then add the Count Behavior there? I always find myself wanting to add additional values for the requirement, say "2+LevelOfBehavior", so... :)
Abilities Tab, select Snipe ability, fields:
Ability Commands, edit it, select the "Execute" command and set the requirement to our newly created requirement. Click OK.
This would make switch and validator obsolete, not required, and you can change the "Ability Snipe's field: Effect to be Snipe Missile instead of the Switch Effect". Because a castable spell without passive behaviors at least, is not castable (not by a hotkey,nor the button) due to it is hidden on the units command card. Not tested with a passive spell that adds behaviors, then it might also require you to put a requirement under "Use" instead of only in the "show folder".
Do note, if you want the ability to be displayed, but not castable, you can swap the requirement, to be located under "Use", and leave "show" empty. :)
Final notes:
This might look like a tutorial at first glance, or even the second, but it is not. Its simply an answer to a question.
Attached the map
Last but not least, I did this with a switch effect and a validator, due to seeing that other people mentioned these two objects. But I would actually have added a requirement for the ability, counting the behavior level... Million ways to Rome.
ยจ
Hi, I have been looking for a tutorial but can't seem to find a way to make a custom ability , here is what i would need as examples:
1. a simple damage ability (like snipe)
2.a splash damage ability (ex: a grenade)
3: an area boost that can be toogled on/off (ex: a time slow in an area around player)
I know that some ability like these already exist but i cant seem to find what to change to make mine work as I want it to (cause I'm a noob at the editor) so can you explain to me what to change or how to create an ability from scratch.
Thanks for helping
Two questions:
Do you want this ability to have multiple levels?
Do this ability level up based on a requirement, for instance hero level?
Edit:
Sniper ability
Sniper ability, only one level, with effects,models, actors. Contains:
One button, one ability, one unit, two actors and two effects, in steps 1-11 below.
Note: no steps (apart from Step 8 ) nor any sentences can be skipped. Read one line/sentence and do what it tells you to do, within 30-60 minutes, you have the ability completed.
PS: Whenever you create or change the name of any object in data editor (unit, ability ,effect, actor, etc.) click "Suggest" so you give the object a decent unique ID, mentioning it here, in case I've forgotten it somewhere.
Reference:
"Multiple Levels": Some fields that are being modified below, is for level 1 of the ability. If you add more values to some fields, each represent another level of the ability.
Step 1:
Button-Tab
Step 2:
Ability-Tab
Step 3:
Unit-Tab
Step 4:
Actor-Tab:
Select "Snipe Attack", fields:
Step 5:
Effect-Tab
Select Snipe Damage, fields:
Select Snipe Missile, fields:
Step 6:
Actors-Tab
We have created our effects, lets set our actors' token:
Select "Snipe Attack", and at the bottom of the "Fields" in your window, there shall be a few "Tokens".
Token:
Select the "Snipe Attack Missile"-actor
Token:
Step 7:
Abilities-Tab
Select "Hero Snipe", fields:
Step 8: (OPTIONAL)
Adding mana cost or cooldown
Ability-Tab
Select Snipe-ability, fields
Step 9
Button-Tab:
Select the Snipe button we created, fields:
"Sniper deals damage from a long distance, dealing " and there I stop, then I click "Choose field" just below the tooltip I've wrote, and I remember that the effect "Snipe Damage" was dealing the damage, so I chose effect and chose my snipe damage ability, then click OK, then click "Insert" and suddenly this text appears:
<d ref="Effect,SnipeDamage2,Amount"/>, which is a reference to the 100 damage amount in our ability. If we change 100 damage to 105, tool-tip is auto-updated.
Step 10:
Unit Tab
Search for SCV
The type is "Ability Command", the ability is "Snipe", and the ability command again is "Snipe".
Step 11:
Triggers, remove the melee triggers, if this was created in a new map.
Final notes:
Test the map [Ctrl+F9].
@ManyTimes: Go
Nice answer.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
Thanks for this answer, it works perfectly fine, but I was wondering if you could help me make a level requirement for my ability.
@pokenoufl: Go
OneTwoSC had a tutorial explaining that. Just set the requirement to use some function of the Count Behavior type.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
Thanks for the tutorial but I would like my abilities to auto learn without having to make a learn ability button, is that possible ??
@pokenoufl: Go
yeah just dont use a learn ability :P.
And instead change the vailidators for the switch to compare behavior veterency levels.
sure, the only problem is I'm a noob so I have no idea how to do that.
Get your ability to use a Switch effect and Unit Compare Veterancy Levels validators. Instead of all effects neing in each level of the ability they are all used by the switch that the ability uses. Based on level the switch then decides what branch of the tree to use.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
Thanks for answering but i don't know what a switch is so i don't know how to make one.
It is an effect type. Look at Changeling - Disguise (Switch Based On Unit Target Type) for an ingame example. The wiki also explains what each field does.
http://www.sc2mapster.com/wiki/galaxy/data/effects/switch/
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
I just looked at the changeling but i don't get how the effect works and where the switch actually is, sorry for being such a noob but i just can't get how to make it.
Ok, I will explain exactly how the changeling works. Although the data navigator function of the editor (ctrl + space) should make it pretty obvious.
The changeling unit has a behaviour on it called Changeling Disguise that uses a periodic Search Area effect. This area effect removes the disguise behaviour and uses a Switch effect when it finds a target. The switch uses validators that use Unit Compare Field type validators to check what race the target units of the search are (and the upgrades they have using other validators). Based on what validators return true the switch uses the corresponding Set effect that uses an Issue Order effect to order the changeling to use a Morph ability to change into a marine/zealot/zergling mimic and a Modify Unit effect to give it the mimic flag.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
So, I've took myself the time to continue from my previous post, to answer your further questions, how to make the ability not castable before, say, level 3 of the unit.
Step 1:
Step 2:
Step 3: Behavior Tab:
Select last created behavior, fields:
Step 4: Actors Tab
Step 5: Units Tab
Step 6: Effects Tab
Step 7: Abilities-tab
Step 8: Validators-Tab
Step 9: Effect Tab
Step 10: [Optional] Abilities-tab
Step 11:
Step 12 [OPTIONAL, NOT WITHIN THE MAP, NOT PART OF THE ANSWER] If you want the ability to be hidden on the SCV's command card, untill it is level 3:
Final notes:
@ManyTimes: Go
thanks for this answer, ill try when i get enough time.