Difference between revisions of "hintC"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Command Group)
m (Text replacement - "|version6= 0.50 " to "|version6= 0.50 ")
 
(17 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Command
+
{{RV|type=command
  
 
|game1= ofp
 
|game1= ofp
  
 
|version1= 1.00
 
|version1= 1.00
 +
 +
|game2= arma1
 +
 +
|version2= 1.00
 +
 +
|game3= arma2
 +
 +
|version3= 1.00
 +
 +
|game4= arma2oa
 +
 +
|version4= 1.51
 +
 +
|game5= tkoh
 +
 +
|version5= 1.00
 +
 +
|game6= arma3
 +
 +
|version6= 0.50
  
 
|eff= local
 
|eff= local
  
|gr1= Interaction |GROUP1=
+
|gr1= Interaction
  
|gr2= Structured Text |GROUP2=
+
|gr2= Structured Text
  
|gr3= Strings |GROUP3=
+
|gr3= Strings
  
 
|descr= Displays attractive hint in the center of the screen. Player control is taken away until "Continue" is pressed.
 
|descr= Displays attractive hint in the center of the screen. Player control is taken away until "Continue" is pressed.
  
{{Informative | In Singleplayer, the game is paused as well.}}
+
{{Feature | Informative | In Singleplayer, the game is paused as well.}}
  
 
After user confirmation, the content of the [[hintC]] is repeated again in a normal [[hint]]. This type of hint can also have a title. It is also possible to drag this type of hint around the screen.
 
After user confirmation, the content of the [[hintC]] is repeated again in a normal [[hint]]. This type of hint can also have a title. It is also possible to drag this type of hint around the screen.
 
  
 
|s1= [[hintC]] content
 
|s1= [[hintC]] content
Line 25: Line 44:
  
 
|r1= [[Nothing]]
 
|r1= [[Nothing]]
 
  
 
|s2= title [[hintC]] content
 
|s2= title [[hintC]] content
Line 33: Line 51:
  
 
|r2= [[Nothing]]
 
|r2= [[Nothing]]
 
  
 
|x1 = <code>[[hintC]] "Press W to move forward";</code>
 
|x1 = <code>[[hintC]] "Press W to move forward";</code>
Line 52: Line 69:
 
"Use the mouse to turn right or left.",
 
"Use the mouse to turn right or left.",
 
"Press V for weapon sights."
 
"Press V for weapon sights."
];</code> |EXAMPLE3=
+
];</code>
  
 
|x4= Same as the above in {{arma3}} but without second [[hint]] displayed: <code>"Instructions" [[hintC]] [
 
|x4= Same as the above in {{arma3}} but without second [[hint]] displayed: <code>"Instructions" [[hintC]] [
Line 77: Line 94:
 
}}
 
}}
  
<h3 style="display:none">Notes</h3>
 
 
<dl class="command_description">
 
<dl class="command_description">
 
<!-- Note Section BEGIN -->
 
<!-- Note Section BEGIN -->
  
 
<dd class="notedate">
 
<dd class="notedate">
<dt class="note">[[User:Str|Str]]
+
<dt class="note">[[User:Str|Str]]</dt>
 
<dd class="note">This command must be executed after mission start. If you place it into init.sqs or init field of some unit, it will not work. Just add a little delay (~0.001) and the place the command.
 
<dd class="note">This command must be executed after mission start. If you place it into init.sqs or init field of some unit, it will not work. Just add a little delay (~0.001) and the place the command.
  
 
<dd class="notedate">
 
<dd class="notedate">
<dt class="note">[[User:Worldeater|Worldeater]]
+
<dt class="note">[[User:Worldeater|Worldeater]]</dt>
 
<dd class="note">To display multiple messages after another you have to add a small delay in between. Otherwise only the first message will be displayed.
 
<dd class="note">To display multiple messages after another you have to add a small delay in between. Otherwise only the first message will be displayed.
 
<code>[[hintC]] "foo"; [[sleep]] 0.1; [[hintC]] "bar"</code>
 
<code>[[hintC]] "foo"; [[sleep]] 0.1; [[hintC]] "bar"</code>
Line 92: Line 108:
  
 
<dd class="notedate">
 
