Garry's Mod

Garry's Mod

Turret & Emplacement placers
21 Comments
Доктор Коньяк 21 Jun, 2023 @ 6:39am 
Это прекрасно! Спасибо! :p2chell:
Omen 14 Mar, 2021 @ 9:33pm 
Oh cool, I can use this for the engineer class on The Horde Gamemode, ty
>KB> >KEKSQUAD 12 Oct, 2020 @ 2:08am 
Asked the second last one kind of weird whoops
>KB> >KEKSQUAD 12 Oct, 2020 @ 2:07am 
Okay, but I want it to work on both teams. I have this here

/code Shpigun.TeamWL = {
"Combine",
"Rebels"
}
end)
Attache  [author] 11 Oct, 2020 @ 5:19pm 
I don't see how it wouldn't work. Just input one team inside, that should be it
>KB> >KEKSQUAD 11 Oct, 2020 @ 1:36am 
Okay so can I only make it friendly towards one team then?
Attache  [author] 10 Oct, 2020 @ 6:28pm 
I mean that with whitelist turned off it won't work properly
>KB> >KEKSQUAD 7 Oct, 2020 @ 11:38pm 
Did you happen to leave any debug methods behind?
>KB> >KEKSQUAD 7 Oct, 2020 @ 8:05pm 
And I am using the latest version.
>KB> >KEKSQUAD 7 Oct, 2020 @ 6:36pm 
I don't have any prop protection and I was able to kill the enemy with my crowbar, but not the sentry.
Attache  [author] 7 Oct, 2020 @ 12:40pm 
Probably won't work without whitelist at all, tested on darkrp
Attache  [author] 7 Oct, 2020 @ 12:39pm 
Sure you're using the lattest version? Can't replicate the problem on my side, might be your prop protection or something.
>KB> >KEKSQUAD 7 Oct, 2020 @ 11:05am 
It also still leaves behind the PHX cube for some reason whenever it's moved.
>KB> >KEKSQUAD 7 Oct, 2020 @ 11:05am 
Hey, so I noticed a peculiar bug just now, as I've decided to revisit this with an extracted version by disabling the whitelist. The turret does shoot at the enemy and ignores the owner, but it doesn't do any damage and at some point just ignores everyone altogether.
Attache  [author] 11 Aug, 2020 @ 5:51am 
fixed all the bugs, now works as intended
Attache  [author] 1 Feb, 2020 @ 6:52am 
May be, then,
Shpigun.TeamWL = {
[1]=true,
[2]=true,
}
try that?
Attache  [author] 1 Feb, 2020 @ 6:48am 
I found in fortfights this code:
[code]local function SetPlayerTurretRelationship(ply)
for k, v in pairs(ents.FindByClass( "npc_turret_floor")) do
local turretTeam = -1
if v:GetName() == "turret_Rebel" then
turretTeam = 1
elseif v:GetName() == "turret_Combine" then
turretTeam = 2
end
if turretTeam == ply:Team() or ply:Team() == TEAM_SPECTATOR or ply:Team() == TEAM_UNASSIGNED then
v:AddEntityRelationship(ply, D_LI, 99)
else
v:AddEntityRelationship(ply, D_HT, 99)
end
end
end[/code]
seems like fortfights gamemode already has functionality similiar to what's been done in this addon?
>KB> >KEKSQUAD 29 Jan, 2020 @ 12:35am 
Hey, so I noticed the turret will attack teammates on Fort Fights. It uses the "ply:Team()" Lua method of 1 for Rebels, 2 for Combine. Not sure how I'd go about adding that into the config with what is limited in the indicated file above.
Tactic_N7 the Comrade 3 Oct, 2019 @ 11:32am 
Buuut.. you made it.
:summer2019boost::cozyspaceengineersc:
Attache  [author] 2 Oct, 2019 @ 2:32pm 
I haven't added support for TTT nor TTT2 specifically, it was tested on Sandbox and works on DarkRP. In sandbox it appears in Other tab of Q-menu (spawnmenu). As it has TEAM-based whitelist, it could theoretically work for TTT but after your comment I'll consider testing it on TTT.
Cuckoo 2 Oct, 2019 @ 1:41am 
Hmm. We tried this out in TTT, but neither the Turret Placer nor the Gun Emplacement Placer appeared in the shop.

We run TTT2 (which has a built-in shop editor), so I can normally see all the items which are loaded, even if they're not currently linked to any roles, or are set to not-buyable by default. But I can't seem to find either of these weapons anywhere.