hostMission: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "|= Comments" to "|Comments=")
m (Text replacement - "<sqf>([^↵][^\/]*↵[^\/]*)<\/sqf>" to "<sqf> $1 </sqf>")
 
(46 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{Command|Comments=
{{RV|type=command
____________________________________________________________________________________________


| arma2oa |Game name=
|game1= arma2oa
|version1= 1.55


|1.55|= Game version
|game2= tkoh
____________________________________________________________________________________________
|version2= 1.00


| Host the mp mission described by config class. Should be called as reaction to some UI action in some dialog.
|game3= arma3
|version3= 0.50


For example you can start a MP scenario from a button. It creates a host and takes you to the lobby with the scenario loaded.
|gr1= Multiplayer


You need to provide the display which is active when the hostMission command is called. |DESCRIPTION=
|descr= Host the multiplayer mission defined in the config class and opens the lobby with the scenario loaded. Must be called in UI action from a dialog.
____________________________________________________________________________________________


| '''hostMission''' [pConfig, pDisplay] |SYNTAX=
|s1= [[hostMission]] [configEntry, activeDisplay]


|p1= [pConfig, pDisplay]: [[Array]] |=
|p1= configEntry: [[Config]]
|p2= pConfig: [[Config]] |=
|p3= pDisplay: [[Display]] |=


| [[Nothing]] |RETURNVALUE=
|p2= activeDisplay: [[Display]]
____________________________________________________________________________________________


|x1= <code>'''hostMission''' [configMissionName, display];</code> |=
|r1= [[Nothing]]


|x2= <code>[[hostMission]] <nowiki>[</nowiki>[[configFile]]/"CfgMissions"/"MPMissions"/_scenarioClassName, _currentlyActiveDisplay];</code> |=
|x1= <sqf>hostMission [configFile >> "CfgMissions" >> "MPMissions" >> _scenarioClassName, _currentlyActiveDisplay];</sqf>


|x3= Launch host mission dialog in Arma 3 from a client on dedicated server<code>[[hostMission]] [
|x2= Launch host mission dialog from a client on dedicated server in {{arma3}}:
[[configFile]] >> "CfgMissions" >> "MPmissions" >> "MP_COOP_m01",
<sqf>
[[findDisplay]] 46
hostMission [
];</code> |=
configFile >> "CfgMissions" >> "MPmissions" >> "MP_COOP_m01",
____________________________________________________________________________________________
findDisplay 46
];
</sqf>


| [[playScriptedMission]], [[playMission]] |SEEALSO=
|seealso= [[playScriptedMission]] [[playMission]] [[createMPCampaignDisplay]] [[createMissionDisplay]]
}}
}}


<h3 style="display:none">Notes</h3>
{{Note
<dl class="command_description">
|user= .kju
<!-- Note Section BEGIN -->
|timestamp= 20110103165100
 
|text= The command must be called in the main menu or something similar menu it seems.
 
}}
<dd class="notedate">Posted on January 03, 2011
<dt class="note">'''[[User:kju|kju]]'''<dd class="note">
The command must be called in the main menu or something similar menu it seems.
 
 
<!-- Note Section END -->
</dl>
 
<h3 style="display:none">Bottom Section</h3>
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands ArmA2|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting_Commands_Take_On_Helicopters|{{uc:{{PAGENAME}}}}]]
[[Category:ArmA 2 OA: New Scripting Commands List|{{uc:{{PAGENAME}}}}]]
[[Category:Command_Group:_Multiplayer|{{uc:{{PAGENAME}}}}]]

Latest revision as of 11:34, 3 September 2024

Hover & click on the images for description

Description

Description:
Host the multiplayer mission defined in the config class and opens the lobby with the scenario loaded. Must be called in UI action from a dialog.
Groups:
Multiplayer

Syntax

Syntax:
hostMission [configEntry, activeDisplay]
Parameters:
configEntry: Config
activeDisplay: Display
Return Value:
Nothing

Examples

Example 1:
hostMission [configFile >> "CfgMissions" >> "MPMissions" >> _scenarioClassName, _currentlyActiveDisplay];
Example 2:
Launch host mission dialog from a client on dedicated server in Arma 3:
hostMission [ configFile >> "CfgMissions" >> "MPmissions" >> "MP_COOP_m01", findDisplay 46 ];

Additional Information

See also:
playScriptedMission playMission createMPCampaignDisplay createMissionDisplay

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note
.kju - c
Posted on Jan 03, 2011 - 16:51 (UTC)
The command must be called in the main menu or something similar menu it seems.