Oh, indeed! How I haven't thought of it?
+1
Some.
For some reason (probably because my OS is a WinME), it won't run for me. Major letdown and disappointment. It doesn't even pop-up when I ctrl+alt+delete. I've got 4 things on there: my wireless device's program, Firefox, Systray and Explorer.
Do you have Java Runtime Environment Installed, and are you trying to run it through Notepad++ like you're supposed to?
None.
Do you have Java Runtime Environment Installed, and are you trying to run it through Notepad++ like you're supposed to?
Yes, and no, in that order. It took me a while to find the ANSI version that'll work on my computer...but it's amazing now. I'm currently too tired to comprehend it.
Post has been edited 2 time(s), last time on Sep 6 2009, 6:33 am by poison_us.
You know, if you're not able to get Notepad++ up and running, but don't mind using just plain notepad or another text editor to do your text macro triggers, then I could set you up with a simple .bat file or something for compiling your macro triggers. MacroTriggers is really only a command line application itself, after all. Notepad++ just adds a bunch of stuff for conveniences, but nothing essential, really.
None.
I got it up, just the step #3 or whatever currently has me fuxxored.
EDIT: After trying for roughly 23 or so minutes, I'm still equaling the fail.
3. Use mtrigsc from command line. The .jar file mtrigsc.jar is a java executeable file. It takes three parameters: the source file with your triggers written on MacroTriggers and names of two output files with SCMD triggers and properties respectively. The most straightforward way is to invoke it directly from the command line. To open command line you go Start->Run... and type cmd. To run mtrigsc on your source file source.mtrigger you type java -jar <full path to mtrigsc.jar> <full path to source.mtrigger> out.trigger out.property. Two specified files out.trigger and out.property will be created in your current directory.
I can't figure out how to get this to work. What I'm putting in is:
java -jar "C:\Program Files\MT1.5\mtrigsc.jar" "C:\Program Files\MT1.5\mtrigger.xml" "$(NAME_PART).trigger" "$(NAME_PART).property" . What the DOS spits back at me before closing [yay for prt scr] is:
MacroTriggers Compiler v1.5
line 1:1 no viable alternative at character '?'
line 1:44 no viable alternative at character '?'
in c:\Program Files\MT1.5\mtrigger.xml:line 1:0: required <...>+ loop did not match anything at input '<'
Any help?
Post has been edited 1 time(s), last time on Sep 8 2009, 3:19 am by poison_us.
Thanks to TuxLar for his epic video tutorial
One thing I'm wondering: that Alt+2 that you are talking of do not work for me... wtf?
And what's the difference between "mtrigger" and "mtrigger help" language?
And also, shouldn't I be able to select a value and have a little list that pop-up over my mouse or something like that? Right now, I'm not ever getting to select a block of text by a single click. I do not know if that's normal ;o
None.
I got it up, just the step #3 or whatever currently has me fuxxored.
EDIT: After trying for roughly 23 or so minutes, I'm still equaling the fail.
3. Use mtrigsc from command line. The .jar file mtrigsc.jar is a java executeable file. It takes three parameters: the source file with your triggers written on MacroTriggers and names of two output files with SCMD triggers and properties respectively. The most straightforward way is to invoke it directly from the command line. To open command line you go Start->Run... and type cmd. To run mtrigsc on your source file source.mtrigger you type java -jar <full path to mtrigsc.jar> <full path to source.mtrigger> out.trigger out.property. Two specified files out.trigger and out.property will be created in your current directory.
I can't figure out how to get this to work. What I'm putting in is:
java -jar "C:\Program Files\MT1.5\mtrigsc.jar" "C:\Program Files\MT1.5\mtrigger.xml" "$(NAME_PART).trigger" "$(NAME_PART).property" . What the DOS spits back at me before closing [yay for prt scr] is:
MacroTriggers Compiler v1.5
line 1:1 no viable alternative at character '?'
line 1:44 no viable alternative at character '?'
in c:\Program Files\MT1.5\mtrigger.xml:line 1:0: required <...>+ loop did not match anything at input '<'
Any help?
Well, mtrigger.xml is the wrong file. That's just your language definition for Notepad++. The second file path parameter refers to the .mtrigger file containing your macro triggers themselves.
Not sure why you're going the command line route, though. Just copy pasta the code box into the Execute dialog of NP++ (like in my tutorial videos).
Also...
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? Like, say, you define a set of variables:
STRING str1 = "Brings(@CurrentPlayer, @AtLeast 1, "
UNIT marine = @U("Terran Marine")
STRING str2 = ", @Anywhere)"
Then you use them in your trigger like this:
TRIGGER
OWNERS: @P(1)
CONDITIONS:
eval( str1 + "marine" + str2 )
ACTIONS:
...
ENDT
How doable would that be?
None.
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.
None.
Thanks to TuxLar for his epic video tutorial
One thing I'm wondering: that Alt+2 that you are talking of do not work for me... wtf?
If the language definitions are installed correctly, you could also go under the View menu, Collapse Level, and select 2. That should neatly collapse all 2nd-level nested groups in your open files.
And what's the difference between "mtrigger" and "mtrigger help" language?
And also, shouldn't I be able to select a value and have a little list that pop-up over my mouse or something like that? Right now, I'm not ever getting to select a block of text by a single click. I do not know if that's normal ;o
'mtrigger help' is just a silly "language" made up to make the help file look pretty and allow collapsing it into a neat list. 'mtrigger' is your actual macro trigger language definition.
Here's a tip: Adding in //> and, on a later line, //< lets you make your own collapsible groups in your macro trigger files. Useful for organization.
None.
I've been sort of lurking this topic for quite some time, but haven't really gotten extremely interested until now. 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! If you could do that, I would be major happy!
None.
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.)"Attached are a few examples of what you can do with Python:
"one.zip" is an example of a Python file I wrote in a few minutes, with example input and output text. just an illustration of how unbelievably simple some useful operations are.
"two.zip" is an complex example - I used a python script to manage the upgrade tree/probabilities for my rpg. included are the main trigger file, various input/output files, but all you really need to know is you can mess around with the input values, run techtree.py, and trig.txt is updated accordingly.
Attachments:
None.
This is system is worth using because it allows you to more easily organize your triggers, and is already written for people's use, rather than them using their own scripted language, which takes a bit of time to write. I don't think you realize the full capabilities of this language, azala.
None.
I've been sort of lurking this topic for quite some time, but haven't really gotten extremely interested until now. 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! If you could do that, I would be major happy!
I have an old tool I used for text triggers for doing eval-like stuff, but without Macro Triggers integration it'd be a pain to use. Yeah this needs to be implemented. I wouldn't mind not having condition or action variables if I had just an 'eval' function (or something equivalent), really.
None.
This is system is worth using because it allows you to more easily organize your triggers, and is already written for people's use, rather than them using their own scripted language, which takes a bit of time to write. I don't think you realize the full capabilities of this language, azala.
What sort of operation is easier to do in MT?
And why would you go through the process of learning a whole new language that has relatively little testing behind it (compared to scripting languages), and has zero value outside the SC context? Your productivity is directly tied to the reliability and usability of the system, so if something goes wrong, you're *really* out of luck.
None.
This is system is worth using because it allows you to more easily organize your triggers, and is already written for people's use, rather than them using their own scripted language, which takes a bit of time to write. I don't think you realize the full capabilities of this language, azala.
Yeah I would actually prefer to use a scripting language, but my problem is that I don't have a complete enough knowledge of python or ruby in order to create my own .py files for trigger replication..
Also, I'm really rather interested in one of the earliest posts in which wormer said you could define variables as units, which would allow you to modify the definition of the variable thus changing all your triggers at once, instead of modifying each individual trigger to swap one unit for another.
Macro Triggers looks more friendly to people who haven't a working knowledge of programming yet.
[Edit]Also, it looks like there are a few people around here who would love to help people learn to use macro triggers, while I am rather alone in my quest to learn to program in python.
[Edit]
And why would you go through the process of learning a whole new language that has relatively little testing behind it (compared to scripting languages), and has zero value outside the SC context? Your productivity is directly tied to the reliability and usability of the system, so if something goes wrong, you're *really* out of luck.
Actually that is a rather good point. I am extremely limited on my time, I'm a busy person. I'm willing to try out MT right now, but I'm actually not sure if I will put my time and effort into learning how to use it effectively, as if I were to learn something like Python.. That would be useful outside of SC context, very useful.
None.
Macro Triggers looks more friendly to people who haven't a working knowledge of programming yet.
This is exactly why I recommended Python. Spend an hour with it and then re-evaluate your position
None.
Spend an hour with python? I've spent quite a few hours with it actually. I can just about create a very simple game, even using the A-Star algorithm for AI.. But other than that, I really can't use python to do much. 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.
None.
MacroTriggers is extremely simple if you've already been triggering in SC before, it's a language already set up to be specifically geared toward SC, instead of you having to do all the basic brute-forcing, it's already been done. With the help file and the autocomplete it's ridiculously easy to get, and you just get faster at it the more you use it.
Yes, all the operations
could be done using another scripting language, but that would require you to also write the basic connections between the language and SC itself, this is already done in MacroTriggers, loops, functions, variables, all already possible and no brute-forcing information except writing the actual triggers themselves.
None.
This is system is worth using because it allows you to more easily organize your triggers, and is already written for people's use, rather than them using their own scripted language, which takes a bit of time to write. I don't think you realize the full capabilities of this language, azala.
What sort of operation is easier to do in MT?
And why would you go through the process of learning a whole new language that has relatively little testing behind it (compared to scripting languages), and has zero value outside the SC context? Your productivity is directly tied to the reliability and usability of the system, so if something goes wrong, you're *really* out of luck.
Good argument, actually. Actually I already have a Javascript tool with trigger bindings for that very reason. I built it earlier in a failed bid to make a web application for trigger making, and it could ostensibly be used for that purpose in its current form (getting it to plug it into notepad++ or another IDE might take some work, though). But I don't use it because the added layer of language features do little to improve trigger making, as triggers are basically a shallow and highly constrained
declarative language that would rarely be able to make use of the sorts of abstract features normal languages possess. Even MacroTriggers' own MACRODEF; it's equivalent of functions, is something I rarely ever use, for example.
There's little in terms of specifics that you can do with trigger making that applies outside of its own domain, really. And all the syntax and data types of triggers are built into the language itself rather than needing to be wrestled with as data variables of another language's bindings library. The
only real shortcoming with the features of the native language is, as I addressed with my 'eval' request, control of conditions and actions as data rather than code. But even that shortcoming is not a substantial drawback, really.
Note also that both me and Wormer have already made
multiple non-trivial maps with it. It's not perfect, sure, but it definitely does its job.
Post has been edited 6 time(s), last time on Sep 20 2009, 8:31 am by Tuxedo-Templar.
None.