Worm, you're a smart guy, but regarding MT there is a gigantic elephant in the room. Namely,
"Why is this system worth using, as opposed to any good scripting language (Python, Ruby, etc.)"
Alright, the problem I simply had not a chance to program on any kind of a scripting language. Though when gazing I can even understand something you've written and I believe it is quite simple to learn a language like that.
First of all, I made MT to have a little practice on programming myslef. The goal behind MT was to make something syntactically and semantically similar to the SCMD triggers, but something more compact, something which allows good graphic way to view and organize triggers. A minor thing was I didn't like how awfully SCMD actions and conditions are named (with spaces in their names), one can't use a NP++ syntax highlighting and autocompletion because of that. I wanted to have a language which incorporates meta-data (about used units, locations and such) in a source file. While a scripting language can statisfy the second requirement, you should agree it is less graphic than MT. In MT you see the triggers sequence
right before your eyes. Syntactic and semantic similarity to the SCMD triggers should be more friendly for people who already have a gist about SCMD text triggers. Actually the word 'language' applied to MT sounds very loud. Inherently MT is the SCMD triggers with an option to specify sequence of triggers with a pattern and to define new names for different objects. Probably MT even has not got the full power of a scripting language (or any other language), but as practice shows (mostly my own and now also Tuxlar's) the expressiveness of MT is enough for a modest practical task of writing triggers for your map. (Though I can't think of an example of such a thing which could not be done easily in MT at the moment, I suspect there
might be some examples; on the other hand one can always bureforce and specify triggers she wants manually without replication.) Usually one doesn't need very complex replication templates, but what she needs is a good way to organize triggers in order not to get tangled in them herself.
But after looking at your two files, that looks extremely cost effective. Those triggers would have taken me hours upon hours to do by hand. You probably made them in a fraction of that time.
Yeah it is cost effective, but I also want to look at it and see the structure of the output triggers without all that superfulous stuff. Also, if another person will write his python triggers he probably will do his definitions in another way. Afterwards if these two persons woould like to cooperate they won't understand each other without studying each other's ways of doing this meta-stuff (or a brute-forceing infomration, as Falkoner named it) instead of directly studying each other's triggers.
Quote from name:Tuxedo-Templar
Hey Wormer, can I ask you a huge favor? Could you cook up a quick version to add a simple language feature: An 'eval' function?
Of course, an ACTION and CONDITION variable would also be very cool, don't know how your code is written, so whichever is easier for you.
If you were to add in condition and action variables, with an eval function like tuxedo-templar asked, I think MT would be extremely useful!
Alright, that would be cool. Could you guys give me a few
real examples where this can be really extremely usefull?
The first reason I won't do it right now is that I am working on my map project and I really want to finish it first. The second reason is that I have to admit that I already quite forgot the code I written more than a year ago and a lil lazy to make any signifacant changes like this one. I even don't know which is easier, to make a true CONDITION and ACTION types or an evalish-like hack. The third reason I don't feel like this is really a crucial thing to do.
Having issues compiling, it keeps saying this line is wrong:
MoveLocation(Reusable_Pixel, Follow_Placeholder, @P(9), @L("Anywhere"))
Reusable_Pixel is fine, Follow_Placeholder is also fine, it points me to the @ symbol in @P(9), no matter what number I change the player to, it says it's an Invalid Argument.
Also, is the Anywhere locations defined by default? Because that also gave me an error
EDIT: Tested, and it just seems to dislike the use of Anywhere, in either spot, why is this?
Could you show me the source?
Some.