• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] Copy / Paste Trigger from one map to another

Status
Not open for further replies.
Level 6
Joined
Jan 12, 2014
Messages
59
Hello

I'm trying to copy paste trigger from one map to another.
All of them are based on variables etc. NOTHING on the actual map. It's a kind of melee init but with my spells etc.

However, even if it works for the most part, some triggers are... broken... My dialog boxes are empty, no text, and some spells doesnt work either...
I copy pasted a file with everything in it. And i tried with both maps open in the editor to ctrl C / ctrl V.

Another thing : how can i copy paste the Game Constants too ?


Thanks !
 
Level 20
Joined
Mar 16, 2008
Messages
811
1) For the triggers just make sure all the variables and triggers are in the same category folder, also make sure Trigger Editor -> JASS Helper is enabled, then,
Right click in your folder (the one that contains the triggers), press copy and go to your other map and press paste. You also need to tick the option from File -> Preferences -> Automatically create variables when pasting unknown trigger data.
(How can I copy/paste triggers?)

2) I don't think there is an easy way to copy Gameplay Constants?

Let me know if that works.
 
Level 20
Joined
Mar 16, 2008
Messages
811
What do you mean "in the same category folder" ?
The variables must be "next to" the triggers which use it?
Everything is in the same folder. And i have sub-folders etc.
No that's not required to use the triggers. But it makes it easier to copy/paste from map file to map file. Because if you copy the triggers over before the variables are copied over. Then all the variables will be blank and you would need to set them up again.
 
Level 6
Joined
Jan 12, 2014
Messages
59
No that's not required to use the triggers. But it makes it easier to copy/paste from map file to map file. Because if you copy the triggers over before the variables are copied over. Then all the variables will be blank and you would need to set them up again.
Nono, everything is in ONE SINGLE folder. It's easier indeed.
But still doesnt work
And yeah the preference thing is checked, i alrdy read the thread you quote. Its strange

Look :

1689447548821.png


1689447535849.png

It makes no sense xD
 
Last edited:

Uncle

Warcraft Moderator
Level 70
Joined
Aug 10, 2018
Messages
7,375
Go through all of the variables and make sure that they have the correct variable type. It sounds like some are getting unset which is a bug. Then after fixing the variables, proceed to delete all of the triggers but keep the variables. Then save, return to your original map, and copy ONLY the triggers this time and then paste them into the new map. Hopefully this will avoid the variable breaking issue and preserve the triggers.
 
Level 6
Joined
Jan 12, 2014
Messages
59
Go through all of the variables and make sure that they have the correct variable type. It sounds like some are getting unset which is a bug. Then after fixing the variables, proceed to delete all of the triggers but keep the variables. Then save, return to your original map, and copy ONLY the triggers this time and then paste them into the new map. Hopefully this will avoid the variable breaking issue and preserve the triggers.
Okay i'll try to do it your way ! I keep you informed if it still bugs !

I have custom datas for units spells etc aswell as importes models/icon
In which order to you advice me to import it ?
1- models icons
2- custom data
3- variables & triggers
?
 
Level 20
Joined
Mar 16, 2008
Messages
811
Maybe it's something to do with the language loaded? I know sometimes Korean letters don't appear in game when I have the English set loaded. I know the French alphabet is the same so it's unlikely but maybe causing the text to not load?
 
Status
Not open for further replies.
Top