ropeLength: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <dl class="command_description"> </dl>" to "")
m (Text replacement - "Samatra" to "Sa-Matra")
 
(31 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{RV|type=command
{{RV|type=command


| arma3
|game1= arma3
|version1= 1.34


|1.34
|gr1= Ropes and Sling Loading


|gr1= Ropes and Sling Loading
|descr= Return rope length in meters (set by [[ropeCreate]], [[ropeCut]], [[ropeUnwind]]).
{{Feature|informative|Returned rope length will remain the same, even if the rope is stretched.}}


| Return rope length in meters (set by [[ropeCreate]], [[ropeCut]], [[ropeUnwind]]).
|s1= [[ropeLength]] rope
{{Informative|Returned rope length will remain the same, even if the rope is stretched.}}


| [[ropeLength]] rope
|p1= rope: [[Object]]


|p1 = rope: [[Object]]
|r1= [[Number]]


| [[Number]]
|x1= <sqf>_length = ropeLength (ropes heli1 select 0);</sqf>
|x1 = <code>_length = [[ropeLength]] ([[ropes]] heli1 [[select]] 0);</code>


| [[ropes]], [[canSlingLoad]], [[enableRopeAttach]], [[getSlingLoad]], [[ropeAttachedObjects]], [[ropeAttachTo]], [[ropeDestroy]], [[ropeUnwound]], [[ropeAttachedTo]], [[ropeCreate]], [[ropeDetach]], [[ropeAttachEnabled]], [[ropeCut]], [[ropeEndPosition]], [[ropeUnwind]], [[setSlingLoad]], [[slingLoadAssistantShown]]
|seealso= [[ropes]] [[canSlingLoad]] [[enableRopeAttach]] [[getSlingLoad]] [[ropeAttachedObjects]] [[ropeAttachTo]] [[ropeDestroy]] [[ropeUnwound]] [[ropeAttachedTo]] [[ropeCreate]] [[ropeDetach]] [[ropeAttachEnabled]] [[ropeCut]] [[ropeEndPosition]] [[ropeUnwind]] [[setSlingLoad]] [[slingLoadAssistantShown]]
}}
}}


{{GameCategory|arma3|Scripting Commands}}
{{Note
|user= Sa-Matra
|timestamp= 20240608044002
|text= Returns 0 for [[ropeSegments|rope segments]]. To get length of individual segment, do <sqf inline>vectorMagnitude vectorUpVisual _segment * 0.3</sqf>. 0.3 is model height of <sqf inline>RopeSegment</sqf>, you can calculate it using [[boundingBox]] for other rope types.
}}

Latest revision as of 20:58, 4 July 2024

Hover & click on the images for description

Description

Description:
Return rope length in meters (set by ropeCreate, ropeCut, ropeUnwind).
Returned rope length will remain the same, even if the rope is stretched.
Groups:
Ropes and Sling Loading

Syntax

Syntax:
ropeLength rope
Parameters:
rope: Object
Return Value:
Number

Examples

Example 1:
_length = ropeLength (ropes heli1 select 0);

Additional Information

See also:
ropes canSlingLoad enableRopeAttach getSlingLoad ropeAttachedObjects ropeAttachTo ropeDestroy ropeUnwound ropeAttachedTo ropeCreate ropeDetach ropeAttachEnabled ropeCut ropeEndPosition ropeUnwind setSlingLoad slingLoadAssistantShown

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
Sa-Matra - c
Posted on Jun 08, 2024 - 04:40 (UTC)
Returns 0 for rope segments. To get length of individual segment, do vectorMagnitude vectorUpVisual _segment * 0.3. 0.3 is model height of RopeSegment, you can calculate it using boundingBox for other rope types.