aussie battler

[solved] Tanks DLC - Adding the Custom CAMO

20 posts in this topic

I was looking at adding the custom camos & objects addons to the new DLC Tanks.

I grabbed the script to add it from the editor:
 

_veh = createVehicle ["I_LT_01_AT_F",position player,[],0,"NONE"];
[
	_veh,
	["Indep_01",1], 
	["showTools",1,"showCamonetHull",1,"showBags",1,"showSLATHull",1]  //these are all the extra addons to this DLC tanks
] call BIS_fnc_initVehicle;


Not sure if should try & add it to cfg_vehicleCustoms (would need to grab the directory to all the picture files).

or the quick dirty way:

Add it to ExileServer_object_vehicle_createPersistentVehicle.sqf and make every tank have the skins automatically added to the tank when it spawns in?
 

 if (typeOf _vehicleObject player == "I_LT_01_AT_F") then
{
_vehicleObject ["showTools",1,"showCamonetHull",1,"showBags",1,"showSLATHull",1];
}call BIS_fnc_initVehicle; 

Has anyone added the DLC skins to their server yet?

20180712144813_1.jpg

Edited by aussie battler

Share this post


Link to post
Share on other sites
Advertisement

@kuplion Do you see what I am doing wrong here? Trying to get the extra camo to spawn on the DLC Tanks.

I put htis code into ExileServer_object_vehicle_createPersistentVehicle:

But It just shoots blanks when you buy the Tank...

//DLC TANKS 
 if (_className _vehicleObject player == "I_LT_01_AT_F") then
{
_vehicleObject ["showTools",1,"showCamonetHull",1,"showBags",1,"showSLATHull",1];
}call BIS_fnc_initVehicle; 
//DLC TANKS 

 


//DLC TANKS 
 if (_className _vehicleObject player == "I_LT_01_AT_F") then
{
_vehicleObject ["showTools",1,"showCamonetHull",1,"showBags",1,"showSLATHull",1];
}; 
//DLC TANKS 


 

Spoiler

/**
 * ExileServer_object_vehicle_createPersistentVehicle
 *
 * Exile Mod
 * www.exilemod.com
 * © 2015 Exile Mod Team
 *
 * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
 */
 
private["_className", "_position", "_direction", "_usePositionATL", "_pinCode", "_vehicleObject"];
_className = _this select 0;
_position = _this select 1;
_direction = _this select 2;
_usePositionATL = _this select 3;
_pinCode = _this select 4;
_vehicleObject = [_className, _position, _direction, _usePositionATL] call ExileServer_object_vehicle_carefulCreateVehicle;
_vehicleObject setVariable ["ExileIsPersistent", true];
_vehicleObject setVariable ["ExileAccessCode", _pinCode];
_vehicleObject addEventHandler ["GetOut", {_this call ExileServer_object_vehicle_event_onGetOut}];
_vehicleObject addEventHandler ["GetIn", {_this call ExileServer_object_vehicle_event_onGetIn}];
_vehicleObject addMPEventHandler ["MPKilled", { if !(isServer) exitWith {}; _this call ExileServer_object_vehicle_event_onMPKilled;}];
//DLC TANKS
if(_className == "I_LT_01_AT_F") then
{
_vehicleObject ["showTools",1,"showCamonetHull",1,"showBags",1,"showSLATHull",1];
};
//DLC TANKS
if (getNumber(missionConfigFile >> "CfgSimulation" >> "enableDynamicSimulation") isEqualTo 1) then
{
    _vehicleObject enableDynamicSimulation true;
}
else
{
    _vehicleObject call ExileServer_system_simulationMonitor_addVehicle;
};
_vehicleObject

 

Share this post


Link to post
Share on other sites

in ExileServer_object_vehicle_carefulCreateVehicle.sqf

