Jump to content

Recommended Posts

Posted

Hello people!

I am completly new to the mission editor, and i am trying to make a standard PvP file with some AI and stuff. Ive ran into a problem a bit early on, and ill run into MANY more if i dont get something to help me...

 

My problem right now is that i simply cant figure out how to make airfields capturable and stuff.. I want an airfield with 2-3 anti air things, and when they're done with, the base will be captured by the other team, and new anti air things will spawn! Simple for you, i cant even find out which anti air thing i need :I

 

I know about the lua thingy, and im pretty good at c++ sp lua isnt gonna be hard, i just dont know how i set it up so i can begin coding. I have found no tutorials on the internet covering this for a complete noob...

 

 

Any of you wanna help me, maybe add me on skype or something and figure it out from there?

Posted
To capture an airfield you need to place a unit inside, with no other coalition in it. I think. So.... i would activate the unit, once the three AAA are destroyed.

 

Yea well im so new i dont understand half of this :I

You're saying place a unit without "coalition" inside the airfield and when the three AAA are dead, activate it? How will this change the side of the airfield?

 

Sorry for my dumbness

Posted

Place a blue unit named "capture" inside your hostile airfield. Check "late activation" below the unit's name.

 

Place your 3 SAM/AAA sites, named AA1, AA2, AA3.

 

Names are not important, just will make things easier to understand

 

Open the triggers menu (about halfway down the column on the left side of the ME)

 

Click "new" in the leftmost column of the trigger menu.

 

Type : capture trigger in the NAME field. Leave type as 1 ONCE and event as NO EVENT.

 

Click NEW in the conditions column.

 

Select "group dead" from the drop down menu.

Select "AA1" from the group menu.

 

Repeat this step for AA2 or AA3. Alternately, you can place all three units in the same group, and you will only need one condition.

 

In the TRIGGERED ACTIONS column, click NEW.

 

Select GROUP ACTIVATE from the drop down menu, select "capture" from the group menu.

 

Altogether it will look like this:

1 ONCE (capture trigger, NO EVENT)

 

GROUP DEAD (AA1)

GROUP DEAD (AA2)

GROUP DEAD (AA3)

 

GROUP ACTIVATE (capture)

 

When all of your AA at the hostile airfield is dead, the blue "capture" unit will spawn in and the airfield should turn blue.

Posted
Place a blue unit named "capture" inside your hostile airfield. Check "late activation" below the unit's name.

 

Place your 3 SAM/AAA sites, named AA1, AA2, AA3.

 

Names are not important, just will make things easier to understand

 

Open the triggers menu (about halfway down the column on the left side of the ME)

 

Click "new" in the leftmost column of the trigger menu.

 

Type : capture trigger in the NAME field. Leave type as 1 ONCE and event as NO EVENT.

 

Click NEW in the conditions column.

 

Select "group dead" from the drop down menu.

Select "AA1" from the group menu.

 

Repeat this step for AA2 or AA3. Alternately, you can place all three units in the same group, and you will only need one condition.

 

In the TRIGGERED ACTIONS column, click NEW.

 

Select GROUP ACTIVATE from the drop down menu, select "capture" from the group menu.

 

Altogether it will look like this:

1 ONCE (capture trigger, NO EVENT)

 

GROUP DEAD (AA1)

GROUP DEAD (AA2)

GROUP DEAD (AA3)

 

GROUP ACTIVATE (capture)

 

When all of your AA at the hostile airfield is dead, the blue "capture" unit will spawn in and the airfield should turn blue.

 

Thank you! How will i make this happen more than once? For ex. when red captured a base blue will be able to capture it again. And isnt it easier to make this in some sort of lua file?

Posted
Thank you! How will i make this happen more than once? For ex. when red captured a base blue will be able to capture it again. And isnt it easier to make this in some sort of lua file?

 

IF you can write LUA that is. Besides, conditions and all that stuff still need to be set in the editor unless you want your code to get really cumbersome.

 

You can pull of a lot of cool stuff with just the trigger/condition system and the flag system without even being able to print "hello world" in LUA. The flags being a poor man's way to remember Variables ( Meaning you can store TRUE, FALSE, or a number on a flag. You can have a lot of flags, more than you'd ever need).

 

I would make it so that each time the anti-air is destroyed, the value of a certain flag is increased by one. That value is then the condition for another trigger that will spawn the AA, wich should auto-capture the base. If they get destroyed the flag value is increased once again wich will fire another trigger, spawning enemy AA's this time. It will be time-consuming to set this up to happen 20+ times or so for a fun MP mission but a nice side-effect you could make is have the AA appear in different positions every time. If you don't want to set this up but instead just want the unit to respawn you'll have to write a script for it or use something like MiST.

 

have fun and good luck with making the mission!

Check my F-15C guide

Posted
IF you can write LUA that is. Besides, conditions and all that stuff still need to be set in the editor unless you want your code to get really cumbersome.

 

