Skip to content

Commit a55c1a3

Browse files
committed
Small change, write the timestamp as hex to avoid scientific representation.
1 parent cbd073b commit a55c1a3

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Scripts/net/DCSServerBot/DCSServerBot.lua

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ dcsbot.sendBotTable = dcsbot.sendBotTable or function (tbl, channel)
4949
return
5050
end
5151

52-
local msg_id = tostring(math.floor(socket.gettime() * 1e6))
52+
local ts = math.floor(socket.gettime() * 1e6)
53+
local msg_id = string.format("%X", ts)
5354
local total_parts = math.ceil(#msg / MAX_CHUNK)
5455

5556
for part = 1, total_parts do

Scripts/net/DCSServerBot/DCSServerBotUtils.lua

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ function sendBotTable(tbl, channel)
5353
return
5454
end
5555

56-
local msg_id = tostring(math.floor(socket.gettime() * 1e6))
56+
local ts = math.floor(socket.gettime() * 1e6)
57+
local msg_id = string.format("%X", ts)
5758
local total_parts = math.ceil(#msg / MAX_CHUNK)
5859

5960
for part = 1, total_parts do

0 commit comments

Comments
 (0)