• Is It Possible To Force The Round To End In Murder Through An Addon?
    2 replies, posted
I'm writing a round timer addon for the Murder gamemode and when the timer runs out, I'd like to end the round gracefully without having to kill everyone. Does anyone know how to do this? I can't seem to find a command or hook I can run.
[QUOTE]// 1 Murderer wins // 2 Murderer loses // 3 Murderer rage quit EndTheRound(reason, murderer)[/QUOTE] Try this?
Unable to call that. I'm trying to include the sv_rounds file so I can call that but it's not going so well... Any help? Here's my code to include it and test it to see what I get. [CODE] if(CLIENT) then net.Receive("test", function() local test = net.ReadString() print(test) end) end if (SERVER) then local sv_rounds = file.Find( "gamemodes/murder/gamemode/sv_rounds.lua", "MOD" ) include(sv_rounds[1]) util.AddNetworkString("test") net.Start("test") net.WriteString(sv_rounds[1]) net.Broadcast() end [/CODE] On the client end, I see [QUOTE]sv_rounds.lua[/QUOTE] printed back to me. On the server side, I get [QUOTE]Lua Error: Couldn't include file 'sv_rounds.lua' (File not found) (@addons/murder round timer/lua/autorun/timer.lua (line 30))[/QUOTE] [B]Edit:[/B] Nevermind, I was able to call it with: [CODE]gamemode.Call("EndTheRound", 2, team.GetPlayers(2)[1])[/CODE] team.GetPlayers() being a placeholder for now. Thanks for the help!
Sorry, you need to Log In to post a reply to this thread.