YARM - Resource Monitor

by Narc

This mod helps you to keep track of your mining sites, with useful data such as the percent mined, and estimated time to depletion.

Utilities
7 months ago
0.14 - 1.1
124K
Mining

b [Fixed][v0.9.5] Crash on world load

11 months ago

I'm receiving the following crash on loading my world when YARM loads the currently monitored sites:

'The mod YARM - Resource Monitor (0.9.5) caused a non-recoverable error.
Please report this to the mod author.

Error while running event YARM::on_gui_click (ID 1)
Gui element with name YARM_label_percent_Total[item=coal] already present in the parent element.
stack traceback:
[C]: in function 'add'
YARM/resmon.lua:1036: in function 'print_single_site'
YARM/resmon.lua:924: in function 'update_ui'
YARM/resmon.lua:1448: in function 'update_force_members_ui'
YARM/resmon.lua:1280: in function 'remove_site'
YARM/resmon.lua:1458: in function
<YARM/resmon.lua:1452>'

[item=coal] is the actual Coal icon from Rich Text
After not clicking the remove button, I get a similar error (event YARM::on_tick, resmon.lua 1036, 924, 1508, 1548, 1582, 1577)

I tried removing and re-adding the mod with no luck

My world has Angels Infinite Ores (inside normal ore patches) and Angels Ores types (bobmonium, rubyite etc)

11 months ago

Saving the game without the mod and re-adding it allows it to load, but when I add the coal patch back, it crashes again.

It also removes one ore, to add another. On the world, it removes Rubyte to add Crotinium and reverse, and assigns them both the same name (E 130)

Link to save for testing: https://www.dropbox.com/s/x48cib9dyrboe3e/2023%20-%20BobRedMew%20-%20YARMCrash.zip?dl=0

Mithaldu β˜†
11 months ago

Thanks for providing a save. I'll look at it.

Mithaldu β˜†
11 months ago

As for the "same name" thing, that's normal right now. Sadly it uses names as IDs of sites, and if you create a new site whose name matches an existing one, it overwrites the old one. I plan to fix this, but it's a future thing.

Mithaldu β˜†
11 months ago

v0.9.6 should fix this. :)

11 months ago

Works perfectly. Excellent turnaround time.

A suggestion for the Naming issue, perhaps the name should default to "{Location} {RichText of Ore}"
That should eliminate the issue mostly.
Or perform a check, and if the name already exists, add a "-x" after the location code.

Mithaldu β˜†
10 months ago

That's not a bad workaround for now, but i think i'd rather just implement an internal id system. :)

New response