<dd class="notedate">
<dt class="note">[[User:ArmAtec|ArmAtec]]
+
<dt class="note">[[User:ArmAtec|ArmAtec]]</dt>
 
<dd class="note">HintC can be used with formatting like this: <code>[[hintC]] [[format]] ["Hello %1", [[player]]]</code>
 
<dd class="note">HintC can be used with formatting like this: <code>[[hintC]] [[format]] ["Hello %1", [[player]]]</code>
  
Line 102: Line 118:
 
</dl>
 
</dl>
  
<h3 style="display:none">Bottom Section</h3>
 
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.46|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.46|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.96|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.96|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands OFP 1.99|Scripting Commands OFP 1.99]]
 
[[Category:Scripting Commands OFP 1.99|Scripting Commands OFP 1.99]]
[[Category:Scripting Commands Armed Assault|{{uc:{{PAGENAME}}}}]]
+
{{GameCategory|arma1|Scripting Commands}}
[[Category:Scripting Commands Arma 2|{{uc:{{PAGENAME}}}}]]
+
{{GameCategory|arma2|Scripting Commands}}
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
+
{{GameCategory|arma3|Scripting Commands}}
[[Category:Scripting Commands Take On Helicopters|{{uc:{{PAGENAME}}}}]]
+
{{GameCategory|tkoh|Scripting Commands}}
[[Category:Command_Group:_Interaction|{{uc:{{PAGENAME}}}}]]
 

Latest revision as of 18:12, 1 March 2021

Hover & click on the images for descriptions

Description

Description:
Displays attractive hint in the center of the screen. Player control is taken away until "Continue" is pressed.
In Singleplayer, the game is paused as well.
After user confirmation, the content of the hintC is repeated again in a normal hint. This type of hint can also have a title. It is also possible to drag this type of hint around the screen.

Syntax

Syntax:
hintC content
Parameters:
content: String
Return Value:
Nothing

Alternative Syntax

Syntax:
title hintC content
Parameters:
title: String - message title
content: String, Structured Text, Array of Strings or Array of Structured Text
Return Value:
Nothing

Examples

Example 1:
hintC "Press W to move forward";
Example 2:
Same as the above in Arma 3 but without second hint displayed:hintC "Press W to move forward"; hintC_EH = findDisplay 57 displayAddEventHandler ["unload", { 0 = _this spawn { _this select 0 displayRemoveEventHandler ["unload", hintC_EH]; hintSilent ""; }; }]; HintC.jpg
Example 3:
"Instructions" hintC [ "Press W to move forward.", "Press S to move backwards.", "Use the mouse to turn right or left.", "Press V for weapon sights." ];
Example 4:
Same as the above in Arma 3 but without second hint displayed: "Instructions" hintC [ "Press W to move forward.", "Press S to move backwards.", "Use the mouse to turn right or left.", "Press V for weapon sights." ]; hintC_arr_EH = findDisplay 72 displayAddEventHandler ["unload", { 0 = _this spawn { _this select 0 displayRemoveEventHandler ["unload", hintC_arr_EH]; hintSilent ""; }; }]; HintC array.jpg
Example 5:
private _separator1 = parseText "<br />------------------------<br />"; private _image = "\ca\ui\textures\aus_flag.paa"; private _txt = composeText [image _image, "Heading Text", _separator1, "Content"]; "" hintC _txt;

Additional Information

See also:
hinthintCadethintSilent
Groups:
InteractionStructured TextStrings

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
Str
This command must be executed after mission start. If you place it into init.sqs or init field of some unit, it will not work. Just add a little delay (~0.001) and the place the command.
Worldeater
To display multiple messages after another you have to add a small delay in between. Otherwise only the first message will be displayed. hintC "foo"; sleep 0.1; hintC "bar" Without a sleep statement hintC will not suspend the script it has been called from.
ArmAtec
HintC can be used with formatting like this: hintC format ["Hello %1", player]
Posted on March 19, 2015 - 09:52 (UTC)
Killzone Kid
"Titled" hintC uses display #72 while "untitled" one uses display #57. If you are trying examples in Arma 3 debug console, add a little delay like this: [] spawn {sleep 0.5; /* your example code goes here*/ }; or no hintC will be displayed.