GlowstoneMC / Glowstone

A fast, customizable and compatible open source server for Minecraft: Java Edition
https://glowstone.net
Other
1.88k stars 271 forks source link

Implement Player locale Setting #1011

Closed heisluft closed 5 years ago

heisluft commented 5 years ago

Motivation: My plugin, AntiLaby, sends localized messages to players. In order to do this, we need a working PlayerLocaleChangeEvent and player.getLocale() implementation.

Implementation specifics: The PlayerLocaleChangeEvent is (like in CB) only fired when the player locale actually changes. I lowercased "en_US" to "en_us", because for quite a while (1.9 afaik) language ids are all lowercased (at least the vanilla ones)