BIS fnc replaceWithSimpleObject: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "<code>(\[[a-zA-Z0-9_, ]*\] )?\[\[(call|spawn)\]\] \[\[(BI[NS]\_fnc\_[a-zA-Z0-9_]+)\]\];?<\/code>" to "<sqf>$1$2 $3;</sqf>")
m (Text replacement - "{{Feature|Informative|" to "{{Feature|informative|")
(3 intermediate revisions by the same user not shown)
Line 8: Line 8:
|descr= Replaces a normal object with a [[Arma 3 Simple Objects|Simple Object]].
|descr= Replaces a normal object with a [[Arma 3 Simple Objects|Simple Object]].
Object must not contain any crew and must be placed on the ground.
Object must not contain any crew and must be placed on the ground.
{{Feature|Informative|
{{Feature|informative|
* Useful if you do not have access to simple object adjustment data - e.g. in case of unsupported/discontinued asset.
* Useful if you do not have access to simple object adjustment data - e.g. in case of unsupported/discontinued asset.
* All official assets have the adjustment data defined in config.}}
* All official assets have the adjustment data defined in config.}}
Line 22: Line 22:
|x1= <sqf>[tank] call BIS_fnc_replaceWithSimpleObject;</sqf>
|x1= <sqf>[tank] call BIS_fnc_replaceWithSimpleObject;</sqf>


|seealso= [[createSimpleObject]], [[BIS_fnc_adjustSimpleObject]], [[BIS_fnc_createSimpleObject]], [[BIS_fnc_simpleObjectData]]
|seealso= [[createSimpleObject]] [[BIS_fnc_adjustSimpleObject]] [[BIS_fnc_createSimpleObject]] [[BIS_fnc_simpleObjectData]]
}}
}}

Revision as of 01:24, 2 February 2024

Hover & click on the images for description

Description

Description:
Replaces a normal object with a Simple Object. Object must not contain any crew and must be placed on the ground.
  • Useful if you do not have access to simple object adjustment data - e.g. in case of unsupported/discontinued asset.
  • All official assets have the adjustment data defined in config.
Execution:
call
Problems:
Use with caution as this technique is not very clean - it should not be used for many objects and definitely not in MP games.
Groups:
Object Manipulation

Syntax

Syntax:
[object] call BIS_fnc_replaceWithSimpleObject
Parameters:
object: Object - the object that will be replaced by a simple object
Return Value:
Object - the created Simple Object

Examples

Example 1:
[tank] call BIS_fnc_replaceWithSimpleObject;

Additional Information

See also:
createSimpleObject BIS_fnc_adjustSimpleObject BIS_fnc_createSimpleObject BIS_fnc_simpleObjectData

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