Warcraft III resources & community, 2003–2006 · archived

Transporting Units/etc from map to map / Campaign Editor

17 posts
#1

Transporting Units/etc from map to map / Campaign Editor

This will be an example for a two map long campaign where the hero and the player's money is transported. The campaign is uploaded on this site, here's the quick-link:
http://www.wc3sear.ch/?p=Maps&ID=9634
You can extract the maps from the campaign by opening the campaign in the campaign editor, right-click on the map and "extract map".
Important: When creating game-caches, labels, variables and all that stuff, remember NOT to put any spaces in their names. E.g. "OneMoreVariable" is a valid name, while "One More Variable" is not. As far as I know WE doesn't allow to put spaces while naming variables anyway. However, that doesn't fit for games-caches or the labels/categories used in a cache. WE won't tell you that there's a problem, it just won't work.


On our first map, we create these variables:


http://img15.exs.cx/img15/9328/CPN_tut_map01_variables.jpg


Then, we create following triggers:


http://img15.exs.cx/img15/6147/CPN_tut_map01_trigger01.jpg
http://img15.exs.cx/img15/294/CPN_tut_map01_trigger02.jpg
http://img15.exs.cx/img15/4793/CPN_tut_map01_trigger03.jpg
http://img15.exs.cx/img15/3488/CPN_tut_map01_trigger04.jpg


In the second map we need these triggers:


http://img15.exs.cx/img15/9499/CPN_tut_map02trigger01.jpg
http://img15.exs.cx/img15/6708/CPN_tut_map02trigger02a.jpg
http://img15.exs.cx/img15/9029/CPN_tut_map02trigger03a.jpg


OK. Now we open the Campaign Editor:


http://img14.exs.cx/img14/580/CPN_tut_01open_cpn_editor.jpg


Now it should look this way:


http://img15.exs.cx/img15/3681/CPN_tut_02_cpn_editor.jpg


I called my campaign "Unit Transport". Now, we select "Unit Transport" in "map files" and right-click on it. There's the option "add map":


http://img15.exs.cx/img15/4537/CPN_tut_04add_map01.jpg


There, we select our first map:


http://img15.exs.cx/img15/3808/CPN_tut_03add_map02.jpg


The Campaign editor checks now if there's any trigger inside the map which gives information about the following map (Game - Set next level) and shows the path


http://img15.exs.cx/img15/8581/CPN_tut_05map_added.jpg


Now we right-click on that path and add the second map.


http://img15.exs.cx/img15/1439/CPN_tut_06second_map.jpg


After doing so, we click "Loading Screen" (upper panel, atm we are in "General"). There, we right-click on the white field


http://img15.exs.cx/img15/6407/CPN_tut_07add_button.jpg


Now we add an button. It's important for the first map that we mark "Visible (first time campaign is loaded)". "Title" is for the name in the campaign menu, here I called it "UnitTransportButton1


http://img15.exs.cx/img15/9184/CPN_tut_08button01.jpg


We add a second button concerning to our second map. There we don't mark "Visible", else the players could chose every map right from beginning


http://img15.exs.cx/img15/6517/CPN_tut_09button02.jpg

Looking at "General", it should be like this:


http://img15.exs.cx/img15/2804/CPN_tut_10finished2.jpg


Now we add one small action in the first map by right-clicking on the map choosing "Edit Map". This will just change the file integrated in the campaign, the original map-file (the one you created before importing them in the campaign editor) won't be changed. If you do your changes in the original map-file, you'll have to replace the map in campaign editor by right-clicking and choosing "Replace Map".


http://img15.exs.cx/img15/5220/CPN_tut_map01_triggerButton.jpg


For further information, use the demo campaign that comes with TFT. All I know about game-caches, cinematics or else I learned from that campaign. Most of the triggers there are well explained and show various ways of how to play with game-caches.

PM me if you find any mistakes in this tutorial
#2
good job
#3
Thanks man!! That helped me for my campaign.
#4
hello there, this tutorial was amazing but there is something that i need to know(if possible):

Do you know how to link map, in a way i can go back to the last map(like a submap, where do you go to make a quest and them returns to the main map).

if you know plz post here, and thx for reading.
#5
Hm, that is MUCH harder. Can't really help though I never made a multiple-map rpg or else, but I can give you an idea:

You need sth like a trigger that, when it runs, stores all necessary information (discovered area, fallen enemies, quests, destroyed buildings,...) in a game cache and then loads the submap. After leaving the submap, you load the main map and change everything via triggers using the game cache information so it almost looks like you left it when entering the submap. Darky used sth with save game/load game triggers in RotD, but I'm not really sure how he did everything (though it doesn't work for me)
#6
To DarkShadow: Thank-you for someone finally writing this tutorial, it was VERY easy to understand. I am hoping to see more tutorials written by you, and you are guaranteed that I will read them. 5000/10 - Great job, DarkShadow! :)
#7

campaigns only?

Can you do this awesome function in normal maps? It would be awesome! (but i doubt it)
#8
You mean normal singleplayer maps? Yes, you can. Some patches (and TFT) ago this was the only way to create a campaign, but you have to care in which folders you place the maps. Only problem is multiplayer: Game Caches are deleted after you left a B.Net/LAN-game, what makes them useless for multiplayer.
#9

...

Ty, very clear tutorial, not one flaw, and i look for flaws :).
#10

AHHHH NOOO!!!!! You CAN use Game Cache in Multiplayer!!!!!!!

ahhhhh i must know how u do it!?!??! EVER QUEST, NIGHT OF THE DEAD, V QUEST, RESEDINT EVIL, DARK DEEDS, They all have game caches, How elsew would u b able to save ur unit/values and load him up again in a diff game?!?! PLZZZ I MUST KNOW!!!!!! :x :x :x :x
#11
No these map did't have game cache, cuz you cant use game cache in multiplayer maps.
These map use a save/load system.

There is a link below where you can download my save/load code 5, where you can learn how to create a save/load system. :D
#12
its ok only 1 problem tho,when u path where the maps load from do u load them from=C:\Program Files\Warcraft3\Maps\My Maps\Turtorial or does it already lookin wc3 OR is it on the desktop specify this!!!plus dont even make these kinds of things theres no hope ur just making fake crap that shouldnt even be told
#13
HELP PLEASE my computer wont load some of the tutorial. Is there anywhere where i can download the turtorial or something :cry:
#14
LOL it loaded dont worry anybody :D
#15
Just a quick tip here: DO NOT USE SPACES for any of your names (names of the variable, names of the category, names of the cache, etc...).

Also, the WCIII Demo Campaign is quite helpful as well (that demonstrates the process used for heroes; it also supplies triggers to check if anything is in the cache).