Hmm, something is wrong.
SandyZoneGuard1 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1863.8369140625, 3660.6931152344, 36.666610717773, 210.0, true, false)
SandyZoneGuard2 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1866.4075927734, 3662.1362304688, 36.666610717773, 210.0, true, false)
SandyZoneGuard3 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1869.6414794922, 3664.2055664063, 36.666610717773, 210.0, true, false)
SandyZoneGuard4 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1876.2316894531, 3668.3173828125, 36.277591705322, -60.0, true, false) – HEAVY BOI
SandyZoneGuard5 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1870.8305664063, 3680.8078613281, 36.530979156494, -80.0, true, false)
SandyZoneGuard6 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1870.5925292969, 3689.3947753906, 36.530979156494, -80.0, true, false)
SandyZoneGuard7 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1848.3670654297, 3668.7766113281, 36.50354385376, 180.0, true, false)
SandyZoneGuard8 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1843.4039306641, 3669.7106933594, 36.503551483154, 180.0, true, false)
SandyZoneGuard9 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1856.5505371094, 3657.0041503906, 36.587120056152, 120.0, true, false) – HEAVY BOI
SandyZoneGuard10 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1858.8133544922, 3687.3088378906, 34.267082214355, 120.0, true, false) – INSIDE DUDE
SandyZoneGuard11 = CreatePed(7, GetHashKey(“s_m_m_marine_01”), 1851.2963867188, 3683.5339355469, 34.267082214355, -60.0, true, false) – INSIDE DUDE
local GuardList = {
SandyZoneGuard1,
SandyZoneGuard2,
SandyZoneGuard3,
SandyZoneGuard4,
SandyZoneGuard5,
SandyZoneGuard6,
SandyZoneGuard7,
SandyZoneGuard8,
SandyZoneGuard9,
SandyZoneGuard10,
SandyZoneGuard11
}
setGuardSettings(GuardList)
function setGuardSettings(GuardList)
for key, guard in GuardList do – we iterate the GuardList
SetPedRelationshipGroupHash(guard, GetHashKey(“armymen”)) – for each Guard we set the ped relation
SetPedRandomComponentVariation(guard, false)
SetPedAccuracy(guard, 100)
SetPedSeeingRange(guard, 80.0)
SetPedHearingRange(guard, 80.0)
SetPedCombatMovement(guard, 0)
SetPedInfiniteAmmo(guard, true, GetHashKey(“WEAPON_CARBINETRIFLE”))
SetPedInfiniteAmmo(guard, true, GetHashKey(“WEAPON_SMG”))
SetPedInfiniteAmmo(guard, true, GetHashKey(“WEAPON_PISTOL50”))
SetPedInfiniteAmmo(guard, true, GetHashKey(“WEAPON_PUMPSHOTGUN”))
SetPedInfiniteAmmo(guard, true, GetHashKey(“WEAPON_HEAVYSNIPER”))
SetPedArmour(guard, 100)
SetPedSuffersCriticalHits(guard, false)
end
end