Jump to content

Ricardo

Member
  • Posts

    54
  • Joined

  • Last visited

Posts posted by Ricardo

  1. Hello Everyone,

     

    I made some additions to my server awhile ago, since i locked it (no time to admin) i thought i would share them to everyone.

     

    My additions include a NorthWest base at the end of the Airfield, a new NorthEast Airfield, Checkpoints around the map and finally a new look to Stary Trader.

     

    Hope you enjoy! ;)

     

    NOTE!!!

     

    If you get errors on your server when you join, simply just copy this code to your "mission.sqm" located on your mission folder.

     

    Add this code to the bottom of "addOns" section:

    "mbg_buildings_3",
    "mbg_killhouses",
    "mbg_african_buildings"
    

    --------------------------------------------------------------------------------------------------------------------------

    NorthWest Airfield Base

    https://mega.co.nz/#!xVtQRSaT!4P5nLQS7mzIUvqxhMOqROc2DnBbD7qmgbm9fppSVc8E

     

    Pictures

    http://imgur.com/a/EsiHI#0

    --------------------------------------------------------------------------------------------------------------------------

     

    NorthEast Airfield

    https://mega.co.nz/#!MYkCyJoL!Rb7aqWliSuVtHvBZXf3BFXrEK3ZWcU6bkkNh0eGfLkQ

     

    Pictures

    http://imgur.com/a/A54VO#0

    --------------------------------------------------------------------------------------------------------------------------

     

    Checkpoints

    https://mega.co.nz/#!oYlxiIrb!-bY98PnmN6pTclygYkzKx72cmcSQXPW7Gtg2sheaEzk

     

    Pictures

    http://imgur.com/a/A0vIM#8

    --------------------------------------------------------------------------------------------------------------------------

     

    Stary Trader

    https://mega.co.nz/#!kQ902JQY!M3WqrQbelewcbC92eZhIQw4v1xLMnqOd-nMjHMDjLHA

     

    Pictures

    http://imgur.com/a/dQDLa#0

     

     

    How to install:

     

    Unpack your dayz_server.pbo

     

    Add the following code to the bottom of your server_functions.sqf  located at:

    dayz_server\init\server_functions.sqf

    execVM "\z\addons\dayz_server\buildings\checkpoints.sqf";
    execVM "\z\addons\dayz_server\buildings\traderstary.sqf";
    execVM "\z\addons\dayz_server\buildings\nwafbase.sqf";
    execVM "\z\addons\dayz_server\buildings\neaf.sqf";
    

    Crate a folder on your dayz_server.pbo and name it "buildings".

    Copy all the files you just downloaded into that folder.

     

    Repack and Upload your dayz_server.pbo

  2. Thanks for the quick reply!

     

     

    Something like this:

    //Add and fill the crate
    _box = ["RULaunchersBox","RULaunchersBox","RULaunchersBox"]; // Box Classnames
    _fBox = _box select (random (count _box - 1)); // Picks a Classname
    _crate = createVehicle [_fBox,[(_coords select 0) - 14, _coords select 1,0],[], 0, "CAN_COLLIDE"]; // Creates the Box
    [_crate] ExecVM DZMSBoxSetup;
    [_crate] call DZMSProtectObj;
    

     

    But im a bit  confused, im trying to understand your solution to my problem, so...

    _box = ["RULaunchersBox","RULaunchersBox","RULaunchersBox"]; // Box Classnames
    _fBox = _box select (random (count _box - 1)); // Picks a Classname
    

    _box defines what box can choose, in this case ["USLaunchersBox","RULaunchersBox","USBasicAmmunitionBox"] right?

    _fbox randomizes which box will be choosen within all those 4 box's, then:

    _crate = createVehicle [_fBox,[(_coords select 0) - 14, _coords select 1,0],[], 0, "CAN_COLLIDE"]; // Creates the Box
    

    Creates the box choosen in _fbox to the mission location, but this for in my understanding spawns a box with the loot that Arma has inside the box or this chooses one of my static box's i defined in DZMSBox.sqf?

     

    In this case:

    _box = ["weapons","weapons1","weapons3","weapons4"];
    

    Maybe im completly wrong

    Im sorry, im not that good with scripting :P

  3. Hello,

     

    I have created Static box's so the loot inside it's not randomize, however i would like to know how can i randomize my static box's?

     

    What i mean is, not randomize the loot inside the box but the box that it chooses to spawn from the static ones i created.

     

    This is my DZMSBox.sqf

    /*


    Usage: [_crate,"type"] execVM "dir\DZMSBox.sqf";
    _crate is the crate to fill
    "type" is the type of crate
    "type" can be weapons or medical
    */
    _crate = _this select 0;
    _type = _this select 1;

    // Clear the current cargo
    clearWeaponCargoGlobal _crate;
    clearMagazineCargoGlobal _crate;

    // Define lists. Some lists are defined in DZMSWeaponCrateList.sqf in the ExtConfig.
    _bpackList = ["DZ_Patrol_Pack_EP1","DZ_Assault_Pack_EP1","DZ_Czech_Vest_Puch","DZ_ALICE_Pack_EP1","DZ_TK_Assault_Pack_EP1","DZ_British_ACU","DZ_CivilBackpack_EP1","DZ_Backpack_EP1"];
    _gshellList = ["HandGrenade_west","FlareGreen_M203","FlareWhite_M203"];
    _medical = ["ItemBandage","ItemMorphine","ItemEpinephrine","ItemPainkiller","ItemWaterbottle","FoodMRE","ItemAntibiotic","ItemBloodbag"];
    _money = ["ItemSilverBar","ItemSilverBar10oz","ItemGoldBar","ItemGoldBar10oz"];
    _box = ["weapons","weapons1","weapons3","weapons4"];
    _box2 = ["weapons","weapons1","weapons3","weapons4"];
    _box3 = ["medical","medical2","food"];
    _box4 = ["supply","supply2"];

    //////////////////////////////////////////////////////////////////
    // Medical Crates
    if (_type == "medical") then {
    // load medical
    // Add Ammunition
    _crate addMagazineCargoGlobal ["ItemBandage",20];
    _crate addMagazineCargoGlobal ["ItemMorphine",10];
    _crate addMagazineCargoGlobal ["ItemEpinephrine",10];
    _crate addMagazineCargoGlobal ["ItemPainkiller",10];
    _crate addMagazineCargoGlobal ["ItemBloodbag",10];
    _crate addMagazineCargoGlobal ["ItemAntibiotic",5];
    _crate addMagazineCargoGlobal ["SmokeShell",2];
    _crate addMagazineCargoGlobal ["SmokeShellYellow",2];
    _crate addMagazineCargoGlobal ["SmokeShellRed",2];
    _crate addMagazineCargoGlobal ["SmokeShellGreen",2];
    _crate addMagazineCargoGlobal ["SmokeShellPurple",2];
    _crate addMagazineCargoGlobal ["SmokeShellBlue",2];
    _crate addMagazineCargoGlobal ["SmokeShellOrange",2];

    // Add Weapons
    _crate addWeaponCargoGlobal ["Binocular_Vector",1];
    _crate addWeaponCargoGlobal ["ItemToolbox",2];
    _crate addWeaponCargoGlobal ["ItemEtool",2];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];
    };
    if (_type == "medical2") then {
    // load medical
    // Add Ammunition
    _crate addMagazineCargoGlobal ["ItemBandage",15];
    _crate addMagazineCargoGlobal ["ItemMorphine",12];
    _crate addMagazineCargoGlobal ["ItemEpinephrine",15];
    _crate addMagazineCargoGlobal ["ItemPainkiller",15];
    _crate addMagazineCargoGlobal ["ItemBloodbag",12];
    _crate addMagazineCargoGlobal ["ItemAntibiotic",7];
    _crate addMagazineCargoGlobal ["SmokeShell",2];
    _crate addMagazineCargoGlobal ["SmokeShellYellow",2];
    _crate addMagazineCargoGlobal ["SmokeShellRed",2];
    _crate addMagazineCargoGlobal ["SmokeShellGreen",2];
    _crate addMagazineCargoGlobal ["SmokeShellPurple",2];
    _crate addMagazineCargoGlobal ["SmokeShellBlue",2];
    _crate addMagazineCargoGlobal ["SmokeShellOrange",2];

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemCrowbar",2];
    _crate addWeaponCargoGlobal ["Binoculars",2];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];
    };

    //////////////////////////////////////////////////////////////////
    // Food Crates
    if (_type == "food") then {
    // load Food
    // Add Ammunition
    _crate addMagazineCargoGlobal ["FoodMRE",5];
    _crate addMagazineCargoGlobal ["FoodSteakCooked",2];
    _crate addMagazineCargoGlobal ["FoodCanBoneboy",2];
    _crate addMagazineCargoGlobal ["FoodCanGriff",2];
    _crate addMagazineCargoGlobal ["FoodCanCorn",2];
    _crate addMagazineCargoGlobal ["FoodCanBadguy",2];
    _crate addMagazineCargoGlobal ["FoodCanCurgon",2];
    _crate addMagazineCargoGlobal ["FoodCanDemon",2];
    _crate addMagazineCargoGlobal ["FoodCanFraggleos",2];
    _crate addMagazineCargoGlobal ["FoodCanHerpy",2];
    _crate addMagazineCargoGlobal ["ItemWaterbottle",5];
    _crate addMagazineCargoGlobal ["ItemSodaR4z0r",2];
    _crate addMagazineCargoGlobal ["ItemSodaClays",2];
    _crate addMagazineCargoGlobal ["ItemSodaSmasht",2];
    _crate addMagazineCargoGlobal ["ItemSodaDrwaste",2];
    _crate addMagazineCargoGlobal ["ItemSodaLemonade",2];
    _crate addMagazineCargoGlobal ["ItemSodaLvg",2];
    _crate addMagazineCargoGlobal ["ItemSodaMzly",2];
    _crate addMagazineCargoGlobal ["ItemSodaRabbit",2];
    _crate addMagazineCargoGlobal ["ItemSodaRbull",1];
    };

    ///////////////////////////////////////////////////////////////////
    // Weapon Crates
    if (_type == "weapons") then {
    // load Weapons
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["M16A2",3];
    _crate addWeaponCargoGlobal ["M4A1_HWS_GL_SD_Camo",3];
    _crate addWeaponCargoGlobal ["G36K",2];
    _crate addWeaponCargoGlobal ["M9SD",2];
    _crate addWeaponCargoGlobal ["M1014",2];
    _crate addWeaponCargoGlobal ["AKS_74_U",2];
    _crate addWeaponCargoGlobal ["m8_Sharpshooter",1];
    _crate addWeaponCargoGlobal ["AK_74_GL",1];
    _crate addWeaponCargoGlobal ["M24",1];
    _crate addWeaponCargoGlobal ["M40A3",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",20];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["15Rnd_9x19_M9SD",10];
    _crate addMagazineCargoGlobal ["8Rnd_B_Beneli_74Slug",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_DMR",5];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",10];
    _crate addMagazineCargoGlobal ["1Rnd_SMOKE_GP25",4];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];

    };
    if (_type == "weapons2") then {
    // load Weapons
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["G36A",3];
    _crate addWeaponCargoGlobal ["G36_C_SD_Eotech",3];
    _crate addWeaponCargoGlobal ["G36C",2];
    _crate addWeaponCargoGlobal ["MakarovSD",2];
    _crate addWeaponCargoGlobal ["m8_Carbine",2];
    _crate addWeaponCargoGlobal ["MP5A5",2];
    _crate addWeaponCargoGlobal ["m8_Sharpshooter",1];
    _crate addWeaponCargoGlobal ["Mk_48_DZ",1];
    _crate addWeaponCargoGlobal ["SVD_Camo",1];
    _crate addWeaponCargoGlobal ["KSVK_DZE",1];
    _crate addWeaponCargoGlobal ["RPK_74",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36",20];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36SD",15];
    _crate addMagazineCargoGlobal ["8Rnd_9x18_MakarovSD",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["10Rnd_762x54_SVD",10];
    _crate addMagazineCargoGlobal ["5Rnd_127x108_KSVK",5];
    _crate addMagazineCargoGlobal ["75Rnd_545x39_RPK",5];
    _crate addMagazineCargoGlobal ["30rnd_9x19_MP5",5];
    _crate addMagazineCargoGlobal ["HandGrenade",5];

    };
    if (_type == "weapons3") then {
    // load Weapons3
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["SCAR_L_CQC",3];
    _crate addWeaponCargoGlobal ["SCAR_L_CQC_CCO_SD",3];
    _crate addWeaponCargoGlobal ["Sa58V_CCO_EP1",2];
    _crate addWeaponCargoGlobal ["Colt1911",2];
    _crate addWeaponCargoGlobal ["bizon_silenced",2];
    _crate addWeaponCargoGlobal ["AKS_74_U",2];
    _crate addWeaponCargoGlobal ["M8_carbineGL",1];
    _crate addWeaponCargoGlobal ["AK_74_GL",1];
    _crate addWeaponCargoGlobal ["VSS_vintorez",1];
    _crate addWeaponCargoGlobal ["M40A3",1];
    _crate addWeaponCargoGlobal ["M240_DZ",1];
    _crate addWeaponCargoGlobal ["RPG7V",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["7Rnd_45ACP_1911",10];
    _crate addMagazineCargoGlobal ["64Rnd_9x19_SD_Bizon",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",10];
    _crate addMagazineCargoGlobal ["20Rnd_9x39_SP5_VSS",5];

    };
    if (_type == "weapons4") then {
    // load Weapons4
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["AK_47_M",3];
    _crate addWeaponCargoGlobal ["Mk_48_DES_EP1",1];
    _crate addWeaponCargoGlobal ["Sa58V_CCO_EP1",2];
    _crate addWeaponCargoGlobal ["glock17_EP1",2];
    _crate addWeaponCargoGlobal ["Saiga12K",2];
    _crate addWeaponCargoGlobal ["AK_47_S",2];
    _crate addWeaponCargoGlobal ["m8_SAW",1];
    _crate addWeaponCargoGlobal ["PK",1];
    _crate addWeaponCargoGlobal ["SCAR_H_LNG_Sniper",1];
    _crate addWeaponCargoGlobal ["M24_des_EP1",1];
    _crate addWeaponCargoGlobal ["M110_NVG_EP1",1];
    _crate addWeaponCargoGlobal ["M4SPR",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["17Rnd_9x19_glock17",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["8Rnd_B_Saiga12_74Slug",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x54_PK",5];
    _crate addMagazineCargoGlobal ["30Rnd_762x39_AK47",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_B_SCAR",5];

    };

    ///////////////////////////////////////////////////////////////////
    // Ammo Crates
    if (_type == "ammo") then {
    // load Ammo

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",25];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_B_SCAR",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_SB_SCAR",5];
    _crate addMagazineCargoGlobal ["10Rnd_762x54_SVD",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_DMR",10];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",15];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36",15];
    _crate addMagazineCargoGlobal ["30Rnd_762x39_AK4",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_FNFAL",7];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["100Rnd_762x54_PK",5];
    _crate addMagazineCargoGlobal ["200Rnd_556x45_M249",3];
    _crate addMagazineCargoGlobal ["15Rnd_9x19_M9SD",3];
    _crate addMagazineCargoGlobal ["17Rnd_9x19_glock17",5];
    _crate addMagazineCargoGlobal ["6Rnd_45ACP",5];
    _crate addMagazineCargoGlobal ["8Rnd_9x18_MakarovSD",5];
    _crate addMagazineCargoGlobal ["30Rnd_9x19_UZI_SD",5];
    _crate addMagazineCargoGlobal ["64Rnd_9x19_SD_Bizon",10];
    _crate addMagazineCargoGlobal ["30rnd_9x19_MP5",10];
    _crate addMagazineCargoGlobal ["PG7V",1];
    };

    ///////////////////////////////////////////////////////////////////
    // Epoch Supply Crates
    if (_type == "supply") then {
    // load Supply
    // Add weapons / Tools

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemCrowbar",3];
    _crate addWeaponCargoGlobal ["ItemEtool",3];
    _crate addWeaponCargoGlobal ["ItemHatchet_DZE",2];
    _crate addWeaponCargoGlobal ["ItemKnife",2];
    _crate addWeaponCargoGlobal ["ItemMachete",2];
    _crate addWeaponCargoGlobal ["ItemToolbox",2];
    _crate addWeaponCargoGlobal ["ItemSledgeHead",1];
    _crate addWeaponCargoGlobal ["ItemSledgeHandle",1];
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemKeyKit",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["CinderBlocks",15];
    _crate addMagazineCargoGlobal ["MortarBucket",10];
    _crate addMagazineCargoGlobal ["ItemWire",10];
    _crate addMagazineCargoGlobal ["ItemTankTrap",5];
    _crate addMagazineCargoGlobal ["ItemSandbag",10];
    _crate addMagazineCargoGlobal ["PartPlankPack",15];
    _crate addMagazineCargoGlobal ["PartPlyWoodPack",10];
    _crate addMagazineCargoGlobal ["ItemPole",10];
    _crate addMagazineCargoGlobal ["ItemComboLock",1];
    };

    if (_type == "supply2") then {
    // load Supply2
    // Add weapons / Tools

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemCrowbar",1];
    _crate addWeaponCargoGlobal ["ItemEtool",1];
    _crate addWeaponCargoGlobal ["ItemHatchet_DZE",2];
    _crate addWeaponCargoGlobal ["ItemKnife",2];
    _crate addWeaponCargoGlobal ["ItemMachete",2];
    _crate addWeaponCargoGlobal ["ItemToolbox",5];
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemKeyKit",3];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["PartEngine",2];
    _crate addMagazineCargoGlobal ["PartGeneric",6];
    _crate addMagazineCargoGlobal ["PartFueltank",2];
    _crate addMagazineCargoGlobal ["PartGlass",5];
    _crate addMagazineCargoGlobal ["PartVRotor",1];
    _crate addMagazineCargoGlobal ["PartWheel",4];
    _crate addMagazineCargoGlobal ["ItemJerrycan",3];
    _crate addMagazineCargoGlobal ["ItemFuelPump",1];
    _crate addMagazineCargoGlobal ["ItemFuelBarrel",2];

    };

    ///////////////////////////////////////////////////////////////////
    // Epoch Money Crates
    if (_type == "money") then {
    // load money
    _scount = count _money;
    for "_x" from 0 to 3 do {
    _sSelect = floor(random _sCount);
    _item = _money select _sSelect;
    _crate addMagazineCargoGlobal [_item,1];
    };
    };

     

    This is the box creating inside one of my missions.

    //Add and fill the crate
    _crate = createVehicle ["RULaunchersBox",[(_coords select 0) - 14, _coords select 1,0],[], 0, "CAN_COLLIDE"];
    [_crate = _box select (random (count _box - 1)] ExecVM DZMSBoxSetup;
    [_crate] call DZMSProtectObj;
    

    This is what i have come up so far, but im not sure if i am doing it correctly, can anyone tell me if what im doing is wrong or not?

  4. Hello,

     

    I have created Static box's so the loot inside it's not randomize, however i would like to know how can i randomize my static box's?

     

    What i mean is, not randomize the loot inside the box but the box that it chooses to spawn from the static ones i created.

     

     

    This is my DZMSBox.sqf

    /*


    Usage: [_crate,"type"] execVM "dir\DZMSBox.sqf";
    _crate is the crate to fill
    "type" is the type of crate
    "type" can be weapons or medical
    */
    _crate = _this select 0;
    _type = _this select 1;

    // Clear the current cargo
    clearWeaponCargoGlobal _crate;
    clearMagazineCargoGlobal _crate;

    // Define lists. Some lists are defined in DZMSWeaponCrateList.sqf in the ExtConfig.
    _bpackList = ["DZ_Patrol_Pack_EP1","DZ_Assault_Pack_EP1","DZ_Czech_Vest_Puch","DZ_ALICE_Pack_EP1","DZ_TK_Assault_Pack_EP1","DZ_British_ACU","DZ_CivilBackpack_EP1","DZ_Backpack_EP1"];
    _gshellList = ["HandGrenade_west","FlareGreen_M203","FlareWhite_M203"];
    _medical = ["ItemBandage","ItemMorphine","ItemEpinephrine","ItemPainkiller","ItemWaterbottle","FoodMRE","ItemAntibiotic","ItemBloodbag"];
    _money = ["ItemSilverBar","ItemSilverBar10oz","ItemGoldBar","ItemGoldBar10oz"];
    _box = ["weapons","weapons1","weapons3","weapons4"];
    _box2 = ["weapons","weapons1","weapons3","weapons4"];
    _box3 = ["medical","medical2","food"];
    _box4 = ["supply","supply2"];

    //////////////////////////////////////////////////////////////////
    // Medical Crates
    if (_type == "medical") then {
    // load medical
    // Add Ammunition
    _crate addMagazineCargoGlobal ["ItemBandage",20];
    _crate addMagazineCargoGlobal ["ItemMorphine",10];
    _crate addMagazineCargoGlobal ["ItemEpinephrine",10];
    _crate addMagazineCargoGlobal ["ItemPainkiller",10];
    _crate addMagazineCargoGlobal ["ItemBloodbag",10];
    _crate addMagazineCargoGlobal ["ItemAntibiotic",5];
    _crate addMagazineCargoGlobal ["SmokeShell",2];
    _crate addMagazineCargoGlobal ["SmokeShellYellow",2];
    _crate addMagazineCargoGlobal ["SmokeShellRed",2];
    _crate addMagazineCargoGlobal ["SmokeShellGreen",2];
    _crate addMagazineCargoGlobal ["SmokeShellPurple",2];
    _crate addMagazineCargoGlobal ["SmokeShellBlue",2];
    _crate addMagazineCargoGlobal ["SmokeShellOrange",2];

    // Add Weapons
    _crate addWeaponCargoGlobal ["Binocular_Vector",1];
    _crate addWeaponCargoGlobal ["ItemToolbox",2];
    _crate addWeaponCargoGlobal ["ItemEtool",2];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];
    };
    if (_type == "medical2") then {
    // load medical
    // Add Ammunition
    _crate addMagazineCargoGlobal ["ItemBandage",15];
    _crate addMagazineCargoGlobal ["ItemMorphine",12];
    _crate addMagazineCargoGlobal ["ItemEpinephrine",15];
    _crate addMagazineCargoGlobal ["ItemPainkiller",15];
    _crate addMagazineCargoGlobal ["ItemBloodbag",12];
    _crate addMagazineCargoGlobal ["ItemAntibiotic",7];
    _crate addMagazineCargoGlobal ["SmokeShell",2];
    _crate addMagazineCargoGlobal ["SmokeShellYellow",2];
    _crate addMagazineCargoGlobal ["SmokeShellRed",2];
    _crate addMagazineCargoGlobal ["SmokeShellGreen",2];
    _crate addMagazineCargoGlobal ["SmokeShellPurple",2];
    _crate addMagazineCargoGlobal ["SmokeShellBlue",2];
    _crate addMagazineCargoGlobal ["SmokeShellOrange",2];

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemCrowbar",2];
    _crate addWeaponCargoGlobal ["Binoculars",2];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];
    };

    //////////////////////////////////////////////////////////////////
    // Food Crates
    if (_type == "food") then {
    // load Food
    // Add Ammunition
    _crate addMagazineCargoGlobal ["FoodMRE",5];
    _crate addMagazineCargoGlobal ["FoodSteakCooked",2];
    _crate addMagazineCargoGlobal ["FoodCanBoneboy",2];
    _crate addMagazineCargoGlobal ["FoodCanGriff",2];
    _crate addMagazineCargoGlobal ["FoodCanCorn",2];
    _crate addMagazineCargoGlobal ["FoodCanBadguy",2];
    _crate addMagazineCargoGlobal ["FoodCanCurgon",2];
    _crate addMagazineCargoGlobal ["FoodCanDemon",2];
    _crate addMagazineCargoGlobal ["FoodCanFraggleos",2];
    _crate addMagazineCargoGlobal ["FoodCanHerpy",2];
    _crate addMagazineCargoGlobal ["ItemWaterbottle",5];
    _crate addMagazineCargoGlobal ["ItemSodaR4z0r",2];
    _crate addMagazineCargoGlobal ["ItemSodaClays",2];
    _crate addMagazineCargoGlobal ["ItemSodaSmasht",2];
    _crate addMagazineCargoGlobal ["ItemSodaDrwaste",2];
    _crate addMagazineCargoGlobal ["ItemSodaLemonade",2];
    _crate addMagazineCargoGlobal ["ItemSodaLvg",2];
    _crate addMagazineCargoGlobal ["ItemSodaMzly",2];
    _crate addMagazineCargoGlobal ["ItemSodaRabbit",2];
    _crate addMagazineCargoGlobal ["ItemSodaRbull",1];
    };

    ///////////////////////////////////////////////////////////////////
    // Weapon Crates
    if (_type == "weapons") then {
    // load Weapons
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["M16A2",3];
    _crate addWeaponCargoGlobal ["M4A1_HWS_GL_SD_Camo",3];
    _crate addWeaponCargoGlobal ["G36K",2];
    _crate addWeaponCargoGlobal ["M9SD",2];
    _crate addWeaponCargoGlobal ["M1014",2];
    _crate addWeaponCargoGlobal ["AKS_74_U",2];
    _crate addWeaponCargoGlobal ["m8_Sharpshooter",1];
    _crate addWeaponCargoGlobal ["AK_74_GL",1];
    _crate addWeaponCargoGlobal ["M24",1];
    _crate addWeaponCargoGlobal ["M40A3",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",20];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["15Rnd_9x19_M9SD",10];
    _crate addMagazineCargoGlobal ["8Rnd_B_Beneli_74Slug",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_DMR",5];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",10];
    _crate addMagazineCargoGlobal ["1Rnd_SMOKE_GP25",4];

    // Add Backpacks
    _crate addBackpackCargoGlobal ["DZ_GunBag_EP1",1];
    _crate addBackpackCargoGlobal ["DZ_Backpack_EP1",2];
    _crate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1",1];

    };
    if (_type == "weapons2") then {
    // load Weapons
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["G36A",3];
    _crate addWeaponCargoGlobal ["G36_C_SD_Eotech",3];
    _crate addWeaponCargoGlobal ["G36C",2];
    _crate addWeaponCargoGlobal ["MakarovSD",2];
    _crate addWeaponCargoGlobal ["m8_Carbine",2];
    _crate addWeaponCargoGlobal ["MP5A5",2];
    _crate addWeaponCargoGlobal ["m8_Sharpshooter",1];
    _crate addWeaponCargoGlobal ["Mk_48_DZ",1];
    _crate addWeaponCargoGlobal ["SVD_Camo",1];
    _crate addWeaponCargoGlobal ["KSVK_DZE",1];
    _crate addWeaponCargoGlobal ["RPK_74",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36",20];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36SD",15];
    _crate addMagazineCargoGlobal ["8Rnd_9x18_MakarovSD",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["10Rnd_762x54_SVD",10];
    _crate addMagazineCargoGlobal ["5Rnd_127x108_KSVK",5];
    _crate addMagazineCargoGlobal ["75Rnd_545x39_RPK",5];
    _crate addMagazineCargoGlobal ["30rnd_9x19_MP5",5];
    _crate addMagazineCargoGlobal ["HandGrenade",5];

    };
    if (_type == "weapons3") then {
    // load Weapons3
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["SCAR_L_CQC",3];
    _crate addWeaponCargoGlobal ["SCAR_L_CQC_CCO_SD",3];
    _crate addWeaponCargoGlobal ["Sa58V_CCO_EP1",2];
    _crate addWeaponCargoGlobal ["Colt1911",2];
    _crate addWeaponCargoGlobal ["bizon_silenced",2];
    _crate addWeaponCargoGlobal ["AKS_74_U",2];
    _crate addWeaponCargoGlobal ["M8_carbineGL",1];
    _crate addWeaponCargoGlobal ["AK_74_GL",1];
    _crate addWeaponCargoGlobal ["VSS_vintorez",1];
    _crate addWeaponCargoGlobal ["M40A3",1];
    _crate addWeaponCargoGlobal ["M240_DZ",1];
    _crate addWeaponCargoGlobal ["RPG7V",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["7Rnd_45ACP_1911",10];
    _crate addMagazineCargoGlobal ["64Rnd_9x19_SD_Bizon",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",10];
    _crate addMagazineCargoGlobal ["20Rnd_9x39_SP5_VSS",5];

    };
    if (_type == "weapons4") then {
    // load Weapons4
    // Add weapons

    // Add Weapons
    _crate addWeaponCargoGlobal ["AK_47_M",3];
    _crate addWeaponCargoGlobal ["Mk_48_DES_EP1",1];
    _crate addWeaponCargoGlobal ["Sa58V_CCO_EP1",2];
    _crate addWeaponCargoGlobal ["glock17_EP1",2];
    _crate addWeaponCargoGlobal ["Saiga12K",2];
    _crate addWeaponCargoGlobal ["AK_47_S",2];
    _crate addWeaponCargoGlobal ["m8_SAW",1];
    _crate addWeaponCargoGlobal ["PK",1];
    _crate addWeaponCargoGlobal ["SCAR_H_LNG_Sniper",1];
    _crate addWeaponCargoGlobal ["M24_des_EP1",1];
    _crate addWeaponCargoGlobal ["M110_NVG_EP1",1];
    _crate addWeaponCargoGlobal ["M4SPR",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["17Rnd_9x19_glock17",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["8Rnd_B_Saiga12_74Slug",15];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",10];
    _crate addMagazineCargoGlobal ["100Rnd_762x54_PK",5];
    _crate addMagazineCargoGlobal ["30Rnd_762x39_AK47",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_B_SCAR",5];

    };

    ///////////////////////////////////////////////////////////////////
    // Ammo Crates
    if (_type == "ammo") then {
    // load Ammo

    // Add Ammunition
    _crate addMagazineCargoGlobal ["30Rnd_556x45_Stanag",25];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_StanagSD",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_B_SCAR",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_SB_SCAR",5];
    _crate addMagazineCargoGlobal ["10Rnd_762x54_SVD",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_DMR",10];
    _crate addMagazineCargoGlobal ["5Rnd_762x51_M24",15];
    _crate addMagazineCargoGlobal ["30Rnd_545x39_AK",15];
    _crate addMagazineCargoGlobal ["30Rnd_556x45_G36",15];
    _crate addMagazineCargoGlobal ["30Rnd_762x39_AK4",10];
    _crate addMagazineCargoGlobal ["20Rnd_762x51_FNFAL",7];
    _crate addMagazineCargoGlobal ["100Rnd_762x51_M240",5];
    _crate addMagazineCargoGlobal ["100Rnd_762x54_PK",5];
    _crate addMagazineCargoGlobal ["200Rnd_556x45_M249",3];
    _crate addMagazineCargoGlobal ["15Rnd_9x19_M9SD",3];
    _crate addMagazineCargoGlobal ["17Rnd_9x19_glock17",5];
    _crate addMagazineCargoGlobal ["6Rnd_45ACP",5];
    _crate addMagazineCargoGlobal ["8Rnd_9x18_MakarovSD",5];
    _crate addMagazineCargoGlobal ["30Rnd_9x19_UZI_SD",5];
    _crate addMagazineCargoGlobal ["64Rnd_9x19_SD_Bizon",10];
    _crate addMagazineCargoGlobal ["30rnd_9x19_MP5",10];
    _crate addMagazineCargoGlobal ["PG7V",1];
    };

    ///////////////////////////////////////////////////////////////////
    // Epoch Supply Crates
    if (_type == "supply") then {
    // load Supply
    // Add weapons / Tools

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemCrowbar",3];
    _crate addWeaponCargoGlobal ["ItemEtool",3];
    _crate addWeaponCargoGlobal ["ItemHatchet_DZE",2];
    _crate addWeaponCargoGlobal ["ItemKnife",2];
    _crate addWeaponCargoGlobal ["ItemMachete",2];
    _crate addWeaponCargoGlobal ["ItemToolbox",2];
    _crate addWeaponCargoGlobal ["ItemSledgeHead",1];
    _crate addWeaponCargoGlobal ["ItemSledgeHandle",1];
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemKeyKit",1];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["CinderBlocks",15];
    _crate addMagazineCargoGlobal ["MortarBucket",10];
    _crate addMagazineCargoGlobal ["ItemWire",10];
    _crate addMagazineCargoGlobal ["ItemTankTrap",5];
    _crate addMagazineCargoGlobal ["ItemSandbag",10];
    _crate addMagazineCargoGlobal ["PartPlankPack",15];
    _crate addMagazineCargoGlobal ["PartPlyWoodPack",10];
    _crate addMagazineCargoGlobal ["ItemPole",10];
    _crate addMagazineCargoGlobal ["ItemComboLock",1];
    };

    if (_type == "supply2") then {
    // load Supply2
    // Add weapons / Tools

    // Add Weapons
    _crate addWeaponCargoGlobal ["ItemCrowbar",1];
    _crate addWeaponCargoGlobal ["ItemEtool",1];
    _crate addWeaponCargoGlobal ["ItemHatchet_DZE",2];
    _crate addWeaponCargoGlobal ["ItemKnife",2];
    _crate addWeaponCargoGlobal ["ItemMachete",2];
    _crate addWeaponCargoGlobal ["ItemToolbox",5];
    _crate addWeaponCargoGlobal ["ItemGPS",1];
    _crate addWeaponCargoGlobal ["ItemKeyKit",3];

    // Add Ammunition
    _crate addMagazineCargoGlobal ["PartEngine",2];
    _crate addMagazineCargoGlobal ["PartGeneric",6];
    _crate addMagazineCargoGlobal ["PartFueltank",2];
    _crate addMagazineCargoGlobal ["PartGlass",5];
    _crate addMagazineCargoGlobal ["PartVRotor",1];
    _crate addMagazineCargoGlobal ["PartWheel",4];
    _crate addMagazineCargoGlobal ["ItemJerrycan",3];
    _crate addMagazineCargoGlobal ["ItemFuelPump",1];
    _crate addMagazineCargoGlobal ["ItemFuelBarrel",2];

    };

    ///////////////////////////////////////////////////////////////////
    // Epoch Money Crates
    if (_type == "money") then {
    // load money
    _scount = count _money;
    for "_x" from 0 to 3 do {
    _sSelect = floor(random _sCount);
    _item = _money select _sSelect;
    _crate addMagazineCargoGlobal [_item,1];
    };
    };

     

    This is the box creating inside one of my missions.

    //Add and fill the crate
    _crate = createVehicle ["RULaunchersBox",[(_coords select 0) - 14, _coords select 1,0],[], 0, "CAN_COLLIDE"];
    [_crate = _box select (random (count _box - 1)] ExecVM DZMSBoxSetup;
    [_crate] call DZMSProtectObj;
    

    This is what i have come up so far, but im not sure if i am doing it correctly, can anyone tell me if what im doing is wrong or not?

  5. you can add some custom skins to your custom variables.sqf

    you will see  all the skins at the top

    add it to 

    //Model Variables

     

    and 

    AllPlayers = 

     

    https://community.bistudio.com/wiki/ArmA_2_OA:_Infantry

    https://community.bistudio.com/wiki/ArmA_2:_Infantry

     

    test em on urself first

    I added hooker skin and she was crazy. All I could do was run around with hands in air was funny

     

    let me know if you dont have a custom variables.sqf

     

    This is not working for me, pls correct me if i did something wrong.

     

    Grabbed variables.sqf from dayz_code/init, put in a custom folder in mission.pbo

     

    Went to Init file and called the variables from there to the correct path:

    call compile preprocessFileLineNumbers "custom\variables.sqf";                       //Initilize the Variables (IMPORTANT: Must happen very early)
    

    Inside variables.sqf added the desired skins like:

    (Im not including the existing code, just my additions to shorten the post)

    //Model Variables
    
    FR_Marksman =   "FR_Marksman_DZ";
    MVD_Soldier =   "MVD_Soldier_DZ";
    FR_TL =         "FR_TL_DZ";
    FR_MILES =      "FR_MILES_DZ";
    CZ_Soldier =    "CZ_Soldier_DZ";
    US_Delta_Force_EP1 = "US_Delta_Force_EP1_DZ";
    US_Soldier_Light_EP1 = "US_Soldier_Light_EP1_DZ";
    
    AllPlayers = ["CZ_Soldier_DZ","FR_MILES_DZ","FR_TL_DZ","MVD_Soldier_DZ","FR_Marksman_DZ","US_Delta_Force_EP1_DZ","US_Soldier_Light_EP1_DZ"]
    

    And then on my database i added the skins to bandit/hero traders like this:

    INSERT INTO `trader_items` (`id`, `classname`, `type`, `group`,`afile`) VALUES 
    (0, 'Skin_CZ_Soldier_DZ', 1, 'Clothes Hero','trade_items');
    
    INSERT INTO `Traders_DATA` (`id`, `item`, `qty`, `buy`, `sell`, `order`, `tid`, `afile`) VALUES
    (0, '["Skin_CZ_Soldier_DZ",1]', 250, '[2,"ItemGoldBar",1]', '[1,"ItemGoldBar",1]', 0, 476, 'trade_items');
    

    The skins are appear on the traders but same thing happens, when i buy them i get nothing on my inventory.

     

    I noticed that every skin on the database has the "Skin_" before the classname so i decided to do the same, do you guys think thats the reason its not working?

     

     

     

    I already knew that website, i even mentioned on my post, but what im looking for is how to change the coordinates that the website gives me to more accurate coords so i can put those in the files, like the example i gave: (example:{7839.6055,381.33774,8414.7324}).

  6. Also i didnt want to create a new topic :P but if possible someone could help me out with another question, how can i define Ingame coordinates to File coordinates, what i mean by this is:

     

    I wanted to create markers on the map to define my custom loot bases and i already know how to add those markers i just dont know how to write the coordinates correctly, basically i used this website

     

    http://snuletek.org/calculators/arma2coordcalc/

     

    and i type 076/104 and i get [0,[7600,4960,0]] but i cant use that on markers i believe, i dont think it can read that, i have to use something like (example:{7839.6055,381.33774,8414.7324}).

     

    Those type of coordinates in the example im looking for, if anyone could help me please let me know! 

     

    Im really noob with this kind of stuff ^^

     

    Best regards, Ricardo!

  7. Hello!

     

    How can i add new clothes to the traders, im not talking about external addons that people have to download, i know that it doesn't work without the player having to download them.

     

    Im talking about the non-Dayz ones, i noticed all clothes in dayz have a _DZ in their classname example = Skin_Sniper1_DZ, i believe this is what turns the "skin" into a Item that players can go into their inventory and click to "wear".

     

    But theres some really cool skins included in Arma 2 and Arma2:OA that i would like to implement in my server that doesnt require people to download them.

     

    Already tried adding them to the traders but i already saw it doesnt work and it takes my money without giving me anything in my inventory, i also tried adding them with _DZ next to it obviously didnt work either.

     

    I believe there must be a file in dayz_code that i need to define the skins and they add them to traders.

     

    Does anyone know what file?

     

    I saw something related to this in dayz_code/init/variables.sqf but im not sure.

     

    If anyone knows how to do this i would be really thankful

     

    Thanks in advance!

  8. Oh i might have missunderstand what u meant, i got a backup of the default files, i was wondering if theres any chance you would send me the files with the monitor, if not it's totally ok.

     

    Im gratefull enough with the help you are giving me :)

     

    I still can't get the monitor to work with the picture :(

  9. Aparently my changes dont make missions spawn now, weird, im going thro the files see if i missed any , or ;

     

     

    Would Calling the monitor after the plane/crate/vehicle is spawned make the mission not work?

     

     

    Sorry for the late response (i dont own a test server, so everytime i wanna test something i have to wait a full restart)

  10.  

     

    Hmm, interessting. So, the text spawns fine, but the picture doesn't show up?

     

    After i added your changes after _plane was spawned, i think i added it wrong cause i added it after AI so missions didnt come up, but i already modified in order to be after the plane was created, all tho the crates might be the problem aswell since it doesn't recognize the _crate picture it blocks there, ill change everything now

     

     

    :o All tho i though crates had pictures in the game files hmmm

     

    Well ok thanks ill try it out

  11. I guess calling it like

    //DZMSBoxFill fills the box, DZMSProtectObj prevents it from disappearing
    [_crate,"medical"] ExecVM DZMSBoxSetup;
    [_crate] call DZMSProtectObj;

    _crate2 = createVehicle ["USLaunchersBox",[(_coords select 0) - 8, _coords select 1,0],[], 0, "CAN_COLLIDE"];
    [_crate2,"weapons"] ExecVM DZMSBoxSetup;
    [_crate2] call DZMSProtectObj;

    //DZMSAISpawn spawns AI to the mission.
    //Usage: [_coords, count, skillLevel, unitArray]
    [[(_coords select 0) - 20, (_coords select 1) - 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) + 10, (_coords select 1) + 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) - 10, (_coords select 1) - 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) + 20, (_coords select 1) + 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;

     

    _pic = (gettext (configFile >> 'CfgVehicles' >> (typeof vehicle _crate) >> 'picture'));
    _hint = parseText format ["

    <t size='1.4' font='Bitstream' align='center' color='#DDDDDD'>Medical Outpost</t><br/><br/>
    <t align='center'><img size='5' image='%1'/></t><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>Bandits have taken over a Medical Outpost!</t><br/><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>Go take their Medical Supplies!</t><br/><br/>
    <t size='1' font='Bitstream' align='center' color='#16DB57'>Check your Map for the location!</t><br/>",

    _pic
    ];
    [nil,nil,rHINT,_hint] call RE;

     

    Doesn't even make my missions spawn, im gonna put like

     

    //DZMSBoxFill fills the box, DZMSProtectObj prevents it from disappearing


    [_crate,"medical"] ExecVM DZMSBoxSetup;
    [_crate] call DZMSProtectObj;

    _crate2 = createVehicle ["USLaunchersBox",[(_coords select 0) - 8, _coords select 1,0],[], 0, "CAN_COLLIDE"];
    [_crate2,"weapons"] ExecVM DZMSBoxSetup;
    [_crate2] call DZMSProtectObj;

    _pic = (gettext (configFile >> 'CfgVehicles' >> (typeof vehicle _crate) >> 'picture'));
    _hint = parseText format ["

     

    <t size='1.4' font='Bitstream' align='center' color='#DDDDDD'>Medical Outpost</t><br/><br/>
    <t align='center'><img size='5' image='%1'/></t><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>Bandits have taken over a Medical Outpost!</t><br/><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>Go take their Medical Supplies!</t><br/><br/>
    <t size='1' font='Bitstream' align='center' color='#16DB57'>Check your Map for the location!</t><br/>",

    _pic
    ];
    [nil,nil,rHINT,_hint] call RE;

    //DZMSAISpawn spawns AI to the mission.
    //Usage: [_coords, count, skillLevel, unitArray]
    [[(_coords select 0) - 20, (_coords select 1) - 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) + 10, (_coords select 1) + 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) - 10, (_coords select 1) - 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;
    [[(_coords select 0) + 20, (_coords select 1) + 15,0],4,0,"DZMSUnitsMinor"] call DZMSAISpawn;
    sleep 3;

     

    And see if it works, probably derp from my part :O

  12. i use DZMS and WAI, i try to implement in both, for each mission i dont really know how to create functions like Vampire mentioned above :P

     

    Well the Monitor works but doesn't display any picture, i thought if i call the variable "_crate" it would associate with: 

    _crate = createVehicle ["USVehicleBox",_coords,[], 0, "CAN_COLLIDE"];
    

    So therefore appear's a picture of a crate, or am i wrong?

     

    Anyway here is an example of a mission i modified to include this monitor.

     

    /*


    AN-2 Bandit Supply Drop by Vampire
    Example Code by Halv
    */

    private ["_missName","_coords","_plane","_aiGrp","_pilot","_wp","_wp_pos","_loop","_half","_newPos","_plane2","_chute","_box","_dropDir","_wp2","_fallCount","_boxFin","_pic","_hint"];

    //Name of the Mission
    _missName = "Supply Drop";

    //DZMSFindPos loops BIS_fnc_findSafePos until it gets a valid result
    _coords = call DZMSFindPos;

    _pic = (gettext (configFile >> 'CfgVehicles' >> (typeof vehicle _plane) >> 'picture'));
    _hint = parseText format ["
    <t size='1.4' font='Bitstream' align='center' color='#DDDDDD'>Supply Drop</t><br/><br/>
    <t align='center'><img size='5' image='%1'/></t><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>An C130 with Bandit Supplies is Flying In!</t><br/><br/>
    <t size='1.15' font='Bitstream' align='center' color='#C70000'>Get to the Location and Capture the Package!</t><br/><br/>
    <t size='1' font='Bitstream' align='center' color='#16DB57'>Check your Map for the location!</t><br/>",

    _pic
    ];
    [nil,nil,rHINT,_hint] call RE;

    [nil,nil,rTitleText,"An C130 with Bandit Supplies is Flying In!\nGet to the Location and Capture the Package!", "PLAIN",10] call RE;

    //DZMSAddMajMarker is a simple script that adds a marker to the location
    [_coords,_missname] ExecVM DZMSAddMajMarker;

    //Lets get the C130 Flying
    _plane = createVehicle ["C130J_US_EP1", [0,0,500], [], 0, "FLY"];
    [_plane] call DZMSProtectObj;
    _plane engineOn true;
    _plane flyInHeight 150;
    _plane forceSpeed 175;

    //Empty the plane
    clearMagazineCargoGlobal _plane;
    clearWeaponCargoGlobal _plane;

    //Lets make AI for the plane and get them in it
    _aiGrp = creategroup east;

    _pilot = _aiGrp createUnit ["SurvivorW2_DZ",getPos _plane,[],0,"FORM"];
    _pilot moveindriver _plane;
    _pilot assignAsDriver _plane;

    _wp = _aiGrp addWaypoint [[(_coords select 0), (_coords select 1),150], 0];
    _wp setWaypointType "MOVE";
    _wp setWaypointBehaviour "CARELESS";
    _wp_pos = waypointPosition [_aiGrp,1];

    _pilot addWeapon 'NVGoggles';
    _pilot addWeapon 'ItemCompass';
    _pilot addWeapon 'ItemRadio';
    _pilot addWeapon 'ItemMap';
    _pilot addWeapon 'ItemGPS';
    sleep 5;

    //DZMSAISpawn spawns AI to the mission.
    //Usage: [_coords, count, skillLevel, unitArray]
    [_coords,6,1,"DZMSUnitsMajor"] call DZMSAISpawn;
    sleep 5;
    [_coords,6,1,"DZMSUnitsMajor"] call DZMSAISpawn;
    sleep 5;
    [_coords,4,1,"DZMSUnitsMajor"] call DZMSAISpawn;
    sleep 5;

    _loop = true;
    _half = false;
    while {_loop} do {
    if (!Alive _plane OR !Alive _pilot) then {
    sleep 5;

    // We are going to pretend the plane was shot down nearby
    deleteVehicle _plane;
    deleteVehicle _pilot;

    _newPos = [(_coords select 0) + (random(2000)),(_coords select 1) - (random(2000)),0];

    if (surfaceIsWater _newPos) then {
    //newPos is water, so lets just drop it on mark
    //This is a temporary fix for needed logic
    _newPos = _coords;
    };

    //Create the plane and kill it
    _plane2 = createVehicle ["C130J_US_EP1", [(_newPos select 0),(_newPos select 1),200], [], 0, "FLY"];
    [_plane2] call DZMSProtectObj;
    _plane2 engineOn true;
    _plane2 flyInHeight 150;
    _plane2 forceSpeed 175;
    sleep 2;
    _plane2 setDamage 1;

    //Update the location
    [_coords,"C130J_wreck_EP1"] ExecVM DZMSAddMajMarker;
    [nil,nil,rTitleText,"The C130 was shot down by UN Peacekeepers!\nGo Find the Supplies!", "PLAIN",10] call RE;

    _chute = createVehicle ["ParachuteMediumEast", [(_newPos select 0),(_newPos select 1),200], [], 0, "FLY"];
    [_chute] call DZMSProtectObj;
    _box = createVehicle ["USVehicleBox", [(_newPos select 0),(_newPos select 1),200],[], 0, "CAN_COLLIDE"];
    [_box] call DZMSProtectObj;
    _box attachTo [_chute, [0, 0, 1]];

    _loop = false;
    };

    if ((Alive _plane) AND (Alive _pilot) AND ((_plane distance _wp_pos) <= 1200) AND (!(_half))) then {
    [nil,nil,rTitleText,"The C130 is only 1200m out from the drop point!", "PLAIN",10] call RE;

    //Keep on truckin'
    _plane forceSpeed 175;
    _plane flyInHeight 135;
    _plane setspeedmode "LIMITED";
    _half = true;
    };

    if ((Alive _plane) AND (Alive _pilot) AND ((_plane distance _wp_pos) <= 200)) then {
    //Drop the package

    _dropDir = getDir _plane;
    _newPos = [(getPosATL _plane select 0) - 15*sin(_dropDir), (getPosATL _plane select 1) - 15*cos(_dropDir), (getPosATL _plane select 2) - 10];

    [nil,nil,rTitleText,"The C130 has reached the location and dropped the cargo!", "PLAIN",10] call RE;

    _chute = createVehicle ["ParachuteMediumEast", _newPos, [], 0, "FLY"];
    [_chute] call DZMSProtectObj;
    _box = createVehicle ["USVehicleBox", _newPos,[], 0, "CAN_COLLIDE"];
    [_box] call DZMSProtectObj;
    _box attachTo [_chute, [0, 0, 1]];

    deleteWaypoint [_aiGrp, 1];
    _wp2 = _aiGrp addWaypoint [[0,0,150], 0];
    _wp2 setWaypointType "MOVE";
    _wp2 setWaypointBehaviour "CARELESS";
    _plane forceSpeed 350;
    _plane setSpeedmode "FULL";

    _loop = false;
    };
    };

    //The box was dropped, lets get it on the ground.
    _fallCount = 0;
    while {_fallCount < 45} do {
    if (((getPos _box) select 2) < 1) then {_fallCount = 46};
    sleep 0.1;
    _fallCount = _fallCount + 0.1;
    };

    detach _box;
    _box setpos [(getpos _box select 0), (getpos _box select 1), 0];
    _boxFin = createVehicle ["USVehicleBox",[(getpos _box select 0),(getpos _box select 1), 0],[],0,"CAN_COLLIDE"];
    deletevehicle _box;
    deletevehicle _chute;
    [[(getpos _boxFin select 0), (getpos _boxFin select 1), 0],"C130 Cargo"] ExecVM DZMSAddMajMarker;
    clearWeaponCargoGlobal _boxFin;
    clearMagazineCargoGlobal _boxFin;
    clearBackpackCargoGlobal _boxFin;
    [_boxFin,"supply"] ExecVM DZMSBoxSetup;
    [_boxFin] call DZMSProtectObj;

    //Wait until the player is within 30 meters and also meets the kill req
    [position _boxFin,"DZMSUnitsMajor"] call DZMSWaitMissionComp;

    //Let everyone know the mission is over
    [nil,nil,rTitleText,"The C130 Cargo has been Secured by Survivors!", "PLAIN",6] call RE;
    diag_log text format["[DZMS]: Major SM2 C130 Drop Mission has Ended."];
    deleteMarker "DZMSMajMarker";
    deleteMarker "DZMSMajDot";

    //Let the timer know the mission is over
    DZMSMajDone = true;

×
×
  • Create New...