You can pull of a lot of cool stuff with just the trigger/condition system and the flag system without even being able to print "hello world" in LUA. The flags being a poor man's way to remember Variables ( Meaning you can store TRUE, FALSE, or a number on a flag. You can have a lot of flags, more than you'd ever need).

 

I would make it so that each time the anti-air is destroyed, the value of a certain flag is increased by one. That value is then the condition for another trigger that will spawn the AA, wich should auto-capture the base. If they get destroyed the flag value is increased once again wich will fire another trigger, spawning enemy AA's this time. It will be time-consuming to set this up to happen 20+ times or so for a fun MP mission but a nice side-effect you could make is have the AA appear in different positions every time. If you don't want to set this up but instead just want the unit to respawn you'll have to write a script for it or use something like MiST.

 

have fun and good luck with making the mission!

 

Well do you know any good sources to learn about the lua system in DCS? I could learn lua really fast, i just dont know how the files work and which variables can do what :I

 

Thanks though!

Posted (edited)
Place a blue unit named "capture" inside your hostile airfield. Check "late activation" below the unit's name.

 

Place your 3 SAM/AAA sites, named AA1, AA2, AA3.

 

Names are not important, just will make things easier to understand

 

Open the triggers menu (about halfway down the column on the left side of the ME)

 

Click "new" in the leftmost column of the trigger menu.

 

Type : capture trigger in the NAME field. Leave type as 1 ONCE and event as NO EVENT.

 

Click NEW in the conditions column.

 

Select "group dead" from the drop down menu.

Select "AA1" from the group menu.

 

Repeat this step for AA2 or AA3. Alternately, you can place all three units in the same group, and you will only need one condition.

 

In the TRIGGERED ACTIONS column, click NEW.

 

Select GROUP ACTIVATE from the drop down menu, select "capture" from the group menu.

 

Altogether it will look like this:

1 ONCE (capture trigger, NO EVENT)

 

GROUP DEAD (AA1)

GROUP DEAD (AA2)

GROUP DEAD (AA3)

 

GROUP ACTIVATE (capture)

 

When all of your AA at the hostile airfield is dead, the blue "capture" unit will spawn in and the airfield should turn blue.

 

 

That is what I meant. Sorry, I was in a hurry, i was not very clear.

 

So..... You want also to spawn AAA, when the airfield is taken? Every time??

 

You could spawn units from any coalition, using a combination of actions and using flags. Try this. Set a trigger zone in the airport

 

All are switched conditions.

 

1.If blue unit is inside zone (airpot) THEN set value flag number 100= 1 ( we will use the flag to say which coalition is the next one).

2 if any blue coalition unit is outside the trigger zone ( if there is not any blue units in the trigger zone is because the AAA has been destroye, is it?) AND flag 100=1 ( the last unit in the zone was blue) THEN spawn three red AAA AND set flag 100=0 ( now, we have changed... this will tell us that now the airfield is red)

3 if red coalition is outside the airport AND flag=0 THEN spawn three blue AAA AND set flag 100=1.

And now this is cyclic.

 

You see, the condition needed for changing the airport control is to destroy the units. The flag value just tell us which coalition will be spawned there. Is like a switch. Flag values could be.... flag "coalition" and value "blue" or "red", instead of flag 100, and 1 and 0 but the ME doesn't accept words.

 

 

You could probably do this by a simple script but i dont know how to program... just some very basic things... so....

 

Search Mist script and read the manual.... and the DCS Mission Editor manual. It helps.

Edited by ESAc_matador
Posted
That is what I meant. Sorry, I was in a hurry, i was not very clear.

 

So..... You want also to spawn AAA, when the airfield is taken? Every time??

 

You could spawn units from any coalition, using a combination of actions and using flags. Try this. Set a trigger zone in the airport

 

All are switched conditions.

 

1.If blue unit is inside zone (airpot) THEN set value flag number 100= 1 ( we will use the flag to say which coalition is the next one).

2 if any blue coalition unit is outside the trigger zone ( if there is not any blue units in the trigger zone is because the AAA has been destroye, is it?) AND flag 100=1 ( the last unit in the zone was blue) THEN spawn three red AAA AND set flag 100=0 ( now, we have changed... this will tell us that now the airfield is red)

3 if red coalition is outside the airport AND flag=0 THEN spawn three blue AAA AND set flag 100=1.

And now this is cyclic.

 

You see, the condition needed for changing the airport control is to destroy the units. The flag value just tell us which coalition will be spawned there. Is like a switch. Flag values could be.... flag "coalition" and value "blue" or "red", instead of flag 100, and 1 and 0 but the ME doesn't accept words.

 

 

You could probably do this by a simple script but i dont know how to program... just some very basic things... so....

 

Search Mist script and read the manual.... and the DCS Mission Editor manual. It helps.

 

Does this make it infinite? And cant i use lua?

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...