mirror of
https://github.com/PHIDIAS0303/factorio-mod-PHI.git
synced 2025-12-27 11:05:22 +09:00
Update
This commit is contained in:
8
PHI-XC/.editorconfig
Normal file
8
PHI-XC/.editorconfig
Normal file
@@ -0,0 +1,8 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = false
|
||||
insert_final_newline = false
|
||||
1597
PHI-XC/.luacheckrc
Normal file
1597
PHI-XC/.luacheckrc
Normal file
File diff suppressed because it is too large
Load Diff
13
PHI-XC/changelog.txt
Normal file
13
PHI-XC/changelog.txt
Normal file
@@ -0,0 +1,13 @@
|
||||
---------------------------------------------------------------------------------------------------
|
||||
Version: 1.0.4
|
||||
Date: 2023-03-17
|
||||
|
||||
Added:
|
||||
- Angel Seafloor pump
|
||||
|
||||
---------------------------------------------------------------------------------------------------
|
||||
Version: 1.0.0
|
||||
Date: 2023-03-17
|
||||
|
||||
Added:
|
||||
- Base Items
|
||||
30
PHI-XC/data.lua
Normal file
30
PHI-XC/data.lua
Normal file
@@ -0,0 +1,30 @@
|
||||
local function clock_display(sec)
|
||||
local sym = ''
|
||||
|
||||
if sec < 0 then
|
||||
sec = math.abs(sec)
|
||||
sym = '- '
|
||||
end
|
||||
|
||||
local s = math.floor(sec) % 60
|
||||
local m = math.floor(sec / 60) % 60
|
||||
|
||||
if sec > 3599 then
|
||||
local h = math.floor(sec / 3600)
|
||||
return sym .. string.format('%d:%02d:%02d', h, m, s)
|
||||
else
|
||||
return sym .. string.format('%d:%02d', m, s)
|
||||
end
|
||||
end
|
||||
|
||||
script.on_nth_tick(60, function(event)
|
||||
clock_display(math.floor(game.tick / 60))
|
||||
|
||||
for _, player in pairs(game.connected_players) do
|
||||
if player.gui.top.phi_clock == nil then
|
||||
player.gui.top.add{type='button', name='phi_clock'}
|
||||
end
|
||||
|
||||
player.gui.top.phi_clock.caption = clock_display(sec)
|
||||
end
|
||||
end)
|
||||
14
PHI-XC/info.json
Normal file
14
PHI-XC/info.json
Normal file
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"name": "PHI-XC",
|
||||
"version": "1.0.0",
|
||||
"factorio_version": "1.1",
|
||||
"date": "2023-04-19",
|
||||
"title": "Phidias Clock",
|
||||
"author": "PHIDIAS0303",
|
||||
"contributers": "",
|
||||
"homepage": "",
|
||||
"description": "In game playtime",
|
||||
"dependencies": [
|
||||
"base >= 1.1.0"
|
||||
]
|
||||
}
|
||||
BIN
PHI-XC/thumbnail.png
Normal file
BIN
PHI-XC/thumbnail.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 86 KiB |
Reference in New Issue
Block a user