1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2025-01-30 04:30:58 +02:00

Fixes a crash when updating coin label after GUI is closed

This commit is contained in:
Lynn 2019-02-02 13:10:30 +01:00
parent 0464ef1351
commit ab72e629cb

View File

@ -567,6 +567,7 @@ Gui.on_click(item_button_name, function (event)
redraw_market_items(data)
PlayerStats.change_coin_spent(player.index, cost)
do_coin_label(coin_count - cost, data.coin_label)
raise_event(Retailer.events.on_market_purchase, {
item = item,
@ -574,8 +575,6 @@ Gui.on_click(item_button_name, function (event)
player = player,
group_name = market_group,
})
do_coin_label(coin_count - cost, data.coin_label)
end)
---Add a market to the group_name retailer.