Qui Intus Diaboli

Active Member
Reaction score
22
Author
Qui Intus Diaboli
Contributors
N/A
Quickbar Entry
javascript:
$.getScript('https://toxicdonut.dev:8080/js/Toxic_Donut_s_Group_Placer.js');
Public?
Public
Moving villages in and out of manual groups is something you do a lot in TW, the only thing I missed was a way to do that quickly without having to load the groups page, delete everything, switch groups again and add everything to add. With this small script you can do all these actions in the same screen.

With this script you can add and remove coordinates from a selected group. You can also delete all the villages in a certain group with it.

Here's an example of all the actions you can do https://streamable.com/o6grac.
 
Upvote 0

Escudo de Espinho

New Member
Reaction score
2
Hi! I hope you're doing well.

Thank you so much for creating this script.

The script won't work for locales different from nl_NL and en_DK.

It will throw an exception when accessing this lang[locale].length.

A suggestion for fixing this is, instead of doing the following:

Code:
const langToUse = lang[locale].length > 0 ? lang[locale] : lang['en_DK'];

Update to:

Code:
const langToUse = lang[locale] && lang[locale].length > 0 ? lang[locale] : lang['en_DK'];

Thank you again!

Hi Qui Intus Diaboli !

Thank you again for your script.

Have you rolled back the version?

The error of not finding the translation is happening again.


const langToUse = lang[locale].length > 0 ? lang[locale] : lang['en_DK'];

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'length')


Thank you!
 
Top