Fandom

武装突袭 Wiki

BuildingPos

简体 | 繁體

4,827个页面创建
于此维基上
添加新页面
评论0 Share

您使用了广告屏蔽软件!


Wikia通过广告运营为用户提供免费的服务。我们对用户通过嵌入广告屏蔽软件访问网站进行了使用调整。

如果您使用了广告屏蔽软件,将无法使用我们的服务。请您移除广告屏蔽软件,以确保页面正常加载。

Introduced with Operation Flashpoint version 1.00
  Arguments of this scripting command don't have to be local to the client the command is executed on

点击图片可看到更多讯息

开始使用于

游戏:
Operation Flashpoint
版本:
1.00

描述

描述:
Returns PositionAGL of a given indexed position in a building. The index is 0-based (i.e. the first possible position would be 0. So if a building has 5 positions listed in the editor, 4 would be the highest position index usable with this command). Command will return [0,0,0] if buildingPos with given index is non-existent.

Since Arma 3 v.155.133934 if index -1 is supplied, the command will return array with all available positions.

基本句法

句法:
building buildingPos index
参数:
building: Object

index: Number - index of a specific position or -1 to return available all positions
返回值:
Array - a single building position in format PositionAGL or (since Arma 3 v.155.133934) Array of all building positions in format PositionAGLs if index is -1

范例

范例1:
_soldier setPosATL (_house1 buildingPos 2);

范例2:
_allpositions = nearestBuilding player buildingPos -1;

额外资讯

多人游戏:
-
也可以看看:

nearestBuildingnearestObjectnearestObjectsnearObjectsbuildingExitpositionsetPosBIS_fnc_buildingPositions

注意事项

此处撰写句法皆为可行用法. 可到官网[1]专页回报错误. 你可以使用讨论页面或是论坛来进行讨论.
新增注意事项 | 如何新增?

Notes

Posted on August 2, 2006 - 10:45
hardrock
Notes from before the conversion: These examples will move a unit to the 1st position specified in a buildings model, in the second example - bunker1. this move (building buildingPos 1); this move (bunker1 buildingPos 1); In the default game buildings, the buildingPos is usually right behind a window. This can make it easy to place units in the windows of buildings, by putting the unit near a building and putting this in its init field: this setPosATL ((nearestBuilding this) buildingPos 1); The location returned by buildingPos is not reliable after the player has exited and then resumed the mission. For code that is executed immediately after the mission starts there is no problem. If buildingPos locations are to be accessed during the mission when the player may have exited and then resumed, save the locations you require at the start of the mission and use these saved locations in your subsequent scripts.


Posted on January 26, 2007 - 01:02
Kronzky
The highest index is not necessarily the highest position in a building! Check the z-value to find out the absolute height of a position.


Posted on February 16, 2007
Bdfy
(building buildingPos 1) will return [0,0,0] if buildingPos with this index does not exist.


Posted on January 08, 2011
kju
Almost all buildings loose their building positions when they get (visually) damaged or destroyed. Some debris do still have building positions though. So it is no technical limitation. Just most damaged/destructed buildings models do not (yet?) have building positions. Keep in mind that a damaged or destroyed building is a different object instance (and model).

Bottom Section

更多维基

随机维基