Skip to content

[Modding] Creating custom Expansion treasure hunt containers

Steve edited this page Mar 21, 2023 · 2 revisions

Return to the summary


If you plan to add your custom quest container object for the Expansion Quest system treasure hunt objective you can find some examples for the neededed object configuration as well as the needed script classes for NPCs here.

Example config.cpp:

class CfgPatches
{
    class MyMod_Quests_ContainerEntities
    {
        units[]={};
        weapons[]={};
        requiredVersion=0.1;
        requiredAddons[]=
        {
            "DayZExpansion_Quests_Dta_Objects_Containers"
        };
    };
};

class CfgVehicles
{
    class ExpansionQuestSeaChest: ExpansionQuestContainerBase
	{
		scope=2;
		displayName="$STR_CfgVehicles_SeaChest0";
		descriptionShort="$STR_CfgVehicles_SeaChest1";
		model="\DZ\gear\camping\sea_chest.p3d";
		class Cargo
		{
			itemsCargoSize[]={10,100};
			openable=0;
			allowOwnedCargoManipulation=1;
		};
	};
};

Script class example for the 4_World script module of your mod:

class ExpansionQuestSeaChest: ExpansionQuestContainerBase {};
Clone this wiki locally