1
0
mirror of https://github.com/ComfyFactory/ComfyFactorio.git synced 2024-12-28 23:06:38 +02:00

Small tweaks

Changes:
- Fixed an issue where boxes around captain's cabin wouldn't get upgraded on harder difficulties.
- Fish now can spawn in Poisonous Fen island lakes.
This commit is contained in:
Piratux 2023-02-02 23:09:26 +02:00
parent 0d9be8e524
commit 087ed90bb2
4 changed files with 15 additions and 12 deletions

View File

@ -340,17 +340,17 @@ function Public.afk_player_tick(player)
if Common.is_captain(player) and (not memory.run_is_protected) then
-- in this case, lose captainhood
local force = memory.force
if force and force.valid then
local message = {'pirates.roles_lose_captainhood_by_afk', player.name}
Common.notify_force(force, message)
Server.to_discord_embed_raw({'',CoreData.comfy_emojis.loops .. '[' .. memory.name .. '] ',message}, true)
end
if #Common.crew_get_nonafk_crew_members() == 1 then --don't need to bounce it around
Public.make_captain(Common.crew_get_nonafk_crew_members()[1])
else
local force = memory.force
if force and force.valid then
local message = {'pirates.roles_lose_captainhood_by_afk', player.name}
Common.notify_force(force, message)
Server.to_discord_embed_raw({'',CoreData.comfy_emojis.loops .. '[' .. memory.name .. '] ',message}, true)
end
Public.assign_captain_based_on_priorities()
end
end

View File

@ -216,7 +216,7 @@ function Public.upgrade_chests(boat, new_chest)
local scope = Public.get_scope(boat)
local surface = game.surfaces[boat.surface_name]
local ps = Common.entity_positions_from_blueprint(scope.Data.upgrade_chests.bp_str, Math.vector_sum(boat.position, scope.Data.upgrade_chests.pos))
local ps = Common.entity_positions_from_blueprint(scope.Data.entities.static.bp_str, Math.vector_sum(boat.position, scope.Data.upgrade_chests.pos))
for _, p in pairs(ps) do
local es = surface.find_entities_filtered{name = 'wooden-chest', position = p, radius = 0.05}

View File

@ -113,8 +113,8 @@ Public.areas_offleft = {
Public.entities = {
static = {
pos = { x = -34, y = 0},
-- This bp should only contain boxes, otherwise upgrading boxes (in harder difficulties won't work)
bp_str = [[0eNqVmutqGzEQhd9FvzdldZf8s69RQnGSpTU4a2M7bUPwu3edlCbQHs85EAg264+Z1Z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XY0YQ31O3wNpm5+jDnOYTt+m7ant/7/OG9H9Ph+IqJTVLtseZy/kntdPoNku6GLw==]],
}
return Public

View File

@ -61,6 +61,10 @@ function Public.terrain(args)
else
args.tiles[#args.tiles + 1] = {name = 'water-mud', position = args.p}
land = false
if math.random(1, 256) == 1 then
args.entities[#args.entities + 1] = {name = 'fish', position = args.p}
end
end
end