if(_vehicleClassName == "B_AFV_Wheeled_01_cannon_F") then
{
	[_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",0,"showSLATTurret",0]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_T_AFV_Wheeled_01_cannon_F") then
{
	[_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",0,"showSLATTurret",0]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_AFV_Wheeled_01_up_cannon_F") then
{
	[_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showSLATTurret",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_T_AFV_Wheeled_01_up_cannon_F") then
{
	[_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showSLATTurret",1]] call BIS_fnc_initVehicle;
};

 

  • Like 4

Share this post


Link to post
Share on other sites

here is my ExileServer_object_vehicle_carefulCreateVehicle.sqf if anyone needs has all the arma 3 tanks including dlc

Spoiler

/**
 * ExileServer_object_vehicle_carefulCreateVehicle
 *
 * Exile Mod
 * www.exilemod.com
 * © 2015 Exile Mod Team
 *
 * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. 
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
 */
 
private["_vehicleClassName", "_position", "_direction", "_usePositionATL", "_temporaryPositionInOuterSpace", "_vehicleObject"];
_vehicleClassName = _this select 0;
_position = _this select 1;
_direction = _this select 2;
_usePositionATL = _this select 3;
_temporaryPositionInOuterSpace = 
[
    (_position select 0) - 250 + (random 500),
    (_position select 1) - 250 + (random 500),
    1000 + (random 1000)
];
_vehicleObject = createVehicle [_vehicleClassName, _temporaryPositionInOuterSpace, [], 0, "CAN_COLLIDE"];
_vehicleObject allowDamage false;
_vehicleObject removeAllEventHandlers "HandleDamage";
_vehicleObject addEventHandler["HandleDamage", {false}];
_vehicleObject setVelocity [0, 0, 0];
if ((typeName _direction) isEqualTo "ARRAY") then 
{
    _vehicleObject setVectorDirAndUp _direction;
}
else 
{
    _vehicleObject setDir _direction;
};
if (_usePositionATL) then
{
    _vehicleObject setPosATL _position;
}
else 
{
    _vehicleObject setPosASL _position;
};
_vehicleObject setVelocity [0, 0, 0];
_vehicleObject allowDamage true;
_vehicleObject removeAllEventHandlers "HandleDamage";
_vehicleObject setDamage 0;
clearBackpackCargoGlobal _vehicleObject;
clearItemCargoGlobal _vehicleObject;
clearMagazineCargoGlobal _vehicleObject;
clearWeaponCargoGlobal _vehicleObject;
if (_vehicleClassName isKindOf "I_UGV_01_F") then 
{
    createVehicleCrew _vehicleObject;
};
if (getNumber (configFile >> "CfgSettings" >> "VehicleSpawn" >> "nightVision") isEqualTo 0) then 
{
    _vehicleObject disableNVGEquipment true;
};
if (getNumber (configFile >> "CfgSettings" >> "VehicleSpawn" >> "thermalVision") isEqualTo 0) then 
{
    _vehicleObject disableTIEquipment true;
};

/////////////////////////////
///////// Tanks DLC /////////
/////////////////////////////

/////////////////////////////
///// Rhino
/////////////////////////////

if(_vehicleClassName == "B_AFV_Wheeled_01_cannon_F") then
{
    [_vehicleObject,["Sand",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_T_AFV_Wheeled_01_cannon_F") then
{
    [_vehicleObject,["Green",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_AFV_Wheeled_01_up_cannon_F") then
{
    [_vehicleObject,["Sand",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_T_AFV_Wheeled_01_up_cannon_F") then
{
    [_vehicleObject,["Green",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// T-140
/////////////////////////////

if(_vehicleClassName == "O_MBT_04_cannon_F") then
{
    [_vehicleObject,["Hex",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "O_T_MBT_04_cannon_F") then
{
    [_vehicleObject,["GreenHex",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "O_MBT_04_command_F") then
{
    [_vehicleObject,["Hex",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "O_T_MBT_04_command_F") then
{
    [_vehicleObject,["GreenHex",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// Nyx
/////////////////////////////

if(_vehicleClassName == "I_LT_01_AT_F") then
{
    [_vehicleObject,["Jungle",1],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "I_LT_01_scout_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "I_LT_01_AA_F") then
{
    [_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "I_LT_01_cannon_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///////// APC Tanks /////////
/////////////////////////////

/////////////////////////////
///// AFV-4 Gorgon
/////////////////////////////

if(_vehicleClassName == "I_APC_Wheeled_03_cannon_F") then
{
    [_vehicleObject,["Jungle",0],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};
if(_vehicleClassName == "B_APC_Wheeled_03_cannon_F") then
{
    [_vehicleObject,["Jungle",0],["showBags",1,"showCamonetHull",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// BTR-K Kamysh
/////////////////////////////

if(_vehicleClassName == "O_T_APC_Tracked_02_cannon_ghex_F") then
{
    [_vehicleObject,["GreenHex",1],["showBags",1,"showCamonetHull","showSLATHull",1,"showTracks",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "O_APC_Tracked_02_cannon_F") then
{
    [_vehicleObject,["Hex",1],["showBags",1,"showCamonetHull","showSLATHull",1,"showTracks",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// AMV-7 Marshall
/////////////////////////////

if(_vehicleClassName == "B_APC_Wheeled_01_cannon_F") then
{
    [_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showSLATTurret",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_T_APC_Wheeled_01_cannon_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showSLATTurret",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// CRV-6e Bobcat
/////////////////////////////

if(_vehicleClassName == "B_APC_Tracked_01_CRV_F") then
{
    [_vehicleObject,["Sand",1],["showBags",1,"showAmmoBoxes",1,"showRoadWheels",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_T_APC_Tracked_01_CRV_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showAmmoBoxes",1,"showRoadWheels",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// FV-720 Mora
/////////////////////////////

if(_vehicleClassName == "I_APC_tracked_03_cannon_F") then
{
    [_vehicleObject,["Sand",0],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showSLATTurret",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// IFV-6a Cheetah
/////////////////////////////

if(_vehicleClassName == "B_APC_Tracked_01_AA_F") then
{
    [_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_T_APC_Tracked_01_AA_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// IFV-6c Panther
/////////////////////////////

if(_vehicleClassName == "B_T_APC_Tracked_01_rcws_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_APC_Tracked_01_rcws_F") then
{
    [_vehicleObject,["Sand",1],["showBags",1,"showCamonetHull",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// MSE-3 Marid
/////////////////////////////

if(_vehicleClassName == "O_APC_Wheeled_02_rcws_v2_F") then
{
    [_vehicleObject,["Hex",1],["showBags",1,"showCamonetHull",1,"showCanisters",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "O_T_APC_Wheeled_02_rcws_v2_ghex_F") then
{
    [_vehicleObject,["GreenHex",1],["showBags",1,"showCamonetHull",1,"showCanisters",1,"showSLATHull",1,"showTools",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// ZSU-39 Tigris
/////////////////////////////

if(_vehicleClassName == "O_APC_Tracked_02_AA_F") then
{
    [_vehicleObject,["Hex",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showTracks",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "O_T_APC_Tracked_02_AA_ghex_F") then
{
    [_vehicleObject,["GreenHex",1],["showCamonetHull",1,"showCamonetTurret",1,"showSLATHull",1,"showTracks",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
/////////// Tanks ///////////
/////////////////////////////

/////////////////////////////
///// M2A1/4 Slammer/UP
/////////////////////////////

if(_vehicleClassName == "B_T_MBT_01_cannon_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_T_MBT_01_TUSK_F") then
{
    [_vehicleObject,["Olive",1],["showBags",1,"showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// MBT-52 Kuma
/////////////////////////////

if(_vehicleClassName == "I_MBT_03_cannon_F") then
{
    [_vehicleObject,["Olive",0],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};


/////////////////////////////
///// T-100 Varsuk
/////////////////////////////

if(_vehicleClassName == "O_T_MBT_02_cannon_ghex_F") then
{
    [_vehicleObject,["GreenHex",1],["showCamonetHull",1,"showCamonetTurret",1,"showWoodLog",1]] call BIS_fnc_initVehicle;
};

/////////////////////////////
///// M5 Sandstorm
/////////////////////////////

if(_vehicleClassName == "B_MBT_01_mlrs_F") then
{
    [_vehicleObject,["Sand",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

if(_vehicleClassName == "B_T_MBT_01_mlrs_F") then
{
    [_vehicleObject,["Olive",1],["showCamonetHull",1,"showCamonetTurret",1]] call BIS_fnc_initVehicle;
};

_vehicleObject

 

  • Like 2

Share this post


Link to post
Share on other sites
Advertisement

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.