Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSC - Fix: Reference between entry and Default maintained, causing the "links" array referenced across all entries #87

Merged
merged 6 commits into from
Nov 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .hemtt/missions/CSC.Altis/init.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,28 @@ params [



] // Hashmap of additional parameters that can be changed optionally
] call cvo_csc_fnc_register;
[
"ACE Medical Box 2", // Name
[
["ace_banana", 169],
["ace_suture", 169],
["ACE_painkillers", 169]
], // Array of Items to be filled into - Default: []
[
// ["somebackpackclassname", 420]
], // Array of Backpacks to be filled into - Default: []
createHashMapFromArray [
["airdrop_pos_start", [10000,10000,100]],
["box_empty", false],
["box_class", "ACE_medicalSupplyCrate_advanced"],
["airframe_class", "B_T_VTOL_01_vehicle_F"],
["normal_mode", "AIRDROP"],
["airdrop_targetMode", "TARGET"]



] // Hashmap of additional parameters that can be changed optionally
] call cvo_csc_fnc_register;

Expand Down
Binary file modified .hemtt/missions/CSC.Altis/mission.sqm
Binary file not shown.
4 changes: 3 additions & 1 deletion addons/csc/functions/fn_link.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ if (_target isEqualTo "404") exitWith {ZRN_LOG_MSG(No target provided);};

private _cat = [_catName] call FUNC(catalog);
if (_cat isEqualTo "404") exitWith {ZRN_LOG_MSG_1(Catalog not found,_catName);};
private _links = _cat get _entryName getOrDefault ["links", []];
private _links = _cat get _entryName getOrDefault ["links", [[],[]]];

ZRN_LOG_1(_links);


// Check if zeus is enabled for this catalog already - if not - create zeus action and attach it to zeus.
Expand Down
2 changes: 1 addition & 1 deletion addons/csc/functions/fn_register.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private _entry = _cat getOrDefault [_entryName, "404"];
if (_entry isEqualTo "404") then {

_entry = createHashMapFromArray [ ["entryName", _entryName] ];
_entry merge [(_cat get "Default Entry"), false];
_entry merge [+ (_cat get "Default Entry"), false];
};

_entry set ["items", _items];
Expand Down
2 changes: 1 addition & 1 deletion addons/main/script_version.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#define MAJOR 1
#define MINOR 3
#define PATCH 1
#define BUILD 64
#define BUILD 65


// #define VERSION MACROS
Expand Down
Loading