Automatically importing triggers?

Status
Not open for further replies.
Level 15
Joined
Aug 7, 2013
Messages
1,342
Hi,

Is there a script/command I can put in a map which takes a(n) (absolute) path as an argument to search for a Trigger file (.wtg), which it then imports directly into the map?

It would run this command every time I load the map.
 
Level 15
Joined
Aug 7, 2013
Messages
1,342
I dont think this is supported by this way(when map is loading), but you can do

//! import "filepath", which will import the script when you save the map

This will import a trigger file? Will it not overwrite the entire triggers already in the map?

Edit: Also, where does the script go afterward?
 
Last edited:
Level 23
Joined
Apr 16, 2012
Messages
4,041
it will place the contents of .j I believe where the import line is, but they are imported before pretty much anything else happens. It imports .j, so is only useful for jass/vJass stuff.

What you want to do is otherwise impossible to do
 
Status
Not open for further replies.
Top