Hallo Gemeinde,
Ich brauch mal hilfe mit den ACE3 Items.
Ich habe schon alle Threads hier zu Ace3 und der bereitstellung der Items gelesen nur leider funktioniert da für mich keiner da diese alle für die 3er oder 4er Version sind.
Was wir schon gemacht haben die Module auf die Map gesetzt und die Items im Shop eingetragen wo sie auch verfügbar sind, desweiteren haben wir diese auch in der core\functions\fn_handleItems.sqf eingetragen, leider weis ich nicht was ich da falsch mache denn ich kann die Items kaufen aber aber sie landen nicht im Inventar.
Die Logs besagen auch nichts dazu.
hier der wichtige Teil der fn_handleItem.sqf
Code
#include "..\..\script_macros.hpp"
/*
File: fn_handleItem.sqf
Author: Bryan "Tonic" Boardwine
Description
Main gear handling functionality.
*/
private ["_item","_details","_bool","_ispack","_items","_isgun","_ongun","_override","_toUniform","_toVest","_preview","_aceCheck"]; //tp
_item = [_this,0,"",[""]] call BIS_fnc_param;
_bool = [_this,1,false,[false]] call BIS_fnc_param;
_ispack = [_this,2,false,[false]] call BIS_fnc_param;
_ongun = [_this,3,false,[false]] call BIS_fnc_param;
_override = [_this,4,false,[false]] call BIS_fnc_param;
_toUniform = [_this,5,false,[false]] call BIS_fnc_param; //Manual override to send items specifically to a uniform.
_toVest = [_this,6,false,[false]] call BIS_fnc_param; //Manual override to send items specifically to a vest
_preview = [_this,7,false,[false]] call BIS_fnc_param;
//tp
_acecheck = ["ACE_atropineItem","ACE_morphineItem","ACE_epinephrineItem","ACE_fieldDressingItem","ACE_packingBandageItem","ACE_quikClotItem","ACE_elasticBandageItem","ACE_tourniquetItem","ACE_salineIVItem","ACE_surgicalKitItem","ACE_personalAidKitItem","ACE_bodyBagItem","ACE_plasmaIVItem","ACE_bloodIVItem"];
//Some checks
if (_item isEqualTo "") exitWith {};
_isgun = false;
_details = [_item] call life_fnc_fetchCfgDetails;
if (count _details isEqualTo 0) exitWith {};
if (_bool) then {
switch (_details select 6) do {
case "CfgGlasses": {
if (_toUniform) exitWith {player addItemToUniform _item;};
if (_toVest) exitWith {player addItemToVest _item;};
if (_ispack) then {
player addItemToBackpack _item;
} else {
if (_override) then {
player addItem _item;
} else {
if (!(goggles player isEqualTo "")) then {
removeGoggles player;
};
player addGoggles _item;
};
};
};
case "CfgVehicles": {
if (!(backpack player isEqualTo "")) then {
_items = (backpackItems player);
removeBackpack player;
};
player addBackpack _item;
clearAllItemsFromBackpack player;
if (!isNil "_items") then {
{[_x,true,true,false,true] call life_fnc_handleItem; } forEach _items;
};
};
case "CfgMagazines": {
if (_toUniform) exitWith {player addItemToUniform _item;};
if (_toVest) exitWith {player addItemToVest _item;};
if (_ispack) exitWith {player addItemToBackpack _item;};
player addMagazine _item;
};
case "CfgWeapons": {
//New addition
if (_toUniform) exitWith {player addItemToUniform _item;};
if (_toVest) exitWith {player addItemToVest _item;};
if (_ispack) exitWith {player addItemToBackpack _item;};
if (_item in _acecheck) exitWith {player addItem _item;}; //tp
if ((_details select 4) in [1,2,4,5,4096]) then {
if ((_details select 4) isEqualTo 4096) then {
if ((_details select 5) isEqualTo -1) then {
_isgun = true;
};
} else {
_isgun = true;
};
};
if (_isgun) then {
if (!_ispack && _override) exitWith {}; //It was in the vest/uniform, try to close to prevent it overriding stuff... (Actual weapon and not an item)
if (_item isEqualTo "MineDetector") then {
player addItem _item;
} else {
player addWeapon _item;
};
} else {
switch (_details select 5) do {
case 0: {
if (_ispack) then {
player addItemToBackpack _item;
} else {
if (_override) then {
player addItem _item;
} else {
if (_item in (assignedItems player)) then {
player addItem _item;
} else {
player linkItem _item;
};
};
};
};
Alles anzeigen