Forum Jump :

Author Message


Posts: 17
Rank:


Level: Member

Country: us
Location: US of A
Occupation:
Age: 28
In-game name: Kasuka

 
#1 Posted at 2011-05-09 05:36        
     
Okay. So I've seen a certain way to create this script. Since to my knowledge the init.sqf is what makes the briefing you've created pop up before the mission begins.

This is a script I've seen for doing so.

//begin init.sqf
//Add briefing
execVM "briefing.sqf";

if(true) exitWith []; 

Which I guess does not seem to work. I've looked around and can't seem to figure out how to do this. So if any one can post how exactly to make this script I'd appreciate it.

This post was edited by DarkXess (2011-05-09 08:23, ago)


Author Message

palyarmerc  

I live inside the editor


Posts: 753
Rank:


Level: Member

Country: uk
Location:
Occupation: *Retired from ArmA*
Age:
In-game name: Paly

 
#2 Posted at 2011-05-09 07:28        
     
By far the easiest way to learn any scripting is to pick apart a working mission
You forgot the array brackets,

[] execVM "briefing.sqf";

you don't really need the if (true) exitwith []; the script will end and exit automatically
If that doesn't work try

null=[] execVM "briefing.sqf";

or

CheckVM =[] execVM "briefing.sqf";

I also have a briefing.html, this allows the mission title to show on the load screen (for some reason)

This post was edited by DarkXess (2011-05-09 08:24, ago)

....that's all folks....!

Advertisement


Author Message


Posts: 17
Rank:


Level: Member

Country: us
Location: US of A
Occupation:
Age: 28
In-game name: Kasuka

 
#3 Posted at 2011-05-09 23:05        
     
# palyarmerc : By far the easiest way to learn any scripting is to pick apart a working mission
You forgot the array brackets,

[] execVM "briefing.sqf";

you don't really need the if (true) exitwith []; the script will end and exit automatically
If that doesn't work try

null=[] execVM "briefing.sqf";

or

CheckVM =[] execVM "briefing.sqf";

I also have a briefing.html, this allows the mission title to show on the load screen (for some reason)

Added 4 minutes later:

Okay. So I've tried all of those. I still can't get it to work. I've seen many ways and I can't get it to work.

Seen just plain

execVM "Briefing.sqf"

and

_nul = [] execVM "Briefing.sqf"

I still cannot get the briefing to come up before the mission starts. Is there some difference between Arma2 and OA?


Author Message

palyarmerc  

I live inside the editor


Posts: 753
Rank:


Level: Member

Country: uk
Location:
Occupation: *Retired from ArmA*
Age:
In-game name: Paly

 
#4 Posted at 2011-05-09 23:30        
     
Well, to begin with use this and this only...

CheckVM =[] execVM "briefing.sqf";

then grab a working briefing.sqf from another mission and check to see it loads...I'll wager there's an error in your briefing.sqf.
A missing " or [ or a < in the wrong place ?

Sometimes I've had it where the briefing and tasks only show after mission starts - is it loading at all?

....that's all folks....!

Author Message


Posts: 17
Rank:


Level: Member

Country: us
Location: US of A
Occupation:
Age: 28
In-game name: Kasuka

 
#5 Posted at 2011-05-10 00:06        
     
My briefing works. It just does not load before the mission. I do not know why. I've tried the CheckVM = [] execVM "briefing.sqf" still won't work.


Author Message

palyarmerc  

I live inside the editor


Posts: 753
Rank:


Level: Member

Country: uk
Location:
Occupation: *Retired from ArmA*
Age:
In-game name: Paly

 
#6 Posted at 2011-05-10 06:31        
     
Yeah, it's an odd one. I never did work out why some briefings don't show until you are in the map.
But, from what you are saying it works though, so you know that the [] execVM "" is not the problem

So, your question to continue this thread correctly (and which I cannot help you with, sorry) is

what makes the briefing you've created pop up before the mission begins?

....that's all folks....!

Author Message


Posts: 17
Rank:


Level: Member

Country: us
Location: US of A
Occupation:
Age: 28
In-game name: Kasuka

 
#7 Posted at 2011-05-10 18:02        
     
I got it working. Seems if you put a briefing.html in the mission folder then it works fine every time. You just hold left-shift before hitting preview in the editor. Then it loads up the briefing itself in SP or MP. Thanks for your help though.