BIS fnc target: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "BIS fnc " to "BIS_fnc_") |
Lou Montana (talk | contribs) m (Some wiki formatting) |
||
Line 9: | Line 9: | ||
Handles the shooting targets in the Bootcamp DLC, statistics, animation, etc. (targets such as {{hl|TargetBootcampHuman_f}}) | Handles the shooting targets in the Bootcamp DLC, statistics, animation, etc. (targets such as {{hl|TargetBootcampHuman_f}}) | ||
{{{!}} class="wikitable mw-collapsible mw-collapsed" style="min-width: 50em" | |||
{{!}}+ Action/Parameter Table | |||
! Action ([[String]]) | |||
! Parameters ([[Array]]) arguments | |||
{{{!}} class="wikitable" | |||
! Action [[String]] | |||
{{!}}- | {{!}}- | ||
{{!}} '''initialize'''<br>Initializes the target and sets it to the "up" position | {{!}} '''initialize'''<br>Initializes the target and sets it to the "up" position | ||
Line 179: | Line 174: | ||
{{!}}} | {{!}}} | ||
|r1= See [[# | |s1= [action, parameters] call [[BIS_fnc_target]] | ||
|p1= action: [[String]] | |||
|p2= parameters: [[Array]] | |||
|r1= See [[#Description|above table]] | |||
|x1= <sqf> | |x1= <sqf> |
Latest revision as of 11:27, 13 January 2023
Description
- Description:
-
Handles the shooting targets in the Bootcamp DLC, statistics, animation, etc. (targets such as TargetBootcampHuman_f)
Action/Parameter Table Action (String) Parameters (Array) arguments initialize
Initializes the target and sets it to the "up" position- target: Object - Target object of type "TargetBootcamp_base_F"
terminate
Doesn't do anythingN/A animate
Animate the object to the given position ("up" or "down")getAnimationPhase
Return Value: Number - 0 (up) or 1 (down) depending on current state- target: Object - Target object of type "TargetBootcamp_base_F"
getAnimationPhaseString
Return Value: String - "up" or "down" depending on current state- target: Object - Target object of type "TargetBootcamp_base_F"
getAnimatedSelection
Return Value: String - the name of the "animatedSelection" from object config- target: Object - Target object of type "TargetBootcamp_base_F"
hit
Handles the hit event to animate the target down and up againhitPart
Handles the hit event and stores the data- partsList: Array - Contains list of all parts which got hit (see HitPart EH format) to format [target, shooter]:
getShooterDataIndex
Return Value: Number - index from Shooter Data for specific unitgetShooterData
Return Value: Array - all data from Shooter Data for specific unit
Format: [["uid", ""], ["name", ""], ["shots", [[["time", 0], ["distance", 0], ["weapon", ""], ["direct", 0]]]]]
setShooterData
Set Shooter Data for specific unitgetShotsData
Return Value: Array - Shots Data for specific unitgetShotsDataFromTargets
Return Value: Number - total amount of shots hitgetShotsDataWithFilter
Return Value: Array - Shot Data after custom filtersetShotsData
Set Shots Data for specific unitgetShootersData
Return Value: Array - full Shooters Data- target: Object - Target object of type "TargetBootcamp_base_F"
setShootersData
Set full Shooters DataresetShootersData
Remove all data from Shooters Data array- target: Object - Target object of type "TargetBootcamp_base_F"
getShooterTemplate
Return Value: Array - template for Shooter DatagetShotTemplate
Return Value: Array - template for Shot Data (see HitPart EH format)- target: Object - Target object of type "TargetBootcamp_base_F"
- shooter: Object - Unit who shot the target
- projectile: Object - ("_bullet" not used)
- position: Array format Position - ("_position" not used)
- velocity: Array - ("_velocity" not used)
- selection: Array - ("_selection" not used)
- ammo: Array - ("_ammo" not used)
- vector: Array - ("_direction" not used)
- radius: Array - ("_radius" not used)
- surfaceType: String - ("_surface" not used)
- isDirect: Boolean - true if object was directly hit, false if it was hit by indirect/splash damage.
getShooterByUid
Return Value: Object - corresponding shooter unit- uid: String - Player UID of unit who shot the target
uiOpen
Opens the Target Board display- target: Object - Target object of type "TargetBootcamp_base_F"
uiOpenToAll
Opens the Target Board display for all connected players- target: Object - Target object of type "TargetBootcamp_base_F"
uiOnLoad
Triggered when display is opened (internal)- display: Display
uiFillTable
Triggered when display is opened, fills UI with Shooters Data (internal)uiFillTableRow
Triggered when display is opened, fills UI with Shooter Data (internal) - Execution:
- call
- Groups:
- Interaction
Syntax
- Syntax:
- [action, parameters] call BIS_fnc_target
- Parameters:
- action: String
- parameters: Array
- Return Value:
- See above table
Examples
- Example 1:
- Example 2:
- Example 3:
Additional Information
- See also:
- doTarget
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