|
|
#3161595 - 12/20/10 02:02 PM
Comanche Gold Modding Breakthrough -- Triggers
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Good news for Comanche Gold fans who care: We should hopefully soon have full -- or near-full -- support over triggers!Yes, triggers! For those who are wondering what this means, custom maps have just had a new door opened to them. We can make custom missions that have multiple ways to win or lose, depending on what conditions are fulfilled. For example, we can make a mission in which you win either by protecting a friendly unit from attack, or, if you fail to save him, by racing over to the enemy's heavily guarded HQ and bombing it to pieces in revenge. We might be able make missions with a time limit, so you only have to hold out from a major attack for so long before you win, pretending for a moment that the enemy is low on fuel and only has a brief moment to overrun your base. We can also change AI groupings to patrol different areas if enemy radar stations are destroyed or not, or even if you're spotted by certain units, making penetration easier or more difficult, depending on the circumstances. This isn't even counting some of the other things we can do like adding our own sounds, music, and text instructions to our missions. Now triggers have always apparently been able to be added manually, but the issue with which I've been fighting currently is how to group objects. This is what you'd need in order to distinguish, for example, your teammate from an enemy hokum in a particular trigger. I've finally discovered how to do this, but it's a laborious, long, manual, and ugly process. I've had to write a rather crude tool to speed up the process, and this appears to be working for me (although I'm not sure it's bug free). It's not certain that everything will work, but tests have been very promising. If people are interested in this, let me know, and I'll continue posting more information on this. Be forewarned -- it's not all that easy to get into right away. It requires you to do some extra work to get right, but it should be easier once you get used to it. For example, the first thing to know is that you'll have to learn how to pack and unpack .MRF files. Sounds difficult perhaps, until you realize that if you've unpacked a .PFF file, it's the same thing.  I can write tutorials or some other form of assistance in creating maps to work with triggers. I at least want to create a demo map and release that as an example. I think a number of us should consider making some actual campaigns. If all goes well, I'll be trying to release my own campaign(s) in the near future -- maybe even playable in multiplayer.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3161673 - 12/20/10 03:21 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
Just 3 words:
GO ON FORWARD !!!
ufolev :-)
|
|
Top
|
|
|
|
#3161726 - 12/20/10 04:20 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Triggers for Player Waypoints.Our goal will be to place a text trigger for the player when he flies to waypoint 1. This means when he flies past waypoint 1, a little bit of text will be displayed at the bottom of his screen. What you'll need:- A simple map with waypoints assigned to the player. It is possible to use ufolev's custom map OIL FLAME for this experiment, since it works just fine. Alternatively, if you want to do this yourself and need help doing this part, Editor.pdf, which comes with the game, should explain how waypoints work.
- An understanding of how to pack and unpack a .PFF file. A .PFF viewer such as FwO Raven's pff utility is recommended if you don't have a preferred one.
Instructions:- If you have a properly configured MRF file, such as ufolev's OIL FLAME map mentioned earlier, you may skip so step 3.
- Otherwise:
- Create, or open an existing, custom map that contains some basic waypoints assigned to the Player.
- Make sure the waypoints are named with an 'A', like "A1", "A2", etc. etc.. It should be by default unless you changed which waypoint groups you're editing.
- Make sure the Player's waypoint grouping should be set to A. It should be fine by default.
- Export the map as an MRF file.
- Open the MRF file with a working PFF viewer.
- Extract USER.INF and open it with a text editor. It should look like this:
>TEXTv
|.|1|bMission Name
|l|-
|.|1|wDownloading Mission Parameters...
< - Make the following changes so your file looks like this:
>TEXTv
|.|1|bMission Name
|l|-
|.|1|wDownloading Mission Parameters...
<
>RM01
Passing Waypoint 1
< - Now extract USER.MIS.
- Find the part that looks like this:
<
;---------> Data ENDS <---------- - The '<' character on the line by itself indicates the end of the triggers. You'll want to change that part of the file to look like this:
if
waypoint, P, A1
then
text, 1
<
;---------> Data ENDS <---------- - Place both USER.INF and USER.MIS back into your MRF file.
- Load the mission normally and verify that when you pass waypoint 1, you receive a beep along with a text message at the bottom of the screen telling you "Passing Waypoint 1". If it didn't work, go back over each step.
Explanation and Conclusion:- Novalogic probably thought it was a bad idea to make users load custom missions with multiple files, so they opted to provide a way for custom missions to be loaded with a single file by making the game understand MRF files -- PFF files by a different extension. We can extra files from them now, edit, and then repack them, adding features that the editor just doesn't support.
- Entries of "RM" in the .INF file followd by a two digit number correspond to text messages that you can send to the player by number. When we wrote "text, 1" in the trigger, we were telling the game to look for a text entry of RM01. It might help to think of "RM" as "Radio Message" found in the mission INFormation file.
- Objects are grouped by letter. By default the player object is placed in group "P". This is good to know, since it lets you write triggers for the player.
Other possibilitiesInstead of text, think about playing sound files, including custom ones, perhaps alerting the player about something. Instead of "text, <id>" the command inside the trigger would be "play, <filename>".
_________________________
DavidC99
|
|
Top
|
|
|
|
#3161930 - 12/20/10 10:36 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
Thank you. Will use your suggestions.
ufolev
|
|
Top
|
|
|
|
#3162863 - 12/21/10 09:50 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I ran into a setback in group IDs. It's still very much possible to group objects, but it's just a huge pain to figure out which objects are the ones you are trying to select in order to group. To be honest, I'm actually really unhappy that Novalogic went out of their way to make it this difficult for us to make proper missions for this game. Anyway, I did make a custom mission complete with a few simple triggers and finishing touches like adding different colors to the briefing text (although I think I may have overdid it  ), but this mission is really, really hard... It's not as much hard as it is unfair. I think I may have to work on the dynamics a little more, but the proof of concept is there. Hopefully, I'll get it fixed up and subsequently find a quick way to make it available to everyone.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3162891 - 12/21/10 10:36 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
Hi DC99
I can't wait to try it LOL. Give it on CG custom mission checkpoint, as soon as it possible, please!
ufolev :-)
Edited by ufolev (12/21/10 11:03 PM)
|
|
Top
|
|
|
|
#3163273 - 12/22/10 10:15 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I have added new music to the mission. It works just fine. 
_________________________
DavidC99
|
|
Top
|
|
|
|
#3163699 - 12/22/10 06:37 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I would appreciate it if someone would be willing to test the map and verify that this new mission works for them. I know others might do things of which I haven't even thought, so I'd like to know if I missed anything major. Features of the mission that should work: - Audio and text occur when 2-7 dies.
- Base tells you to take off, and 2-6 responds.
- Sounds and messages on the bottom of the screen direct you as to what to do at all times in a logical manner, like in a regular mission.
- New music for this mission.
I will say, I think that there is room for improvement in the mission, but at the same time, I think that it's OK for a first mission, especially given the amount of work with triggers. If someone is willing to test it, I'd then consider releasing it, pending feedback.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3163815 - 12/23/10 12:05 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
Hi DC99
Let me test it please!
ufolev :-)
|
|
Top
|
|
|
|
#3163819 - 12/23/10 12:31 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Sure.
I know you gave me your Email address already, but I lost it by accident when I closed the window and realized Kali wasn't logging the contents. :/ If you can give it to me again, I'll send you the map.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3163989 - 12/23/10 08:07 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
hi DC99,
I already sent PM with email.
I have 1 additional question:
Is it possible to increase the number of waypoints in CG mission editor above the limit of 10 ?
ufolev
|
|
Top
|
|
|
|
#3164063 - 12/23/10 10:05 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
That's a good question. Waypoint data is stored in the .MIS file and the .JIM file. I believe the .JIM file contains waypoint data for the briefing map, but the .MIS file contains data for the in-game mission. I was able to add waypoints manually in the .MIS file, but I couldn't get beyond ten.
If you're looking to use them as regular waypoints, it doesn't seem possible (yet, anyway). If you are looking to use them as triggers for when the player gets near to them, you can use NPC waypoints as triggers for the player, I believe, but I haven't tested it.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3164418 - 12/23/10 05:02 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Creating a Radio Conversation:Our goal will be to implement a number of triggers that will result in what sounds like a conversation between multiple parties at the start of a mission. Flyboy has lamented that the Editor doesn't allow for this feature. While it's true that the Editor doesn't explicitly allow it, it is entirely possible to add manually. What you'll need:- A simple custom map exported to MRF format. It can even be empty for this example, except for the player.
- An understanding of how to pack and unpack a .PFF/MRF file. A .PFF/MRF viewer such as FwO Raven's pff utility is recommended if you don't have a preferred one.
Instructions:- Extract USER.MIS from you MRF file and open it with a text editor.
- Find the following line. After it marks where triggers begin:
- Find the following lines. Prior to them is where triggers end:
<
;---------> Data ENDS <---------- - Make the following changes so your file looks something like this:
<< ;wp end
if
time, 2
then
pend, 2BAS002.wav, 0
if
time, 2
then
pend, CPLT722.wav, 2
if
time, 2
then
pend, CPLT569.wav, 0
if
time, 2
then
pend, WING003.wav, 1
if
time, 2
then
pend, WING506.wav, 0
<
;---------> Data ENDS <---------- - Place USER.MIS back into your MRF file.
- Load the mission normally and verify that when the mission starts up, after a few seconds, you'll hear what sounds like dynamic radio chatter for that mission. If it didn't work, go back over each step.
Explanation and Conclusion:- pend means to place a sound file in a queue and play it when it is able.
- The first argument given to pend is the sound file.
- The second argument appears to be a delay. This delay would serve to make conversations sound more natural, depending on how calm or frantic the speaker is, etc. etc..
- When the conditions are the same in two triggers that want to pend sound files, sounds appear to be queued in order of appearance of their triggers in the MIS file. In other words, the trigger that appears first gets its sound file added first.
Other possibilities- Some interesting conversations could be played based on this by using the right order of sounds.
- Of note, sound files need not be stock files. They can be custom wav files.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3164684 - 12/24/10 05:18 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Senior Member
Registered: 11/29/06
Posts: 3015
Loc: England, UK
|
Jeez, DavidC99 - for a newcomer you have certainly a lot to offer for the Comanche Gold community - as small as it is. It looks like you've made more breakthroughs in the last week or so than has been made by anyone in the past 10 years. It's a shame though, that so much research and work has had to be done JUST to make missions on par with the original game ones, due to the editor leaving out certain important feature implementation.
Well done, sir!
|
|
Top
|
|
|
|
#3164916 - 12/24/10 11:33 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Thank you, sir.  Incidentally, if you guys are any good with art, you might be able to make new maps -- not missions, but maps. The map formats are in a number of .pcx files (old school picture format), but I haven't been able to open them, yet, with any viewers. The idea is that you provide picture representations of a color map, an elevation map, etc. etc.. The type of representation and the color tell the game what you want done. When you're finished with all of the pictures, you have your map. (Yes, it's more complicated than this, but it might be entirely possible.) I have started work on expanding my Bunker Bashout mission to a seven mission campaign, complete with each mission being full of triggers and new features. Some features, I suspect, will not have been implemented this way in any campaign or mission for CG to date. I hope to complete this in record time.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3165001 - 12/24/10 01:18 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
With your new custom campaign with such high quality Comanche Gold have no choice except to become Comanche Platinum !
:-)
Edited by ufolev (12/24/10 01:38 PM)
|
|
Top
|
|
|
|
#3165359 - 12/25/10 04:21 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Senior Member
Registered: 11/29/06
Posts: 3015
Loc: England, UK
|
As Kid Rock would say, "We're goin' Plat'num!"
|
|
Top
|
|
|
|
#3165484 - 12/25/10 09:51 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I would say we're heading toward 24kt gold.  Platinum would have to be a number of new campaigns, resolutions, better gameplay, details, an entire scripting language behind it, etc. etc.. Essentially what Comanche 4 should have been. 
_________________________
DavidC99
|
|
Top
|
|
|
|
#3166662 - 12/27/10 12:43 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Hmm, I examined melee maps, and it looks like we might be able to make our own with some effort -- maybe even with some triggers to make it interesting. - Imagine fighting over an area with stingers and SAMs scattered all over the place taking shots at us.
- Maybe instead of fighting to the death, we could compete against each other to destroy a target or group of targets first. (Then again, isn't this what Comanche Gold calls coop?
) - We could even do a race map. First one to make it over the SAM field to a specific waypoint wins.
Yeah, I know. Crazy stuff, but it looks like it might be possible.  It's amazing how many features they left out of the editor. In fact, I'm working on the second map of my campaign, and while some may appreciate the triggers, the third one should introduce a very simple but new feature not used before if all goes well.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3167002 - 12/28/10 04:26 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Senior Member
Registered: 11/29/06
Posts: 3015
Loc: England, UK
|
It's funny you should bring this up, only the other night I had the idea of perhaps being able to put AI units into melee maps to make it more 'interesting'. Imagine having to keep a eye out for human players AND AI units? Also, would it be possible to add AI-controlled Comanche's? That would really confuse players! Comanche Racing has previously been tried, and is documented at this site here: http://www.monsta.cc/Comanche/cockpit.htm#cr
|
|
Top
|
|
|
|
#3167293 - 12/28/10 01:22 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
The difference is that we might be able to do some of these things by adding new units, waypoints, and triggers.  Not sure if we can get 2-7's out there in melee maps. I know 2-7 isn't spawned when he's placed in coop maps, but he may be left alone on melee maps. Would be wild if we all had 2-7's at the start. 
_________________________
DavidC99
|
|
Top
|
|
|
|
#3168816 - 12/31/10 01:14 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Timers / CountersBy now I'll assume that extraction and repacking of map files are basic knowledge (although it's not always that easy). Let's say we want a custom sound to play when the player passes a waypoint. Let's also say that five seconds after the player passes the waypoint, we want him to receive a text radio message. First we play the sound file as already demonstrated: if
waypoint, P, A1
then
pend, cust11.wav, 0 You'll have to replace cust11.wav with the name of your custom sound file. Now we need some way of keeping track of time based on this trigger. Therefore, we add the following trigger next: if
waypoint, P, A1
then
clearcounter This sets up a timer when the player crosses Waypoint 1. Now we need to use the timer, so we write a third trigger: if
waypoint, P, A1
and
counter, 5
then
text, 1 Remember to have your radio message, RM01, defined in the .INF file (as shown previously) or else this won't display. This checks that the player has already passed Waypoint 1, and it checks the value of the counter. Five seconds would have had to go by before this trigger's payload is carried out, if all went well. ufolev, since you're working on maps, let me know if you have any trigger ideas or questions about them. In fact, if you want some simple triggers cooked up for you, I might be able to help out.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3168827 - 12/31/10 02:08 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
hi Davi,
After your appearance as mission maker I understood how limited are my knowledges :-( But I will be happy if I learn from your suggestions above how to put some simpliest event trigger in my mission and this will be enough to me.
ufo :-)
|
|
Top
|
|
|
|
#3168856 - 12/31/10 03:33 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
If you change your mind and want more complex triggers written, let me know. I'd be happy to try to help.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3170575 - 01/03/11 02:31 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
By request... TrackingThis will show how to cause enemy units to track the player. Let's say that after the player crosses Waypoint 3, we want an enemy group of Hokums to track the player's movements. if
waypoint, P, A3
then
route, H, WP This is all there is to the trigger itself. It checks if group P, the player, has crossed waypoint 3. If he has, then the group H is routed to the player's location. Route is also used to route units to waypoints. If we wanted them to go to waypoint 3 instead, we could have easily done this: if
waypoint, P, A3
then
route, H, A3 Unfortunately, Novalogic ripped out the option to group units in the editor. This means, by default, the game won't know who you mean by specifying group H. There are a few ways around this: - Either use the Goal checkboxes in the mission editor to make your own limited groupings;
- Hex edit the .POS file to change the object's group ID;
- Or else use a program to edit the .POS file and allow you to change the group ID.
The first option is sufficient if you have one group to make and you don't want complicated triggers. By designating something as an enemy goal, it is given a group ID of E. By making something a goal for the player, it is given a group ID of G. If both are used, the mission editor writes triggers automatically to win if G is destroy and lose if E is destroyed. This can be changed by the modder by simply editing the triggers in the .MIS file. Thus, you can actually make group E a group of enemy Hokums by selecting them all as enemy goals. Then delete the default trigger for group E, which should look like this: if
destroyed, E
then
lose Substitute it with something like this: if
waypoint, P, A3
then
route, E, WP The second option, the one involving hex editing, is fine for a simple switch, but is tedious and not the way to go for a real mission which involves complicated groupings. The third option is the preferred method. I have a custom program I've written that can group units, but it's not complete and requires some manual effort to figure out what object is what. I plan on releasing something to the public once I make it easier to use (and even then it won't be super easy). In the meantime, if someone wishes for me to group something for them before I'm done (which should hopefully be soon -- like hopefully by the weekend), I'd definitely consider doing it for them.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3173652 - 01/06/11 08:44 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I have not completed the tool, yet, and I'll need some time to come up with a straightforward design. So far, when completed, it should allow you to alter the following for each object: Deloros' idea of placing other objects in custom missions which the editor doesn't support is entirely possible. I invented Super 2-7, a highly armored version of the normal 2-7, except I made it so that we don't get along. You can see 2-7, a Frogfoot, and me, all engaged in a free-for-all. Yes, a free-for-all!   Although not entirely related, the following is a screenshot of me firing loads of hellfire missiles at Super 2-7 in what appears to be bullet time.   Custom missions should get a whole lot more interesting if people can take the time to make them.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3173726 - 01/07/11 12:18 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
Hello David,
Will Your new tool for mission editing be separated from the Original Mission Editor or it will be some kind of Moded Super Mission Editor ?
ufo ?
|
|
Top
|
|
|
|
#3173739 - 01/07/11 01:00 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
It would be separate from the mission editor. The way it would work is by analyzing, providing you with the list of objects in your mission, allowing you to make changes to these object properties, and then editing (or even patching, if you will) the exported custom mission file(s) in question. The editing is actually not that difficult. The triggers are actually harder to write once you get used to it.  As soon as you repack the patched file(s) back into your PFF/MRF, you're good to go. In theory, we might be able to make our own mission editor. It's certainly possible, and I already have a general idea of what it would take, but it's still a lot of work. If we had a volunteer who could handle the graphical user interface, I'd consider working on a backend for it.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3175309 - 01/09/11 06:26 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 01/05/11
Posts: 2
Loc: Tampa Bay Area / Florida / USA
|
DavidC99,
Had a great time in Co-op last night with you and fly. I'll look over this existing information and tools and get up to speed before moving forward with what we were discussing.
Thanks for all the hard work on this, Rob
|
|
Top
|
|
|
|
#3175499 - 01/09/11 11:22 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
I had fun, too, and your plan to look over everything sounds great. I've finished the tool mentioned above, but it's being tested by someone. I think what we discussed may still be the route to go, however. Unfortunately, there are still things regarding the editor and mission files about which I'm still unsure. The main things I'd like to learn right now are: - The rest of the .pff file format. I have the basics, but there are still some bytes of which I'm unsure.
- JIM files. Lots to learn on those.
- How objects know which entries in the AI list are the ones to use for when they die. We'd need this to build the AI list properly. (Of note, while the regular missions appear properly done, the mission editor that we use creates duplicate entries in an inefficient manner. Go figure.)
After I have all of this, it appears I may actually be able to do a huge portion of the project.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3176685 - 01/11/11 12:13 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Junior Member
Registered: 12/16/10
Posts: 74
|
Trigger reference material. Note: All information may not be accurate; this contains some guesses. It's also not complete. - Conditional beginning:
- IF: Marks the start of a trigger.
- Binary operators:
- AND: Both conditions must be true.
- OR: One condition must be true.
- NOR:Both conditions must be both false.
- NAND:Both conditions cannot be both true.
- ORN: Same as NOR.
- ANDN: Same as NAND.
- Conditional consequence:
- THEN: Marks the end of the test condition and the beginning of the command.
- Event Tests:
- SPEE: Speed. Measures player speed against a number.
- TAIR: Checks if player is targeting friendly air unit.
- TGND: Checks if player is targeting friendly ground unit.
- GEAR:True if player's gear is down
- FACE: True if facing a direction or waypoint
- NOTF: NOT facing a direction or waypoint
- NEAR:Nearer. Measures if the player is nearer to the supplied waypoint than the supplied distance.
- FART:Farther. See NEAR.
- ABOV:Above. Checks if player is above supplied height.
- BELO:Below. Checks if player is below specified height.
- ROCK:Rockets. Compares amount of available player's rockets to supplied number.
- WEAP:Weapon. This compares a specified number against the player's current weapon index.
- ARTI:Artillery. Compares amount of player's available artillery calls to supplied number.
- DAMA:Damage/Damaged. Checks if damage has exceeded a supplied number.
- HELL:Hellfires. Compares amount of player's available hellfires to a supplied number.
- STIN:Stingers. Compares amount of player's available stingers to a supplied number.
- WING: True if player sent a numbered message (ie. one of the M commands) to the wingman.
- TIME: Compares supplied number to time since mission started.
- COUN:Counter: Compares counter to supplied number to see if a certain amount of seconds has passed.
- ALIV:Alive. Tests if supplied object group is alive.
- INTA:Intact. Tests if supplied object group is intact.
- KILL:Killed. Tests if supplied object group has had a certain number of members killed.
- ATTA:Attacked: Checks to see if supplied group has been attacked.
- DEST: Destroyed. Checks if supplied group has been destroyed.
- SEES:Tests to see if one unit has established visual contact.
- ENCO:Encounter. Checks to see if a member of group one has established a lock on a member of group two.
- WAYP:Checks if member of supplied group has crossed the supplied waypoint.
- Commands:
- WIN: This forces the game to end in a win
- FLAS:Flash. This causes specified parts of the HUD to flash.
- END: This causes the game to end with no win or loss.
- ROUT:Routes AI either to a waypoint or to a group (which may even be on the move).
- TEXT: Writes an indexed text message from the INF file.
- PLAY:Plays a sound file.
- PEND: Places a sound file into a queue and plays it when available after the given delay.
- SOUA:Squak. Has to do with playing audio. Appears to be a synonym of PEND, but it may be private to own channel. (ie, in multiplayer only the local player who triggered it hears it, such as when exceeding air speed)
- LOSE: Forces game to end in a loss.
- ELIM:Eliminate. Possible synonym for VAPO.
- VAPO:Vaporize. Kills a group dead instantly.
- SETA:setai. Gives AI orders based on a number. Format unknown at present.
- CLEA:clearcounter. Resets the counter, which acts as a timer for triggers.
- ALER:Alert/Alerted. Unknown.
Examples might possibly follow later if anyone is interested. Please let me know if there are any errors or corrections to make.
_________________________
DavidC99
|
|
Top
|
|
|
|
#3285863 - 05/03/11 02:16 AM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: DavidC99]
|
Member
Registered: 03/19/08
Posts: 150
|
First I want to say Thank You DavidC99 for all patience to explain the triggers with simple words I want to give a positive feedback because I included 2 simple triggers in my last Comanche Gold custom mission "SLAVES" I used them to situate a negative outcome options. Now I am more encouraged to use other kind of described triggers :-) ufo :-)
|
|
Top
|
|
|
|
#3292624 - 05/11/11 03:09 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: ufolev]
|
Member
Registered: 03/19/08
Posts: 150
|
There is other waypoint trigger used to situate win option in the Comanche Gold custom mission "CONTACT"  ufo :-)
|
|
Top
|
|
|
|
#3528431 - 02/28/12 09:31 PM
Re: Comanche Gold Modding Breakthrough -- Triggers
[Re: ufolev]
|
Member
Registered: 03/19/08
Posts: 150
|
2 new and different kind of triggers are used in the Comanche Gold custom mission "DEAD OR ALIVE" - the first is an area trigger when the player passes wpt1 2 blackhawks are redirected to follow him constantly, - the second is an area and time trigger when the player passes wpt 5 it starts time counting and gives a radio conversation messages.  many thanks to DavidC99 ufo :-)
Edited by ufolev (02/28/12 09:36 PM)
|
|
Top
|
|
|
|
|
|
|
| |