kbTell: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "<code>([^ ]*)\[\[([a-zA-Z][a-zA-Z0-9_]+)\]\]([^ ]*)<\/code>" to "<code>$1$2$3</code>") |
Lou Montana (talk | contribs) m (Text replacement - "\{\{cc\|([^} ]*)\}\}" to "// $1") |
||
Line 47: | Line 47: | ||
|x2= <code>[[player]] [[kbTell]] [ | |x2= <code>[[player]] [[kbTell]] [ | ||
BIS_HQ, | BIS_HQ, // to | ||
"Airstrike", | "Airstrike", // topic | ||
"AirstrikeRequest", | "AirstrikeRequest", // sentence | ||
["Team", {}, "Anvil", ["Anvil"]], | ["Team", {}, "Anvil", ["Anvil"]], // argument 1 | ||
["Location", {}, "Strelka", ["Strelka"]], | ["Location", {}, "Strelka", ["Strelka"]], // argument 2 | ||
true]; | true]; // use radio</code> | ||
in given .bikb: | in given .bikb: | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
Line 68: | Line 68: | ||
|x3= <code>[[player]] [[kbTell]] [ | |x3= <code>[[player]] [[kbTell]] [ | ||
BIS_HQ, | BIS_HQ, // to | ||
"Airstrike", | "Airstrike", // topic | ||
"AirstrikeRequest", | "AirstrikeRequest", // sentence | ||
["argumentName", argumentValue], | ["argumentName", argumentValue], // argument 1 | ||
true]; | true]; // use radio</code> | ||
|r1= [[Nothing]] | |r1= [[Nothing]] |
Revision as of 11:26, 12 May 2022
Description
- Description:
- Make the person tell to the receiver the sentence. See Conversations for more details.
- Problems:
- Two units cannot talk on the same channel at the same time, this can lead to weird effects for non-local listeners; make sure not to use the same channel at the same time in multiplayer. Custom channels are considered as one channel for this matter.
- Groups:
- Conversations
Syntax
- Syntax:
- person kbTell [receiver, topicName, sentenceClass, argumentArray1, argumentArray2, (…), forceRadio]
- Parameters:
- person: Object
- receiver: Object
- topicName: String
- sentenceClass: String
- argumentArray1toN: Array - (Optional) format [argumentName, argumentValue, argumentText, argumentSpeech]:
- forceRadio: Boolean, Number or String (last value of the array) - (Optional)
- Return Value:
- Nothing
Examples
- Example 1:
player kbTell [BIS_HQ, "myTopic", "playerSentence1"];
- Example 2:
player kbTell [ BIS_HQ, // to "Airstrike", // topic "AirstrikeRequest", // sentence ["Team", {}, "Anvil", ["Anvil"]], // argument 1 ["Location", {}, "Strelka", ["Strelka"]], // argument 2 true]; // use radio
in given .bikb:class AirstrikeRequest { text = "%team requesting close air support at grid %location "; speech[] = { %Team, RequestingCloseAirSupportAtGrid, %Location }; class Arguments { class Team { type = "simple"; }; class Location { type = "simple"; }; }; };
- Example 3:
player kbTell [
BIS_HQ, // to "Airstrike", // topic "AirstrikeRequest", // sentence ["argumentName", argumentValue], // argument 1
true]; // use radio
Additional Information
- See also:
- Conversations kbAddTopic kbHasTopic kbReact kbRemoveTopic kbAddDatabase kbAddDatabaseTargets FSM FSM Editor
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