1
0
mirror of https://github.com/ComfyFactory/ComfyFactorio.git synced 2025-01-06 00:23:49 +02:00

Update server.lua

Added new command.

Server.stop_scenario()
This commit is contained in:
Gerkiz 2020-02-25 22:29:51 +01:00 committed by GitHub
parent 25adfe5279
commit 202aca5b52
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,6 +41,7 @@ local discord_embed_raw_tag = '[DISCORD-EMBED-RAW]'
local discord_admin_embed_tag = '[DISCORD-ADMIN-EMBED]'
local discord_admin_embed_raw_tag = '[DISCORD-ADMIN-EMBED-RAW]'
local start_scenario_tag = '[START-SCENARIO]'
local stop_scenario_tag = '[STOP-SCENARIO]'
local ping_tag = '[PING]'
local data_set_tag = '[DATA-SET]'
local data_get_tag = '[DATA-GET]'
@ -155,6 +156,16 @@ function Public.start_scenario(scenario_name)
raw_print(message)
end
--- Stops and saves the factorio server.
-- @usage
-- local Server = require 'utils.server'
-- Server.stop_scenario()
function Public.stop_scenario()
local message = stop_scenario_tag
raw_print(message)
end
local default_ping_token =
Token.register(
function(sent_tick)