the initial commit to the repo.
This commit is contained in:
parent
025c032b8c
commit
1b757591b9
264 changed files with 21882 additions and 0 deletions
23
EscapeFromTarkovCheat/LocalisationManager.cs
Normal file
23
EscapeFromTarkovCheat/LocalisationManager.cs
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
using EscapeFromTarkovCheat.Data;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace EscapeFromTarkovCheat
|
||||
{
|
||||
public static class LocalisationManager
|
||||
{
|
||||
static List<LocalisationData> data = new List<LocalisationData>();
|
||||
|
||||
public static void Initialize() {
|
||||
data.Add(new LocalisationData(Locale.ENGLISH));
|
||||
data.Add(new LocalisationData(Locale.CHINESE));
|
||||
}
|
||||
|
||||
public static string GetString(Locale locale, StringKey key) {
|
||||
foreach (LocalisationData data in data) {
|
||||
if (data.locale == locale)
|
||||
return data.GetByKey(key);
|
||||
}
|
||||
return $"INVALID_LANGUAGE_{locale}";
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue