Data Editor - Data Editing for Dummies

Tutorial by Siretu

The single biggest problem that people have with the Starcraft 2 editor that causes the most people to just stop and give up, is the Data editor. It doesn't matter if you were creating stuff back in the Warcraft 3 days or if you're new to the scene. Chances are that if you've had any ambitions about making a Starcraft 2 map, the data editor has been there to intimidate you.

This happened to me as well. I was perfectly decent at the warcraft 3 object editor(warcraft's version of the data editor) but now I opened this data editor and I suddenly had no clue how to make a unit from scratch.

Today, I consider myself to be decent at the data editor as well but there's so much to learn.

This tutorial will just be a glimpse of the data editor as I try to explain how the fundamentals work. This means we wont do any actual work. I will try to follow this up with more detailed tutorials where we actually do something. Coming next is a buff tutorial.

Getting Started

Let's start out the tutorial with a picture of the data editor:
(Image)

There are several parts here that are interesting. I will break it down and explain each part separately.

Standard Buttons
First we have some standard buttons that are in most of the other modules as well (like the trigger and terrain module):
(Image)

From left to right, these buttons are:
New (Creates a new map),
Open (Opens an existing map),
Save (Saves the currently active map),

Undo (Removes the last change you made),
Redo (Redo's the change you just undid),

Cut (Removes the selected object(s) but saves it in the clipboard),
Copy (Save the selected object(s) in the clipboard),
Paste (Pastes the content in the clipboard)

Terrain (Opens up the terrain module)
Triggers (Opens up the trigger module)
Data (Opens up the data module)
Text (Opens up the Text module)
Import (Opens up the import module)

Overview (Opens up the overview manager)



These buttons are pretty basic so I wont say anything more about them.

Data Editor Buttons
Instead, let's go on to the other buttons to the right of the buttons we just looked at:
(Image)


View Raw Data - First we have the "View raw data" button. Basically, the data you see in the data editor looks prettier than it is. If you press the "View raw data" button, the editor will show you the data how the editor sees it.

Object Tree List - The next one shows the object lists as a tree instead of a big list. Try pressing on it to see how it works. I personally just use a big list and search for what I need, but it's nice to be able to have it sorted in a tree.

Display All Object Sources - The next button says "Display All Object Sources". Let's say we edit a marine and change the movement speed. This would cause the editor to create a new copy for us to edit. At the same time, the editor will keep the old one. Therefore, you can always go back to see how the unedited units look.

The most commonly used standard object sources are Liberty.SC2Mod and LibertyMulti.SC2Mod. When you edit something or add something new, the source for the object will show as the name of your map.

Show Object Explorer - We now come to the button called "Show object explorer". In my case, this button is already toggled. This button toggles the box in the bottom left which we will get to later. If you uncheck it, that box will get removed. I will explain more about the object explorer later on, for now let's go on to the next button.

Viewing Options - Table/Detail/XML - We now have 3 buttons called Table view, detail view and XML view. This changes the view of the list on the right. I personally prefer it at the table view. Table view is just a big list sorted after category.

The detail view looks prettier and has tabs that you can switch between but since there are a lot of fields, it's easier to find the one you're searching for if they're in a list and you don't have to switch between the tabs.

I think you should try out both and see what you prefer.

Now, did I skip the third one? No, I did not. The third one is XML view. This basically allows you to see the entire object as XML and edit it by coding basically. Advanced users may prefer this, and it is nice to have in some cases, but mostly you will not want to use it.

Show Default Values - Okay, on to the next button: "Show default values". These are the gray rows in the field list on the right side. The gray rows are default values which means they're the same as their parent's.

Show Advanced Values - The next one is "Show advanced values". This buttons toggles showing the advanced values in the field list on the right. If you feel that all the different fields in the list makes you confused, you might want to check this and the "Show default values" button as well. If you feel there's something you aren't finding, toggle these buttons to see if they were advanced/default.

Show Field Type Names "Show field type names" toggles showing/hiding the type of the field name. The fields are sorted into different categories and if you have this button clicked, the fields will show as "*Category*: *field*" instead of just "*field*".

Some fields have so much info that when you click them, you get up a mini menu with several fields that you can edit. If you want to spread this out into several fields, you can click the next button: "Combine Structure Values"

Syntax Color Coding (XML View Important) - This next button is not going to matter to you if you don't use the XML view that we previously talked about. This button gives the text different colors depending on the syntax. Very nice, I recommend it if you want to do XML-editing.

Commit XML Changes (XML View Important) The next button is grayed out for me since I haven't done any XML changes but when I do, I'll have to commit them using the next "Commit XML changes" button.

Test Map - The last button on this row is the "Test map" button. It minimizes your window and starts Starcraft 2. It automatically loads your map so you can play it.



Object Tabs
(Image)

As you can see, this part is quite small but you will often have more tabs than this open. I have around 10-15 depending on what I'm doing but that's because I always have my common ones up.

There are a ton of different objects in the data editor. You have units, effects, models, buttons and textures to name a few. Fortunately, you wont need to know how to use all of them to make a decent map. I will explain some of the more common ones when I'm done explaining all the parts of the overview picture in the beginning.

You use the different tabs to change between what object type you want to work with.

If you click the "+" sign you can add more tabs. You can also open this menu by right clicking on a tab.

(Image)

As you can see, you can close the selected tab (or all tabs except that one).

You can also open a new tab from either game data, actor data, art and sound data, terrain data or advanced data. Just the game data menu is filled with a lot of different object types.

Fortunately, I can tell you that you do VERY rarely need anything from terrain data and advanced data. You will need buttons and maybe models from art and sound data. You will need actors from actor data. In game data, you will need a lot though and I will explain those different objects and how they relate to each other in detail later on.

Object List
(Image)

This is the object list. Assuming you didn't toggle the "Display Object List as tree" button, it will look like a long list. It's the list of all the different objects of the type specified by your selected tab.

You can see the name (which is pretty self-explanatory), the source (which we talked about before), Object family (Just a way to sort things. Choose between None, Campaign, Melee and Storymode), Race (Also a way to sort your objects), Object Type (Also a way to sort things but it might matter on what fields your object has).

This is just for units though, other objects might have different columns but most of them have name and source.

Field List
(Image)

This is the field list. It contains all the information about the object you have selected. Double-click to modify a value.

Object Explorer
(Image)

This is the object explorer. In case you're not seeing it, make sure you have the "Show Object Explorer" button pressed that we talked about before.

Here's an example of the object explorer for a more simple object(The banshee's cloaking ability):
(Image)

The object explorer displays everything that is connected to that object. One difference between Warcraft 3's object editor and Starcraft 2's data editor is that in Starcraft 2, a lot of the things that were previously stuffed into the same object type is not split up and put in separate object types. One example is buttons. In Warcraft 3, you would specify the tooltip for an ability in the ability. Now you specify a button instead which is another object type. The button handles the title, tooltip, hotkey etc.

So, in the picture above we can see that the things that are connected to the Banshee's cloak ability are

• Two actors(Banshee_CloakOn (Unnamed) and Banshee_CloakOff (Unnamed))
• 1 behavior(Banshee - Cloak)
• 2 buttons(Cloak (Banshee) and Decloak)
• 1 requirement(Use cloaking field)
• 2 sounds(Banshee_CloakOn and Banshee_CloakOff)


These are the things that are needed for the banshee's cloak to work.

Now, you might be looking at the banshee's cloak to figure out how to do something similar but you have no idea how these things are connected. Fortunately for you, blizzard implemented a tool to help you see how they are connected. If you right click on one of the parts in the object explorer and press "Explain link", a new box will pop up in the bottom part and explain it to you.

Let's try this out with something simple. Press explain link on the behavior "Banshee - Cloak". It will say something like:
[Ability] Banshee - Cloaking Field <Behaviors> ->
[Behavior] Banshee - Cloak



This means the ability Banshee - Cloaking Field has a Behaviors field that links to the Behavior "Banshee - Cloak". So that's how the behavior is connected to the ability. Pretty simple. Let's try something a bit more advanced. Press explain link on one of the sounds. This time we get something like:
[Ability] Banshee - Cloaking Field <Behavior> ->
[Behavior] Banshee - Cloak <Events> - >
[Actor] Banshee_CloakOff (Unnamed) <Sound> ->
[Sound] Banshee_CloakOff



This is a little more than last time but if you read through it, you'll notice that the first two rows are the same as the ones we had before. This means the sound is somehow linked to the ability through the behavior.

One thing that might confuse you is the fact that actors go the other way around. I don't know why, but for now you just have to accept that they do. What do I mean? Well, it says <Events> after the behavior so you'd expect that the behavior has an event field that links to the actor. That's how it works with everything else. However, in this case, the event field is in the actor and the actor links to the behavior instead of the other way around.

So, the actor has an event field which links to the behavior. The actor also has a Sound field that links to the Sound object. See, that's how they're related. It all makes sense now!

If you still don't understand how things are connected and such, don't be discouraged, this is the hardest thing about it. When you start understanding how things are connected and where the specific thing you want to modify is located, well, that's when you start loving the editor.

This is why I will spend the last part of this tutorial explaining some of the more common object types and how they work.

Common Object Types

Units
I think most people know what a unit is. It's the thing that runs around and does stuff. A marine is a unit. Buildings are units. Missiles are units(So when your marauder shoots a Punisher grenade, it's in fact shooting a unit). In this object type you can find things as the unit's life, energy, shields and such. Note that everything visual about the unit is not found in the unit but in the unit's actor.

Abilities
Abilities is what units can do(In lack of a better explanation). Stim pack, build, Move, mining are all abilities. Here you can find fields like energy cost, the button it uses, range and the effect that is started when the ability is cast. The ability types you use the most are probably Effect - Instant and Effect - Target. Effect - Instant takes no target and starts an effect as soon as you click the ability. Effect - Target gives you a special cursor that allows you to specify a target(Can be a unit or a point) and when you select a target, the effect is started on the unit/point.

Effects
Effects are the stuff that makes things happen. It's the gears behind the scene in abilities. They can apply buffs, deal damage, heal units, issue orders etc.

The most common effect types are "apply behavior" that applies a behavior(a buff basically) to the unit, "damage" which damages a unit, "Search" that searches for units in a specific area and applies an effect to them, "set" which combines several effects in one.

Behaviors
There are several behavior types but the most common one is "Buff". It works as you might expect it. It is something that is attached to a unit and affects it somehow. It might give extra movement speed, disable weapons, have a chance to block incoming damage and more.

Buttons
I mentioned buttons earlier, they handle the things you see on a button. In game you have a command card in the bottom right filled with buttons. Each button has a corresponding button object type that handles icon, tool tip, hotkey and name.

Actors
Oh, these are tricky but vital. Actors handle the visual stuff that you see. They handle the model, wire-frame, health bar and selection circle of a unit. A unit without actor will look like a white ball.

Actors are the biggest problem beginners have with creating a unit from scratch but you can do a lot with them. They even have a kind of integrated trigger editor called events. I use actor events them in my Cruiser Command map by coloring by asteroids a specific color when they get a behavior and then back to normal when the behavior is removed.

Say I wanted to make an AoE target ability that speeds up all allied units in the area for 15 seconds. Can you guess how things would be connected?
I would have an ability(with a button). The ability would be effect - target and the ability's effect would be a search effect that searches for allied units in a radius around the point. On each unit it would run another effect(of the type "Apply behavior"). This effect would apply a custom behavior of the "Buff" type. The behavior would give a movement bonus.


In Conclusion

Now you should have enough information to learn on your own, but how do you do that? I think the best way to continue learning is to use the object explorer to look around and figure out how things work. Check how stim pack works, check how blink works etc and try to make your own abilities. Ask here on the forums if you have problems but spend at least 15-30 minutes trying to get it to work yourself, it will feel better in the end.

If you look at an ability and it feels too complex, disregard the actors and sound and mostly focus on how the effects, behaviors and abilities interact with each other.
Click here to comment on this tutorial.
Tutorials submitted by users are copyright of the original author. All other content on this site is copyright TheHelper.net.
Copyright is secured automatically upon creation, and does not require registration