Page 1 of 1

[Klonan] [1.0] tiny memory "leak" in Wave Defense scenario

Posted: Thu Oct 22, 2020 5:10 am
by Honktown
The global.wave_defense.gui_actions[player_index] table does not have elements removed when an upgrade is purchased. This leads to 8 extra values every time an upgrade is purchased.

It may be from these two lines being improperly ordered, line ~1196 of wave_defense.lua:

Code: Select all

  gui.clear()
  deregister_gui(gui)
gui.clear removes the children, so only the upgrade_table is deregistered. If the lines are swapped, it ought to deregister everything, and then 'clear' the children.

Re: [Klonan] [1.0] tiny memory "leak" in Wave Defense scenario

Posted: Thu Oct 22, 2020 9:02 am
by Klonan
Nice catch, fixed for the next release