mirror of
https://github.com/Refactorio/RedMew.git
synced 2025-02-21 19:20:07 +02:00
mark inf chests as inactive
This commit is contained in:
parent
1a459287b5
commit
32c35baa6b
@ -22,7 +22,7 @@ local chest_gui_frame_name = Gui.uid_name()
|
|||||||
local chest_content_table_name = Gui.uid_name()
|
local chest_content_table_name = Gui.uid_name()
|
||||||
|
|
||||||
function Module.create_chest(surface, position, storage)
|
function Module.create_chest(surface, position, storage)
|
||||||
local entity = surface.create_entity{name = 'infinity-chest', position = position, force = 'player'}
|
local entity = surface.create_entity {name = 'infinity-chest', position = position, force = 'player'}
|
||||||
chests[entity.unit_number] = {entity = entity, storage = storage}
|
chests[entity.unit_number] = {entity = entity, storage = storage}
|
||||||
return entity
|
return entity
|
||||||
end
|
end
|
||||||
@ -33,6 +33,8 @@ local function built_entity(event)
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
entity.active = false
|
||||||
|
|
||||||
chests[entity.unit_number] = {entity = entity, storage = {}}
|
chests[entity.unit_number] = {entity = entity, storage = {}}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -258,6 +260,12 @@ Gui.on_custom_close(
|
|||||||
)
|
)
|
||||||
|
|
||||||
local market_items = require 'resources.market_items'
|
local market_items = require 'resources.market_items'
|
||||||
table.insert(market_items, {price = 100, name = 'infinity-chest', description = 'Stores unlimited quantity of items for up to 48 different item types'})
|
table.insert(
|
||||||
|
market_items,
|
||||||
|
{
|
||||||
|
price = 100,
|
||||||
|
name = 'infinity-chest',
|
||||||
|
description = 'Stores unlimited quantity of items for up to 48 different item types'
|
||||||
|
}
|
||||||
|
)
|
||||||
return Module
|
return Module
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user