improved-stacker
improved-stacker copied to clipboard
Localization errors when language isnt found
Getting these serverside
addons/improved-stacker/lua/improvedstacker/localify.lua:157: Invalid language provided ('es-es')
1. unknown - [C]:-1
2. error - [C]:-1
3. L - addons/improved-stacker/lua/improvedstacker/localify.lua:157
4. LeftClick - addons/improved-stacker/lua/weapons/gmod_tool/stools/stacker_improved.lua:704
5. unknown - gamemodes/sandbox/entities/weapons/gmod_tool/shared.lua:226
Also happens for https://github.com/Mista-Tea/improved-weight, not sure if i should create a duplicate issue for it.
Hey there, @Mista-Tea
It seems like according to Gmod specks the Spanish language is not coded es
but instead es-es
, which differs than the localization key of the library: https://wiki.facepunch.com/gmod/Addon_Localization
Pull request that attempts to fix this: https://github.com/Mista-Tea/improved-stacker/pull/45
Maybe it is better to use a properties file. I've wrote a detailed tutorial in the wiki link provided. ( Currently used in TA for gmod_language )
Here is an example for English: stacker_improved.txt
Sorry for the delay! I will try to look at this soon. I think I had fixed it in Improved Weight's version of Localify, or maybe the Localify repo itself, but haven't updated the hardcoded copies in stacker.
Shouldn't be better to register the library as a sub module then assuming will be easier? With that way the copy will always get updated. They just stay as a pointer to another repo. I will be using it for my wire wrapper module ;)
https://github.blog/2016-02-01-working-with-submodules/
Looks like that ( folder named rock
@ #HASH ):