Triton - Translate Your Server | Skript integration icon

Triton - Translate Your Server | Skript integration -----

Have you always wanted to use Triton syntax in skript? This skript allows you to do so.



Download Triton:
Triton Website

Examples:
1: Translation
Code (YAML):
command /translate [<text>] [<text>]:
    trigger
:
       set {_t } to arg-1's translation in player's lang if arg-2 is not set
        set {_t } to arg-1's translation in player's lang with (split arg-2 at " " ) if arg-2 is set
        message "%{_t}%"
 
is for arguments. You can give infinite arguments but the triton translation needs to contain those argument positions ( %1 %2 %3 etc.)

Command:
test is my message key. argument1 and argument2 are my arguments

Result:
upload_2022-5-2_18-44-20.png

2: Get Player Language

Code (YAML):
command /langfrom [<offline player>]:
    trigger
:
       message player's lang
 
This expression will return the player's selected language as country code.

Command:
German is my currently selected language so the result is de_DE

Result:
upload_2022-5-2_19-2-28.png


3: Set Player Language

Code (YAML):
command /langfrom [<offline player>]:
    trigger
:
       set player's lang to "en_GB"
        message player's lang
 
This effect will change the player's current language without needing to rejoin or to reload something.

Command:
German is my currently selected language but I changed it to en_GB so the result is en_GB now

Result:
New language:
upload_2022-5-2_19-8-23.png
Resource Information
Author:
----------
Total Downloads: 167
First Release: May 2, 2022
Last Update: May 2, 2022
Category: ---------------
All-Time Rating:
0 ratings
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings