i’m trying to make a function that change language woth getLocale i created a function PHP: public function sendEachLang($player, $en, $jp){ if($player->getLocale() == “ja-JP”){ return $jp; }else{ return $en; }} and, i tried to send (japanese mode) but it doesn’t work(sent in english) how can i fix this?
https://github.com/pmmp/PocketMine-...88ab6ee01fa2a0/src/pocketmine/Player.php#L776 Read this, You specified "ja-JP", but correctly it is "ja_JP".
dude, you really should consider a better way to manage local like you should use lang.yml and get things with langcode since this will get messy when you want to add support, for say another language