Compare commits
No commits in common. "12ca9aca540adf0a53610a24daa9d94284bd0e20" and "d9df5d694017ebea82214e2d9ab8af54c1b94e90" have entirely different histories.
12ca9aca54
...
d9df5d6940
24
ghost.lua
24
ghost.lua
@ -75,15 +75,6 @@ local function Columns(line, sep)
|
|||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
local function compareTables(a, b, ...)
|
|
||||||
for _, key in ipairs({...}) do
|
|
||||||
if a[key] != b[key] then
|
|
||||||
return false
|
|
||||||
end
|
|
||||||
end
|
|
||||||
return true
|
|
||||||
end
|
|
||||||
|
|
||||||
Ghosts = {
|
Ghosts = {
|
||||||
map,
|
map,
|
||||||
players = {},
|
players = {},
|
||||||
@ -458,7 +449,7 @@ Client = {
|
|||||||
end,
|
end,
|
||||||
|
|
||||||
callback = function(data, this)
|
callback = function(data, this)
|
||||||
local header, storedHeader
|
local header
|
||||||
local cmd = 1
|
local cmd = 1
|
||||||
for str in data:gmatch("(.-)\n") do
|
for str in data:gmatch("(.-)\n") do
|
||||||
if Client.data:busy(cmd) then
|
if Client.data:busy(cmd) then
|
||||||
@ -466,18 +457,7 @@ Client = {
|
|||||||
end
|
end
|
||||||
|
|
||||||
header = Index.parseHeader(str)
|
header = Index.parseHeader(str)
|
||||||
storedHeader = Index:find(header)
|
if not Index:find(header) then
|
||||||
if not (
|
|
||||||
storedHeader
|
|
||||||
and compareTables(
|
|
||||||
header,
|
|
||||||
storedHeader,
|
|
||||||
"time",
|
|
||||||
"flags",
|
|
||||||
"skin",
|
|
||||||
"color"
|
|
||||||
)
|
|
||||||
) then
|
|
||||||
local tr = Transmitter("GC", {stream = true})
|
local tr = Transmitter("GC", {stream = true})
|
||||||
tr:transmit(cmd)
|
tr:transmit(cmd)
|
||||||
Client.data:listen(header, cmd)
|
Client.data:listen(header, cmd)
|
||||||
|
@ -1212,7 +1212,7 @@ local function saveTime(player)
|
|||||||
MapRecords = GetMapRecords(gamemap, mapChecksum(gamemap), ST_SEP)
|
MapRecords = GetMapRecords(gamemap, mapChecksum(gamemap), ST_SEP)
|
||||||
|
|
||||||
-- Set the updated ScoreTable
|
-- Set the updated ScoreTable
|
||||||
ScoreTable = MapRecords[ST_SEP & Flags]
|
ScoreTable = MapRecords[Flags]
|
||||||
|
|
||||||
for i, score in ipairs(ScoreTable) do
|
for i, score in ipairs(ScoreTable) do
|
||||||
if score.name != player.name then continue end
|
if score.name != player.name then continue end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user