BIS fnc kbTell: Difference between revisions
Jump to navigation
Jump to search
Tag: Undo |
Lou Montana (talk | contribs) (Add soundVolume default values) |
||
(36 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{RV|type=function | {{RV|type=function | ||
| tkoh | |game1= tkoh | ||
|version1= 1.00 | |||
| | |game2= arma3 | ||
|version2= 0.50 | |||
|arg= | |arg= global | ||
|eff= | |eff= global | ||
|gr1 = Conversations | |gr1= Conversations | ||
| Play given sentence/conversation. Script terminates itself when conversation is finished.<br> | |exec= spawn | ||
|descr= Play given sentence/conversation. Script terminates itself when conversation is finished.<br> | |||
Conversation must be declared in [[Description.ext#CfgSentences|Description.ext/CfgSentences]]. | Conversation must be declared in [[Description.ext#CfgSentences|Description.ext/CfgSentences]]. | ||
{{ | {{Feature|informative|This function can also be executed with [[call]]. Doing so will make it internally [[spawn]] since it needs to be able suspend its execution.}} | ||
| [topic, container, section, radioMode, code, speakers, soundVolume, radioProtocol] spawn [[BIS_fnc_kbTell]] | |s1= [topic, container, section, radioMode, code, speakers, soundVolume, radioProtocol] spawn [[BIS_fnc_kbTell]] | ||
|p1= topic: [[String]] - topic name | |p1= topic: [[String]] - topic name | ||
Line 34: | Line 38: | ||
|p4= radioMode: [[Boolean]], [[String]], [[Object]] or [[Code]] - (Optional, default: [[false]]) can be: | |p4= radioMode: [[Boolean]], [[String]], [[Object]] or [[Code]] - (Optional, default: [[false]]) can be: | ||
* [[Boolean]] - true to force radio | * [[Boolean]] - true to force radio | ||
* [[String]] - name of radio channel | * [[String]] - name of radio channel ("DIRECT" or "VEHICLE") or [[radioChannelCreate|custom]] | ||
* [[Object]] - listener's channel | * [[Object]] - listener's channel | ||
* [[Code]] - returned value of code | * [[Code]] - returned value of code | ||
|p5= code: [[Code]] or [[Array]] - (Optional, default { | |p5= code: [[Code]] or [[Array]] - (Optional, default <sqf inline>{ true }</sqf>) can be: | ||
* [[Code]] - executed at the start of every sentence (arguments are same as in kbAddTopic event handler) | * [[Code]] - executed at the start of every sentence (arguments are same as in kbAddTopic event handler) | ||
* [[Array]] - code with arguments in format [code, arguments] | * [[Array]] - code with arguments in format [code, arguments] | ||
|p6= speakers: [[Array]] or [[Boolean]] - (Optional, default []) can be: | |p6= speakers: [[Array]] or [[Boolean]] - (Optional, default <sqf inline>[]</sqf>) can be: | ||
* [[Array]] - replacement units for those defined in .bikb file (in chronological order) | * [[Array]] - replacement units for those defined in .bikb file (in chronological order) | ||
* [[Boolean]] - when true, dummy logics will be created for all actor units which doesn't exist (default: false or value of ' | * [[Boolean]] - when true, dummy logics will be created for all actor units which doesn't exist (default: false or value of 'BIS_fnc_kbTell_createDummy' variable) | ||
|p7= soundVolume: [[Number]] - (Optional, default 0.1) music and sound volumes | |p7= soundVolume: [[Number]] - (Optional, default {{GVI|tkoh|1.00|size= 0.75}} 0.2, {{GVI|arma3|1.00|size= 0.75}} -1) music and sound volumes lowering ratio during the conversation, range 0..1 (e.g 0 = no music, 0.25 = a quarter of the current volume, 1 or out of range = no change) | ||
|p8= radioProtocol: [[Boolean]] - (Optional, default [[true]]) true to disable radio protocol message while the conversation is playing | |p8= radioProtocol: [[Boolean]] - (Optional, default [[true]]) true to disable radio protocol message while the conversation is playing | ||
| [[Nothing]] | |r1= [[Nothing]] | ||
| [ | |x1= <sqf>["01_Wave", "A_in", nil, "SIDE", nil, nil, 1, false] spawn BIS_fnc_kbTell;</sqf> | ||
| | |seealso= [[Conversations]] [[kbTell]] [[BIS_fnc_kbCanSpeak]] [[BIS_fnc_kbCreateDummy]] [[BIS_fnc_kbIsSpeaking]] [[BIS_fnc_kbMenu]] [[BIS_fnc_kbPriority]] [[BIS_fnc_kbSentence]] [[BIS_fnc_kbSkip]] [[BIS_fnc_kbTellLocal]] [[BIS_fnc_kbTopicConfig]] | ||
}} | }} | ||
Latest revision as of 00:00, 29 September 2024
Description
- Description:
- Play given sentence/conversation. Script terminates itself when conversation is finished.
Conversation must be declared in Description.ext/CfgSentences. - Execution:
- spawn
- Groups:
- Conversations
Syntax
- Syntax:
- [topic, container, section, radioMode, code, speakers, soundVolume, radioProtocol] spawn BIS_fnc_kbTell
- Parameters:
- topic: String - topic name
- container: String - (Optional, default missionName) container name (CfgSentences sub-category)
- section: Array or String - (Optional, default "") section to be played. Elements can be:
- radioMode: Boolean, String, Object or Code - (Optional, default: false) can be:
- code: Code or Array - (Optional, default { true }) can be:
- speakers: Array or Boolean - (Optional, default []) can be:
- soundVolume: Number - (Optional, default 1.00 0.2, 1.00 -1) music and sound volumes lowering ratio during the conversation, range 0..1 (e.g 0 = no music, 0.25 = a quarter of the current volume, 1 or out of range = no change)
- radioProtocol: Boolean - (Optional, default true) true to disable radio protocol message while the conversation is playing
- Return Value:
- Nothing
Examples
- Example 1:
Additional Information
- See also:
- Conversations kbTell BIS_fnc_kbCanSpeak BIS_fnc_kbCreateDummy BIS_fnc_kbIsSpeaking BIS_fnc_kbMenu BIS_fnc_kbPriority BIS_fnc_kbSentence BIS_fnc_kbSkip BIS_fnc_kbTellLocal BIS_fnc_kbTopicConfig
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