server-side Hotfix
wulf 21
Join Date: 2011-05-03 Member: 96875Members
<div class="IPBDescription">for gamebreaking bug in build 182</div>There is a gamebreaking bug in the current build that allows any player (even spectator) to spam any structure anywhere. Someone just used it to ruin a game and bring the server "EPIC" down. I already reported it to getsatisfaction (privately).
Looked at the code: It's an extremely simple programming error. Attached is the fixed file.
Extract it into ns2\lua. It will overwrite the original file but don't worry, it is identical to the original but one (update: 3 :) ) character (the one the programmer did wrong). And it probably will be overwritten in the next build anyways, so you don't have to worry about uninstalling it.
edit: Updated download (see below). But really doesn't matter which version you use, both will prevent it. (this one is just more correct from a programmers standpoint)
Looked at the code: It's an extremely simple programming error. Attached is the fixed file.
Extract it into ns2\lua. It will overwrite the original file but don't worry, it is identical to the original but one (update: 3 :) ) character (the one the programmer did wrong). And it probably will be overwritten in the next build anyways, so you don't have to worry about uninstalling it.
edit: Updated download (see below). But really doesn't matter which version you use, both will prevent it. (this one is just more correct from a programmers standpoint)
Comments
i have inspected the diff and.. without having any deeper knowledge of NS2's lua code...
calling client:GetControllingPlayer() does not make sence if client == nil... hence
i suggest using "if client ~= nil <b>and</b> Shared.GetCheatsEnabled() then" instead of "if client <b>=</b>= nil or Shared.GetCheatsEnabled() then"
But you don't want to use this from the server console anyway (client == nil happens only if you put the command into the server console). So it doesn't cause anything. I could have commented it out completely but didn't want it to be too obvious. But now that you mentioned it, I'll update it.
yes. ~= (not equal) is the complete opposite of == (equal). Just like this sentence where you put in a comma at another place and the sense changes. pure logic XD
Oh nice, time to hop on :).
Thanks volc for telling me.