Fandom

武装突袭 Wiki

BIS_fnc_invCodeToArray

简体 | 繁體

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

您使用了广告屏蔽软件!


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

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

  

Click on the images for descriptions

Introduced in

Game:
Arma 2
Version:
1.00

Description

Description:

/*
	File: fn_invSlotsEmpty.sqf

	Description:
	Converts inventory code (used in configs) to array with numbers for weapons and magazines (and their counts).
		
	Parameter(s):
	1: <scalar | empty> config code
	
	Returns:
	<array> items (slots) numbers
	
	
	Function:
	 input (result of): [1  +  4  + 12*  256  + 2* 4096  +  2  + 8* 16  + 12*131072]	 
	 output: [1,1,1,8,12,2,0,12]
	  - means: 1 x WeaponSlotPrimary, 1 x WeaponSlotHangun, ... , 12 x WeaponSlotInventory
	  
	 input: []
	 output: [0,0,0,0,0,0,0,0]

*/


//returned array gives numbers of following:
//mirrored from core config: cfg\Bin\cfgWeapons.hpp
#define WeaponSlotPrimary        1        // primary weapons
#define WeaponSlotHandGun        2        // HandGun
#define WeaponSlotSecondary        4        // secondary weapons
#define WeaponSlotHandGunItem        16 // HandGun magazines
#define WeaponSlotItem                256        // items
#define WeaponSlotBinocular        4096        // binocular
#define WeaponHardMounted        65536
#define WeaponSlotInventory 131072 // inventory items


(Placeholder description extracted from the function header by BIS_fnc_exportFunctionsToWiki)

Example 1:</dt>
Example needed</dd>
See also:</dt>

See also needed</dd>

Notes

Only post proven facts here. Report bugs on the feedback tracker. Use the talk page or the forums for discussions.
Add New Note | How To

Notes

Bottom Section

更多维基

随机维基