mirror of
https://github.com/Refactorio/RedMew.git
synced 2025-02-07 13:31:54 +02:00
Fixes a crash when updating coin label after GUI is closed
This commit is contained in:
parent
0464ef1351
commit
ab72e629cb
@ -567,6 +567,7 @@ Gui.on_click(item_button_name, function (event)
|
|||||||
|
|
||||||
redraw_market_items(data)
|
redraw_market_items(data)
|
||||||
PlayerStats.change_coin_spent(player.index, cost)
|
PlayerStats.change_coin_spent(player.index, cost)
|
||||||
|
do_coin_label(coin_count - cost, data.coin_label)
|
||||||
|
|
||||||
raise_event(Retailer.events.on_market_purchase, {
|
raise_event(Retailer.events.on_market_purchase, {
|
||||||
item = item,
|
item = item,
|
||||||
@ -574,8 +575,6 @@ Gui.on_click(item_button_name, function (event)
|
|||||||
player = player,
|
player = player,
|
||||||
group_name = market_group,
|
group_name = market_group,
|
||||||
})
|
})
|
||||||
|
|
||||||
do_coin_label(coin_count - cost, data.coin_label)
|
|
||||||
end)
|
end)
|
||||||
|
|
||||||
---Add a market to the group_name retailer.
|
---Add a market to the group_name retailer.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user