Jump to content
Sign in to follow this  
hellstorm77

Need help with editing

Recommended Posts

i have started making a mission on the editor. I have placed a red solid marker to show where there enemies are i.e an AO how would i go about making the red solid marker go away after all the OPFOR are dead

Share this post


Link to post
Share on other sites

Give the marker a name, eg. opfor_area. Create a trigger that covers the same area. Set it to OPFOR, NOT_PRESENT. In the activation field (on act: ) you write:

deleteMarker "opfor_area";

Share this post


Link to post
Share on other sites

thanks Muzzleflash

I have placed a D-30 on the map. what i want to happen is when US or BAF enter into a trigger zone the D-30 opens fire from long range onto the triggered area. so arty comes raining down

Share this post


Link to post
Share on other sites

i had a look at the link posted it didn't really help me. what i want to happen instead of a radio trigger is i place a D-30 on the map what is opfor (enemy) and if blufor (friendly) goes in to the area it fires onto them. The mission is to blow the arty you with demo from blufor get to the trigger but if they dont complete the side mission first they will get arty rounds onto them

Share this post


Link to post
Share on other sites

Okay. Are you going for total realism? You could instead simulate arty rounds by creating the arty rounds themselves, or even gbu bombs, out of thin air. Spawning the bombs/arty on editor placed markers or objects. Or maybe by using some random function.

Or, i've never tried this with artillery, but maybe placing the arty far away and using dotarget and doFire commands to get them to fire upon an "invisible" target(s)?

Share this post


Link to post
Share on other sites

it would of been nice to have some realism to the arty and the joint mission im trying to make

Share this post


Link to post
Share on other sites

Set the trigger to touch off when BLUFOR enters it, this can be done in editor, it's a simple thing, you don't need a script for that. What you need a script for is fireing the artillery.

Put in the "on act." field something like this:

Code:

_trigger = 1;

_x = 1;

while {_trigger == 1} do

{

if (_x == 1) then

{

artUnit doTarget yourArtTarget;

sleep 5;

}

artUnit doFire yourArtTarget;

_x =+ 1;

sleep 1;

if (_x==45) then {_trigger = 0};

}

Im a total noob when it comes to scripts this is my first mission i have made where would i put this script?

Share this post


Link to post
Share on other sites

Download the mission in the thread and have a look at it in the editor. It works with a radio trigger.... but is easy to change to a normal trigger. It will take some work on your part.

Share this post


Link to post
Share on other sites
thanks twirly i got it to work :)

do you know how can i hide a destroy marker?

You mean like deleting a marker on the map? Or making an invisible marker? I'm only asking because idk what you mean by "destroy marker".

to delete a marker off of the map use deleteMarker "markername" - To place an invisible marker use an empty marker. To hide a marker use "markerName" setMarkerAlpha 0

Share this post


Link to post
Share on other sites

how would i go about adding parameters to my mission. What im trying to do is add a parameter to section screen where i can set up the mission for day or night

Share this post


Link to post
Share on other sites
how would i go about adding parameters to my mission. What im trying to do is add a parameter to section screen where i can set up the mission for day or night

Firstly, you need to define the parameters in your description.ext file. See here. Once defined, you can access these values from mission scripts via the paramsArray variable.

For example, you could add a parameter like this, enabling the selection of various times:

class Params
{
 class StartTime
 {
   title = "Mission start";
   values[] = {0,6,12,18,21};
   texts[] = {"Midnight","6 AM","Noon","6PM","9 PM"};
   default = 12;
 };
}

Then use the value in a script upon initialization of the mission, like this:

setDate [2012, 12, 25, paramsArray select 0, 0];

See the setDate command on the Biki.

Share this post


Link to post
Share on other sites
Firstly, you need to define the parameters in your description.ext file. See here. Once defined, you can access these values from mission scripts via the paramsArray variable.

For example, you could add a parameter like this, enabling the selection of various times:

class Params
{
 class StartTime
 {
   title = "Mission start";
   values[] = {0,6,12,18,21};
   texts[] = {"Midnight","6 AM","Noon","6PM","9 PM"};
   default = 12;
 };
}

Then use the value in a script upon initialization of the mission, like this:

setDate [2012, 12, 25, paramsArray select 0, 0];

See the setDate command on the Biki.

if i wanted to add more times of the day would all i need to do is this?

values[] = {0,1,2,3,4,5,6,7.8.9.10,11,12,13,14,15,16,17,18,19,20,21,22,23,}; just like this?

would i also need to change anything else to the other scripts?

well apart from this one texts[] = {"Midnight","6 AM","Noon","6PM","9 PM"}; i would have too..

Edited by hellstorm77

Share this post


Link to post
Share on other sites

No...as long as you have enough texts[] to match the values[].

paramsarray select 0 will be the value.

Share this post


Link to post
Share on other sites

How would i got about making 2 respawn points on the map? i have make a respawn point for the US at an airfield now i want to do the some for the BAF but at a different place on the map

Share this post


Link to post
Share on other sites
How would i got about making 2 respawn points on the map? i have make a respawn point for the US at an airfield now i want to do the some for the BAF but at a different place on the map

Unless I am completely mistaken, there is no built-in way to give different units (on the same side) a different respawn location. You will need to use setPos to move the BAF units to their separate location after they have respawned. (You can use addMPEventHandler with the MPRespawn event for this.)

Share this post


Link to post
Share on other sites

i just had a look at addMPEventHandler and MPRespawn just blow my mind lol I'm a total noob this is my first ever mission im trying to make

Share this post


Link to post
Share on other sites

Some how im getting an error when i use this can someone help me if its right

setDate [2012, 8, 3, paramsArray select 0, 0];

class Params
{
 class StartTime
 {
   title = "Mission start";
   values[] = {0,4,6,10,12,16,18,22};
   texts[] = {"Midnight","4 AM","6 AM","10 AM","NOON","4 PM","6 PM","10 PM"};
   default = 12;
 };
}

Share this post


Link to post
Share on other sites

What's the error?

It looks OK....don't see anything wrong really. Maybe brackets around paramsArray select 0 but don't think it's necessary. But if all else fails... try everything you didn't try!

Just to check... the Class params statements needs to be in your description.ext... and put the setDate in your init.sqf

Share this post


Link to post
Share on other sites
What's the error?

It looks OK....don't see anything wrong really. Maybe brackets around paramsArray select 0 but don't think it's necessary. But if all else fails... try everything you didn't try!

Just to check... the Class params statements needs to be in your description.ext... and put the setDate in your init.sqf

i put everything in the right place as told to. i didnt try the brackets. I will have to try that one. this is the error i was getting

Error position: <setDate [2012, 8, 3, paramsArray select >

Error Missing ;

Share this post


Link to post
Share on other sites

Look at the lines directly above the error and make sure there's nothing wrong there.

Share this post


Link to post
Share on other sites

this is the line above the error titleText ["Silence The Guns By Hellstorm77\n\nVersion 1", "BLACK FADED", 0.4];

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×