• Gmod Conques System Help
    4 replies, posted
So i got on my militaryRP server a conquest system and i want to make 2 teams NK and US and add jobs for each team and i have no idea how to do it please help. Here is the script: function ConquestSystem.GetPointColour(point) if point.CategoryEnabled then if ConquestSystem.Config.DarkRP then if LocalPlayer():getJobTable().command == point.Owner then return LocalPlayer():getJobTable().color end return Color(255,0,0,255) else -- find that team for k,v in pairs(team.GetAllTeams()) do if v.Name == point.Owner then return v.Color end end return Color(255,255,255,255) end else if ConquestSystem.Config.DarkRP then return ConquestSystem.FindTeamByCommand(point.Owner).color else -- find that team for k,v in pairs(team.GetAllTeams()) do if v.Name == point.Owner then return v.Color end end return Color(0,0,255,255) end end end function ConquestSystem.GetUserColour(ply) -- default system, returns darkrp team if flag set, normal team if not. if ConquestSystem.Config.DarkRP then local job = RPExtraTeams[ply:Team()] return job.color else return team.GetColor(ply:Team()) end end function ConquestSystem.GetTeamName(point, ply) if ConquestSystem.Config.DarkRP then local job = RPExtraTeams[ply:Team()] if point.CategoryEnabled then return job.category else return job.command end else return team.GetName(ply:Team()) end end function ConquestSystem.GetTeamNameWithoutCategory(ply) if ConquestSystem.Config.DarkRP then local job = RPExtraTeams[ply:Team()] return job.command else return team.GetName(ply:Team()) end end function ConquestSystem.GetTeamShape(point, ply) if ConquestSystem.Config.TeamShapes[ConquestSystem.GetTeamName(point, ply)] ~= nil then return ConquestSystem.Config.TeamShapes[ConquestSystem.GetTeamName(point, ply)] end return 32 end function ConquestSystem.FindTeamByCommand(command) for k,v in pairs(RPExtraTeams) do if v.command == command then return v end end end function ConquestSystem.GetPlayerOwnedPoints(ply) local ownedPoints = {} local points if SERVER then points = ConquestSystem.Points else points = ConquestSystem.CapturePoints end for k,v in pairs(points) do local owner = v.Owner local relativeName = ConquestSystem.GetTeamName(v, ply) if (owner == relativeName) then table.insert(ownedPoints, v) end end return ownedPoints end Thanks for everyone who is helping!
[QUOTE=Shenesis;52759302]Have you tried contacting the author of the script? Just to clarify, I don't really intend to spend minutes trying to understand this code and adapt it for you. I kind of assume you have some level in scripting. Have you tried editing this script at all?[/QUOTE] I don't know lua too much and the author said he will not update or fix the addon. And its the only conquest system on the internet
The closest I could get to fixing something like this was the colour of the control point, simple change this [CODE]return Color(255,0,0,255)[/CODE] to this [CODE]return ConquestSystem.FindTeamByCommand(point.Owner).color[/CODE] That way when youre using the category based mode, jobs under the same category will not be able to capture that point, and it will show all teams the colour of who captured the point instead of being red, if you are not the job that captured it.
[QUOTE=Stanstar22;52762100]The closest I could get to fixing something like this was the colour of the control point, simple change this [CODE]return Color(255,0,0,255)[/CODE] to this [CODE]return ConquestSystem.FindTeamByCommand(point.Owner).color[/CODE] That way when youre using the category based mode, jobs under the same category will not be able to capture that point, and it will show all teams the colour of who captured the point instead of being red, if you are not the job that captured it.[/QUOTE] But is there way to combine categorys?
Sorry, you need to Log In to post a reply to this thread.