Ulysses

General => Developers Corner => Topic started by: JJD on November 11, 2016, 06:40:40 PM

Title: Auto slay
Post by: JJD on November 11, 2016, 06:40:40 PM
This sub-forum is only for help or discussion regarding projects created by Team Ulysses. If you are requesting help, please search the forums FIRST to make sure your question has not already been answered. If you still need help, fill in the following information.

My ULib/ULX versions (run "ulx version" in console):
ULib v..2.61
ULX v..3.71

Game mode(s) I am having this problem on: TTT

Lua errors shown in console, if any:
Code: [Select]
<insert errors here>
So, I run a TTT server and I would like it to at the beggining of the round, check for players in a group and if they are in it, slay them.
My script is in gamemode>gamemode>init.lua as follows:
local function BadBoyChecker(ply)
   if GetRoundState() == ROUND_ACTIVE then
   if ply:CheckGroup("badboys") then
   ply:Kill()
   else
end
   Im not the best at lua so I may be making on obvious mistake, but am getting it correct in theory.
Title: Re: Auto slay
Post by: iViscosity on November 11, 2016, 07:39:19 PM
If you use TTTDamagelogs (https://github.com/Tommy228/TTTDamagelogs) there is a built in !aslay command.

If you wanted to make your own though you'd need to make it in addons. I'd help more but I'm kind of busy atm. If you want to make your own I could help you later.

Also,
This sub-forum is only for help or discussion regarding projects created by Team Ulysses.
Title: Re: Auto slay
Post by: JJD on November 12, 2016, 06:38:28 AM
My mistake in wording, I mean to have a group that all time slays them. I put them in the ULX group "bad boys" maybe for mass rdming and every round they would get slayed. Essentially, they would be "banned" from playing.
Title: Re: Auto slay
Post by: roastchicken on November 14, 2016, 10:17:22 AM
Why not just ban them?
Title: Re: Auto slay
Post by: JamminR on November 14, 2016, 03:20:16 PM
Why not just ban them?
My thought exactly, but, I thought too obvious to ask.
Thank you for verbalizing my same thought.