mirror of
https://github.com/ComfyFactory/ComfyFactorio.git
synced 2024-12-28 23:06:38 +02:00
Small tweaks and fixes
Changes: - Fixed an issue that caused player items to disappear when player left the game. But now offline player's items immediately go to captain's cabin. - Added additional tiles around furnace quest structure. - Veteran class now has 100% chance to slow an enemy. - An error is printed to player now, when he is trying to create crew proposal with max crew limit.
This commit is contained in:
parent
b579ff27f9
commit
032c4d9d4f
@ -553,6 +553,7 @@ gui_runs_launch_error_1=Gather endorsements from more pirates.
|
||||
gui_runs_launch_error_2=The number of concurrent runs on the server has reached the cap set by the admins.
|
||||
gui_runs_launch_error_3=Can't launch; at least one run needs high player capacity.
|
||||
gui_runs_launch_error_4=No sloops available. Join an existing run instead.
|
||||
gui_runs_launch_error_5=Can't create the proposal, because there are too many crews. Join some existing crew run instead.
|
||||
|
||||
gui_runs_wait_to_join=Wait to join... __1__
|
||||
|
||||
|
@ -810,11 +810,11 @@ local function event_on_player_mined_entity(event)
|
||||
|
||||
destination.dynamic_data.wood_remaining = destination.dynamic_data.wood_remaining - amount
|
||||
|
||||
give[#give + 1] = {name = 'wood', count = amount}
|
||||
|
||||
if class == Classes.enum.LUMBERJACK then
|
||||
give[#give + 1] = {name = 'wood', count = amount}
|
||||
Classes.lumberjack_bonus_items(give)
|
||||
else
|
||||
give[#give + 1] = {name = 'wood', count = amount}
|
||||
if Math.random(Balance.every_nth_tree_gives_coins) == 1 then --tuned
|
||||
local a = 5
|
||||
give[#give + 1] = {name = 'coin', count = a}
|
||||
|
@ -74,7 +74,7 @@ Public.rock_eater_damage_taken_multiplier = 0.8
|
||||
Public.rock_eater_required_stone_furnace_to_heal_count = 1
|
||||
Public.soldier_defender_summon_chance = 0.2
|
||||
Public.veteran_destroyer_summon_chance = 0.2
|
||||
Public.veteran_on_hit_slow_chance = 0.1
|
||||
Public.veteran_on_hit_slow_chance = 1
|
||||
Public.medic_heal_radius = 15
|
||||
Public.medic_heal_percentage_amount = 0.1
|
||||
Public.doctor_heal_radius = 20
|
||||
|
@ -1292,6 +1292,7 @@ function Public.validate_player_and_character(player)
|
||||
end
|
||||
|
||||
|
||||
-- Players complained that when "all_items" is false, the items dissapear (perhaps code sending items from dead character to cabin is wrong?).
|
||||
function Public.send_important_items_from_player_to_crew(player, all_items)
|
||||
local player_inv = {}
|
||||
player_inv[1] = game.players[player.index].get_inventory(defines.inventory.character_main)
|
||||
|
@ -434,7 +434,7 @@ function Public.leave_crew(player, to_lobby, quiet)
|
||||
Common.send_important_items_from_player_to_crew(player, true)
|
||||
char.die(memory.force_name)
|
||||
else
|
||||
Common.send_important_items_from_player_to_crew(player)
|
||||
Common.send_important_items_from_player_to_crew(player, true)
|
||||
memory.temporarily_logged_off_characters[player.index] = game.tick
|
||||
end
|
||||
-- else
|
||||
|
@ -147,7 +147,7 @@ function Public.toggle_window(player)
|
||||
vertical_scroll_policy = 'auto'
|
||||
}
|
||||
scroll_pane.style.maximal_height = 500
|
||||
scroll_pane.style.bottom_padding = 20
|
||||
scroll_pane.style.bottom_margin = 10
|
||||
|
||||
scroll_pane.add{
|
||||
type = 'table',
|
||||
|
@ -311,8 +311,6 @@ function Public.flow_add_close_button(flow, close_button_name)
|
||||
type = 'flow',
|
||||
direction = 'vertical',
|
||||
})
|
||||
flow2.style.top_margin = -3
|
||||
flow2.style.bottom_margin = -3
|
||||
|
||||
flow3 = flow2.add{type="flow", name='hflow', direction="horizontal"}
|
||||
flow3.style.vertical_align = 'center'
|
||||
|
@ -47,7 +47,7 @@ function Public.toggle_window(player)
|
||||
vertical_scroll_policy = 'auto'
|
||||
}
|
||||
flow.style.maximal_height = 500
|
||||
flow.style.bottom_padding = 20
|
||||
flow.style.bottom_margin = 10
|
||||
|
||||
--*** PARAMETERS OF RUN ***--
|
||||
|
||||
|
@ -180,7 +180,7 @@ function Public.toggle_window(player)
|
||||
vertical_scroll_policy = 'auto'
|
||||
}
|
||||
flow.style.maximal_height = 500
|
||||
flow.style.bottom_padding = 20
|
||||
flow.style.bottom_margin = 10
|
||||
|
||||
--*** ONGOING RUNS ***--
|
||||
|
||||
@ -474,7 +474,7 @@ function Public.toggle_window(player)
|
||||
flow4.style.font_color = {r=0.10, g=0.10, b=0.10}
|
||||
|
||||
|
||||
GuiCommon.flow_add_close_button(flow, window_name .. '_piratebutton')
|
||||
GuiCommon.flow_add_close_button(window, window_name .. '_piratebutton')
|
||||
end
|
||||
|
||||
|
||||
@ -695,6 +695,11 @@ function Public.click(event)
|
||||
end
|
||||
|
||||
if eventname == 'propose_crew' then
|
||||
if #global_memory.crew_active_ids >= global_memory.active_crews_cap then
|
||||
Common.notify_player_error(player, {'pirates.gui_runs_launch_error_5'})
|
||||
return
|
||||
end
|
||||
|
||||
-- If proposal was set as private
|
||||
local run_is_private = flow.proposals.body.proposal_maker.body.private_checkbox.state
|
||||
if run_is_private then
|
||||
|
@ -11,8 +11,8 @@ Public.step1 = {
|
||||
{
|
||||
type = 'tiles',
|
||||
tile_name = 'orange-refined-concrete',
|
||||
offset = {x = 0, y = 0},
|
||||
bp_string = [[0eNqVmM1qwkAYRd9l1ink+5n8vUpxYXWQAU1CTEtF8u412kUXbfGsQuB4E7gH7phreDu+p3HK/Ry6azj32/FlHl4OU96v95+hEy/C5XaJSxHybujPoXu9gfnQb48rMl/GFLqQ53QKRei3p/Xuxu2mNKew/qjfpzVn2RRhzsf0CBiHc57z0H8/pXw8ZPkt4Q9YCWwEdgJHAlcErgncELglsJSIRh0KKlGebFHudElgIbASGL2zEzgSuCJwTeCGwC0qhVWIOhRUIjNPnqxRiadKPFXiqRJPlXiqxFMlnirxVImnSjxV5KkiTxV5qshTRZ4a8dSIp0Y8NeKpEU+NeGrEUyOeGvHUiKeGPDXkqSFPDXlqyFMn6jlRz4l6TtRzop6Tzh117qhzR5076jySFiOKrkh0haJrEl2j6IZENyi6JdEtOwqhv3QCT/js1A4PceioJWx5Be2joIEUtJCCJlLQRgoaSUErKWgmBe2ksKEUtpTCplL+28pN8fjk0v34gFOEjzSd7wHaiNet1tHFYhmX5QubhLg2]],
|
||||
offset = {x = -1, y = 0},
|
||||
bp_string = [[0eNqV2M1Kw0AUhuF7mXUKPT+Tv1sRF1WHMlCTkExFkdy7iXXhQsV3UUrh60npOQ+cmffwcLmmac5DCf17WIbTdCjj4Tznp/3za+glVuFte2vWKpwelvFyLemw56Y8nENf5muqQn4chyX0d1uFfB5Ol/275W1KoQ+5pOdQheH0vH/aco9zKils1fLwlPYHrPdVKPmSbgWmccklj8PX44+3p68/VfglrCRsJOwkHEm4JuGGhFsS7khYjiiNeiioiYK6KKiN8s8+ymf6SMJCwkrCRsJOwujfqEm4IeGWhDvUFNZC1ENBTRTURUFtZFMt/2ykEgNKDCgxoMSAEgNKDCgxoMSAEgNKDCgyoMiAIgOKDCgyoMiAIgNGDBgxYMSAEQNGDBgxYMSAEQNGDBgxYMiAIQOGDBgyYMiAIQOGDDgx4MSAEwNODDgx4MSAEwNODDgx4MSAIwOODDgy4MiAIwOODDgyEImBSAxEYiASA5EYiMRAJAYiGr6Ihi+i4Yto+CIavoiGL6Lhq8mI1OhnN6R0g0q3pHSLSnekdMcOVOjWSdgdhLDDPzwKolOVsB1b0LoqbHkRtAcIWgQEbQKCVgFBu4CgZUDQNiBoHRC2DwhbCIRtBMJWAvlrJ7ivbhfU/bd78Cq8pHn5LKCteNNpU8ftJc26fgDbkmjB]],
|
||||
},
|
||||
{
|
||||
type = 'tiles',
|
||||
|
Loading…
Reference in New Issue
Block a user