fedorovvl / tso_client

The Settlers Online client
43 stars 24 forks source link

userscript rebuild_mines missing initialization? #397

Closed borsti67 closed 2 months ago

borsti67 commented 2 months ago

Just in case the issue is related to translation - I'm playing the German version.

When the script runs for the 1st time after the client was started, it seems all the checked mines are built as expected. But on each consecutive run I can see such messages popping up: grafik ...and not all of the checked mines are built (mostly it's just one)

fedorovvl commented 2 months ago

i think here we need to use BUI group instead of RES https://github.com/fedorovvl/tso_client/blob/44ebe549247f0a67d6e10789cf622933137bf72e/userscripts/user_mine_rebuild.js#L430 can u manually change line and check?

borsti67 commented 2 months ago

But why does it work on the 1st run then? Anyway, I changed it, now I have to wait for some mines to appear ;)

borsti67 commented 2 months ago

a single gold mine was found. Using the script, it was built, but the same message above appeared twice instead of the one expected (to be clear, only these 2 messages were shown, none about building gold). I have seen correct messages before, so I assume these notifications come because "item" is wrong at that time. That's why I assumed it is about wrong or missing initialization.

fedorovvl commented 2 months ago

maybe @PiTi2k5 as script maker know the answer =)

borsti67 commented 2 months ago

Now a Salpeter and a Titanium deposit was found. I selected both and hit send: grafik Only Salpeter was built, Titanium was ignored. The german text reads "used up mine", which would match my assumption that the script does not use the lines which are checked. The number of notifications does not match either, there should be exactly two according to my checkmarks, even if the wrong ones are processed...

PiTi2k5 commented 2 months ago

https://github.com/fedorovvl/tso_client/pull/398

Should be fixed. Sollte gefixt sein.

borsti67 commented 2 months ago

Looks good so far - no "undefined text" and the number of messages matches. Unfortunately I have only found single deposits yet, but I'm quite confident it works now. Thanks @PiTi2k5 !