Starting Weapons

Starting Weapons

« posted: Feb 08, 2020, 07:47 PM »
Hello all,

Ive been looking around on here and the internet but i cant seem to find the answer.

Where do i go to edit what weapons players spawn in with? im not a fan of spawning in with only a 45 acp any help would be appreciated!

Just a secondary question but not a huge deal; anyone know where to get the grass cutting mod so you can remove grass around a player?

Re: Starting Weapons

« Reply #1 posted: Feb 08, 2020, 09:48 PM »
I figured it out for anyone wondering
Client > Functions > playerSetupGear.sqf

and here is what i used
Code: [Select]
// ******************************************************************************************
// * This project is licensed under the GNU Affero GPL v3. Copyright © 2014 A3Wasteland.com *
// ******************************************************************************************
// @file Name: playerSetupGear.sqf
// @file Author: [GoT] JoSchaap, AgentRev

private ["_player", "_uniform", "_vest", "_backpack", "_headgear", "_goggles"];
_player = _this;

// Clothing is now defined in "client\functions\getDefaultClothing.sqf"

_uniform = [_player, "uniform"] call getDefaultClothing;
_vest = [_player, "vest"] call getDefaultClothing;
_backpack = [_player, "backpack"] call getDefaultClothing;
_headgear = [_player, "headgear"] call getDefaultClothing;
_goggles = [_player, "goggles"] call getDefaultClothing;

if (_uniform != "") then { _player addUniform _uniform };
if (_vest != "") then { _player addVest _vest };
if (_backpack != "") then { _player addBackpack _backpack };
if (_headgear != "") then { _player addHeadgear _headgear };
if (_goggles != "") then { _player addGoggles _goggles };

sleep 0.1;

// Remove GPS
_player unlinkItem "ItemGPS";

// Add radio
_player linkItem "ItemRadio"; //_player unlinkItem "ItemRadio";

// Remove NVG
//if (hmd _player != "") then { _player unlinkItem hmd _player };

// Add NVG
_player linkItem "NVGoggles";
_player addBackpack "B_Carryall_oli";

switch (true) do
{
case (["_medic_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "30Rnd_556x45_Stanag";
_player addWeapon "arifle_Mk20_plain_F";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addPrimaryWeaponItem "optic_Holosight";
//Handgun
_player addMagazine "16Rnd_9x21_Mag";
_player addWeapon "hgun_P07_F";
_player addItemToVest "16Rnd_9x21_Mag";
_player addItemToVest "16Rnd_9x21_Mag";
//Items
_player addItem "Medikit";
_player addItem "FirstAidKit";
_player addWeapon "Binocular";
};
case (["_engineer_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "30Rnd_556x45_Stanag";
_player addWeapon "arifle_Mk20_F";
_player addPrimaryWeaponItem "optic_aco";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
//Handgun
_player addMagazine "6Rnd_45ACP_Cylinder";
_player addWeapon "hgun_Pistol_heavy_02_F";
_player addItemToVest "6Rnd_45ACP_Cylinder";
_player addItemToVest "6Rnd_45ACP_Cylinder";
//Items
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addItem "MineDetector";
_player addItem "Toolkit";
_player addItem "SmokeShell";
_player addWeapon "Binocular";
};
case (["_soldier_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "30Rnd_556x45_Stanag";
_player addWeapon "arifle_Mk20_plain_F";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addItemToBackpack "30Rnd_556x45_Stanag";
_player addPrimaryWeaponItem "optic_Holosight";
//Handgun
_player addMagazine "16Rnd_9x21_Mag";
_player addWeapon "hgun_P07_F";
_player addItemToVest "16Rnd_9x21_Mag";
_player addItemToVest "16Rnd_9x21_Mag";
//Items
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addWeapon "Binocular";
};
case (["_sniper_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "10Rnd_762x54_Mag";
_player addWeapon "srifle_DMR_01_F";
_player addPrimaryWeaponItem "optic_Arco";
_player addItemToBackpack "10Rnd_762x54_Mag";
_player addItemToBackpack "10Rnd_762x54_Mag";
_player addItemToBackpack "10Rnd_762x54_Mag";
_player addItemToBackpack "10Rnd_762x54_Mag";
//Handgun
_player addMagazine "16Rnd_9x21_Mag";
_player addWeapon "hgun_Rook40_F";
_player addItemToVest "16Rnd_9x21_Mag";
_player addItemToVest "16Rnd_9x21_Mag";
//Items
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addWeapon "Rangefinder";
};
case (["_diver_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "20Rnd_556x45_UW_mag";
_player addWeapon "arifle_SDAR_F";
_player addItemToBackpack "20Rnd_556x45_UW_mag";
_player addItemToBackpack "20Rnd_556x45_UW_mag";
//Handgun
_player addMagazine "9Rnd_45ACP_Mag";
_player addWeapon "hgun_ACPC2_F";
_player addItemToBackpack "9Rnd_45ACP_Mag";
_player addItemToBackpack "9Rnd_45ACP_Mag";
//Items
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addItem "HandGrenade";
_player addWeapon "Binocular";
};
case (["_pilot_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "30Rnd_45ACP_Mag_SMG_01";
_player addWeapon "SMG_01_F";
_player addPrimaryWeaponItem "optic_Holosight";
//Handgun
_player addMagazine "11Rnd_45ACP_Mag";
_player addWeapon "hgun_Pistol_heavy_01_F";
//Items
_player addItemToBackpack "H_PilotHelmetFighter_O";
_player addItemToBackpack "H_PilotHelmetFighter_B";
_player addItem "30Rnd_45ACP_Mag_SMG_01";
_player addItem "30Rnd_45ACP_Mag_SMG_01";
_player addItem "11Rnd_45ACP_Mag";
_player addItem "11Rnd_45ACP_Mag";
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addWeapon "Binocular";
};
case (["_uav_", typeOf _player] call fn_findString != -1):
{
removeAllWeapons _player;
//Rifle
_player addMagazine "30Rnd_45ACP_Mag_SMG_01";
_player addWeapon "SMG_01_F";
_player addPrimaryWeaponItem "optic_Holosight";
//Handgun
_player addMagazine "11Rnd_45ACP_Mag";
_player addWeapon "hgun_Pistol_heavy_01_F";
//Items
_player addItem "30Rnd_45ACP_Mag_SMG_01";
_player addItem "30Rnd_45ACP_Mag_SMG_01";
_player addItem "11Rnd_45ACP_Mag";
_player addItem "11Rnd_45ACP_Mag";
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addItem "FirstAidKit";
_player addWeapon "Binocular";
};
};

switch (side _player) do
{
case west:
{
_player addItem "Chemlight_blue";
};
case east:
{
_player addItem "Chemlight_red";
};
case resistance:
{
_player addItem "Chemlight_green";
};
};

if (_player == player) then
{
thirstLevel = 100;
hungerLevel = 100;
};