diff --git a/JotunnModStub/Aswid/AswidBloodRefinery.cs b/JotunnModStub/Aswid/AswidBloodRefinery.cs index 0e8d711..78a9867 100644 --- a/JotunnModStub/Aswid/AswidBloodRefinery.cs +++ b/JotunnModStub/Aswid/AswidBloodRefinery.cs @@ -567,7 +567,7 @@ namespace RacesOfValheim if (!AswidBloodRefinery.IsEssence(item)) return true; if (AswidRace.IsAswid()) return true; - player.Message(MessageHud.MessageType.Center, "Living blood curdles in a living throat."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_living_blood_curdles_living_throat")); return false; } } diff --git a/JotunnModStub/Aswid/AswidPatches.cs b/JotunnModStub/Aswid/AswidPatches.cs index 0bc1753..9361df9 100644 --- a/JotunnModStub/Aswid/AswidPatches.cs +++ b/JotunnModStub/Aswid/AswidPatches.cs @@ -529,7 +529,7 @@ namespace RacesOfValheim { AswidRace.DevourEnabled = !AswidRace.DevourEnabled; AswidRace.AuraEnabled = AswidRace.DevourEnabled; - string msg = AswidRace.DevourEnabled ? "Vampiric Aura: ENABLED" : "Vampiric Aura: DISABLED"; + string msg = ModText.Get(AswidRace.DevourEnabled ? "rov_msg_aswid_aura_enabled" : "rov_msg_aswid_aura_disabled"); __instance.Message(MessageHud.MessageType.Center, msg); } diff --git a/JotunnModStub/Aswid/AswidRace.cs b/JotunnModStub/Aswid/AswidRace.cs index 2ca35de..edfbdc5 100644 --- a/JotunnModStub/Aswid/AswidRace.cs +++ b/JotunnModStub/Aswid/AswidRace.cs @@ -338,11 +338,11 @@ namespace RacesOfValheim { if (isNight) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "what a horrible night to have a curse"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_what_horrible_night_have_curse")); } else { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The morning sun has vanquished the horrible night"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_morning_sun_has_vanquished_horrible")); } } wasNight = isNight; @@ -431,7 +431,7 @@ namespace RacesOfValheim if (IsTransformed && !isTransformingSequence && activeRules != null && activeRules.NeedsNight && EnvMan.instance != null && EnvMan.IsDay()) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The morning sun drives the bat back into your body"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_morning_sun_drives_bat_back")); StartCoroutine(RevertToHumanRoutine()); } } @@ -534,7 +534,7 @@ namespace RacesOfValheim // sunrise must always be able to turn back. if (rules.NeedsNight && (EnvMan.instance == null || !EnvMan.IsNight())) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The sun burns. You can only take bat form at night."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_sun_burns_can_only_take")); return; } @@ -844,7 +844,7 @@ namespace RacesOfValheim c.SetTamed(true); HarmonyLib.Traverse.Create(tameable).Method("Tame").GetValue(); // attempt to call Tame for VFX if it exists tameable.Command(Player.m_localPlayer); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Tamed!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_tamed")); } } } @@ -863,7 +863,7 @@ namespace RacesOfValheim if (Time.time - lastEclipseTime < cooldown) { int remaining = (int)(cooldown - (Time.time - lastEclipseTime)); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"Eclipse is on cooldown. Remaining: {remaining}s"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_eclipse_cooldown_remaining_s", remaining)); return; } @@ -915,7 +915,7 @@ namespace RacesOfValheim } // Lock player for the duration of the cast (approx 2 seconds) - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "An Eclipse descends..."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_eclipse_descends")); float castTimer = 0f; while(castTimer < AswidConfig.EclipseCastTime.Value) @@ -967,7 +967,7 @@ namespace RacesOfValheim if (Player.m_localPlayer != null) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The Eclipse has ended."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_eclipse_has_ended")); } } @@ -1160,7 +1160,7 @@ namespace RacesOfValheim if (successfullyEaten) { // Show the Vae Victis message in the center of the screen - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Vae Victis"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_vae_victis")); Player.m_localPlayer.Message(MessageHud.MessageType.TopLeft, "$msg_ate " + addedItem.m_shared.m_name); // Vae Victis XP logic - similar to Dead Raiser diff --git a/JotunnModStub/Aswid/AswidThrall.cs b/JotunnModStub/Aswid/AswidThrall.cs index 35d1562..638ce4e 100644 --- a/JotunnModStub/Aswid/AswidThrall.cs +++ b/JotunnModStub/Aswid/AswidThrall.cs @@ -81,12 +81,12 @@ namespace RacesOfValheim if (m_ai.GetFollowTarget() == user.gameObject) { m_ai.SetFollowTarget(null); - user.Message(MessageHud.MessageType.Center, $"{m_character.m_name} is staying."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_staying", m_character.m_name)); } else { m_ai.SetFollowTarget(user.gameObject); - user.Message(MessageHud.MessageType.Center, $"{m_character.m_name} is following."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_following", m_character.m_name)); } } return true; @@ -98,7 +98,7 @@ namespace RacesOfValheim float cooldown = AswidRace.GetEnslaveCooldown(); if (cooldown > 0) { - user.Message(MessageHud.MessageType.Center, $"Dominate on cooldown ({Mathf.CeilToInt(cooldown / 60f)}m {Mathf.CeilToInt(cooldown % 60f)}s)"); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_dominate_cooldown_m_s", Mathf.CeilToInt(cooldown / 60f), Mathf.CeilToInt(cooldown % 60f))); return false; } @@ -123,7 +123,7 @@ namespace RacesOfValheim GameObject vfx = ZNetScene.instance.GetPrefab("vfx_corpse_destruction_medium"); if (vfx) Instantiate(vfx, m_character.transform.position, Quaternion.identity); - user.Message(MessageHud.MessageType.Center, $"{m_character.m_name} dominated!"); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_aswid_dominated", m_character.m_name)); return true; } diff --git a/JotunnModStub/Aswid/BloodRefineryBehaviour.cs b/JotunnModStub/Aswid/BloodRefineryBehaviour.cs index d06b47b..ada6820 100644 --- a/JotunnModStub/Aswid/BloodRefineryBehaviour.cs +++ b/JotunnModStub/Aswid/BloodRefineryBehaviour.cs @@ -98,7 +98,7 @@ namespace RacesOfValheim if (item == null) item = FindUsable(inventory, isMeat); if (item == null) { - user.Message(MessageHud.MessageType.Center, isMeat ? "No raw flesh to render." : "No bone to grind."); + user.Message(MessageHud.MessageType.Center, (isMeat ? ModText.Get("rov_msg_aswid_no_raw_flesh_render") : ModText.Get("rov_msg_aswid_no_bone_grind"))); return false; } diff --git a/JotunnModStub/BossProgressionManager.cs b/JotunnModStub/BossProgressionManager.cs index 27e492e..cc7f2ad 100644 --- a/JotunnModStub/BossProgressionManager.cs +++ b/JotunnModStub/BossProgressionManager.cs @@ -39,6 +39,26 @@ namespace RacesOfValheim { "FaderDrop", 8 } // Fader - Fader relic }; + /// + /// The boss's name as the game's own localization token, for text shown to players: + /// Valheim translates it wherever it is localized, so "The Elder" arrives in every language. + /// GetBossNameForState stays English, for logs and anything not localized. + /// + public static string GetBossTokenForState(int state) + { + switch (state) + { + case 2: return "$enemy_eikthyr"; + case 3: return "$enemy_gdking"; + case 4: return "$enemy_bonemass"; + case 5: return "$enemy_dragon"; + case 6: return "$enemy_goblinking"; + case 7: return "$enemy_seekerqueen"; + case 8: return "$enemy_fader"; + default: return GetBossNameForState(state); + } + } + public static string GetBossNameForState(int state) { switch (state) diff --git a/JotunnModStub/Butler/BoneServant.cs b/JotunnModStub/Butler/BoneServant.cs index 8c7a0a3..6126d1d 100644 --- a/JotunnModStub/Butler/BoneServant.cs +++ b/JotunnModStub/Butler/BoneServant.cs @@ -94,7 +94,7 @@ namespace RacesOfValheim "Coal"); PieceDensityLimit.Register(SmithTableName, TableSpacing, 1, - "Another smith's table stands within forty paces. One smith to a yard."); + "rov_msg_build_limit_smithtable"); // Two races, and it is the wider of the two locks: the Skeleton raises the dead to work // for it, and Skadi's hold is a forge under ice. @@ -105,7 +105,7 @@ namespace RacesOfValheim if (player != null) { player.Message(MessageHud.MessageType.Center, - "The bones do not answer to your blood."); + ModText.Get("rov_msg_butler_bones_do_not_answer_blood")); } return false; }); @@ -118,7 +118,7 @@ namespace RacesOfValheim "CookedMeat"); PieceDensityLimit.Register(CookTableName, TableSpacing, 1, - "Another cook's table stands within forty paces. One cook to a yard."); + "rov_msg_build_limit_cooktable"); // Skadi alone. A hearth kept by something dead is hers, not the Skeleton's. PieceDensityLimit.RegisterGate(CookTableName, (player, position) => @@ -128,7 +128,7 @@ namespace RacesOfValheim if (player != null) { player.Message(MessageHud.MessageType.Center, - "Only Skadi's hearth is kept by the dead."); + ModText.Get("rov_msg_butler_only_skadi_s_hearth_kept")); } return false; }); diff --git a/JotunnModStub/Butler/ServantTableBehaviour.cs b/JotunnModStub/Butler/ServantTableBehaviour.cs index 6aab038..bac4a73 100644 --- a/JotunnModStub/Butler/ServantTableBehaviour.cs +++ b/JotunnModStub/Butler/ServantTableBehaviour.cs @@ -70,7 +70,7 @@ namespace RacesOfValheim if (Servant() != null) { - player.Message(MessageHud.MessageType.Center, "It is already at work."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_butler_already_at_work")); return false; } @@ -78,7 +78,7 @@ namespace RacesOfValheim if (wait > 0f) { player.Message(MessageHud.MessageType.Center, - $"The bones are not ready. {Mathf.CeilToInt(wait)}s."); + ModText.Get("rov_msg_butler_bones_are_not_ready_s", Mathf.CeilToInt(wait))); return false; } @@ -94,7 +94,7 @@ namespace RacesOfValheim if (prefab == null) { Jotunn.Logger.LogWarning($"[Butler] No '{m_servantPrefab}' in ZNetScene; nothing was raised."); - player.Message(MessageHud.MessageType.Center, "Nothing answers."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_butler_nothing_answers")); return false; } @@ -109,7 +109,7 @@ namespace RacesOfValheim if (ZNet.instance != null) m_nview.GetZDO().Set(KeyLastRaise, ZNet.instance.GetTime().Ticks); - player.Message(MessageHud.MessageType.Center, "The servant rises."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_butler_servant_rises")); return true; } diff --git a/JotunnModStub/Draugh/DraughFoodPatches.cs b/JotunnModStub/Draugh/DraughFoodPatches.cs index 847a615..f6d7fe7 100644 --- a/JotunnModStub/Draugh/DraughFoodPatches.cs +++ b/JotunnModStub/Draugh/DraughFoodPatches.cs @@ -42,7 +42,7 @@ namespace RacesOfValheim { if (!DraughRace.IsDraugh()) { - player.Message(MessageHud.MessageType.Center, "This rotting flesh is fatal to the living."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_this_rotting_flesh_fatal_living")); return false; // Block consumption } // If it IS a Draugh, let them consume it via native mechanics @@ -101,7 +101,7 @@ namespace RacesOfValheim bool isFood = item.m_shared.m_food > 0 || item.m_shared.m_foodStamina > 0 || item.m_shared.m_foodEitr > 0; if (isFood) { - player.Message(MessageHud.MessageType.Center, "Draugr consume only raw flesh, eyes, entrails or blood."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_draugr_consume_only_raw_flesh")); return false; // Block it } } diff --git a/JotunnModStub/Draugh/DraughProgressionPatches.cs b/JotunnModStub/Draugh/DraughProgressionPatches.cs index eaa8357..26743f5 100644 --- a/JotunnModStub/Draugh/DraughProgressionPatches.cs +++ b/JotunnModStub/Draugh/DraughProgressionPatches.cs @@ -153,7 +153,7 @@ namespace RacesOfValheim } } - Player.m_localPlayer.Message(MessageHud.MessageType.TopLeft, "The northern wind blows"); + Player.m_localPlayer.Message(MessageHud.MessageType.TopLeft, ModText.Get("rov_msg_draugh_northern_wind_blows")); } } } @@ -312,7 +312,7 @@ namespace RacesOfValheim if (prefab != null) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Swarm of Terror!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_swarm_terror")); for (int i = 0; i < DraughConfig.SwarmSpawnCount.Value; i++) { @@ -356,7 +356,7 @@ namespace RacesOfValheim float healAmount = Player.m_localPlayer.GetMaxHealth() * DraughConfig.StealBreathHealPercent.Value; Player.m_localPlayer.Heal(healAmount); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Steal Their Breath! Death is denied."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_steal_their_breath_death_denied")); // Restore visuals immediately if (Player.m_localPlayer.GetComponent() != null) diff --git a/JotunnModStub/Draugh/DraughRace.cs b/JotunnModStub/Draugh/DraughRace.cs index 9362f5c..f654eac 100644 --- a/JotunnModStub/Draugh/DraughRace.cs +++ b/JotunnModStub/Draugh/DraughRace.cs @@ -133,7 +133,7 @@ namespace RacesOfValheim public System.Collections.IEnumerator UndyingWillRoutine(Player p) { - p.Message(MessageHud.MessageType.Center, "Zombie Ritual Activated! Your borrowed time is fading..."); + p.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_zombie_ritual_activated_borrowed_time")); // Trigger a re-evaluation of visuals to apply the ghost effect if (p.GetComponent() != null) diff --git a/JotunnModStub/Draugh/DraughSpawner.cs b/JotunnModStub/Draugh/DraughSpawner.cs index 9e00fd5..a2604b2 100644 --- a/JotunnModStub/Draugh/DraughSpawner.cs +++ b/JotunnModStub/Draugh/DraughSpawner.cs @@ -129,7 +129,7 @@ namespace RacesOfValheim PieceDensityLimit.Register(PieceName, PieceDensityLimit.RadiusForArea(DensityAreaKm2), MaxPilesInRange, - "The ground here already carries {0} of these. Find another country."); + "rov_msg_build_limit_draugh_bodypile"); } // ---------------------------------------------------------------- items @@ -201,7 +201,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = maxFollowers; thrall.m_witherSeconds = OrphanWitherSeconds; thrall.m_homeCheckRange = HomeCheckRange; - thrall.m_refusalMessage = "The dead do not take orders from the living."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_draugh"; PrefabManager.Instance.AddPrefab(prefab); } diff --git a/JotunnModStub/Draugh/DraughSpawnerBehaviour.cs b/JotunnModStub/Draugh/DraughSpawnerBehaviour.cs index faf40ee..39b1dd7 100644 --- a/JotunnModStub/Draugh/DraughSpawnerBehaviour.cs +++ b/JotunnModStub/Draugh/DraughSpawnerBehaviour.cs @@ -82,7 +82,7 @@ namespace RacesOfValheim if (item == null) item = FindAnyInput(inventory); if (item == null) { - user.Message(MessageHud.MessageType.Center, "It wants flesh, or the head of one of its own."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_wants_flesh_or_head_one")); return false; } @@ -93,7 +93,7 @@ namespace RacesOfValheim if (prefabName == DraughSpawner.TrophyDraugrElite && !IsUpgraded()) { - user.Message(MessageHud.MessageType.Center, "This pile keeps no officers yet."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_this_pile_keeps_no_officers")); return false; } @@ -162,19 +162,19 @@ namespace RacesOfValheim { if (IsUpgraded()) { - user.Message(MessageHud.MessageType.Center, "It has already had one."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_has_already_had_one")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < DraughSpawner.UpgradeProgressionState) { - user.Message(MessageHud.MessageType.Center, "The bone will not wake. Something older has to fall first."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_bone_will_not_wake_something")); return false; } inventory.RemoveItem(item, 1); m_nview.InvokeRPC("RoV_DraughUpgrade"); - user.Message(MessageHud.MessageType.Center, "The pile stirs. It will keep officers now."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_draugh_pile_stirs_will_keep_officers")); return true; } @@ -294,7 +294,7 @@ namespace RacesOfValheim if (bound.Count > 0 && Player.m_localPlayer != null) { Player.m_localPlayer.Message(MessageHud.MessageType.Center, - $"The pile is broken. {bound.Count} will not outlast it by more than a minute."); + ModText.Get("rov_msg_draugh_pile_broken_will_not_outlast", bound.Count)); } SetFlesh(0f); diff --git a/JotunnModStub/Dvergar/DvergarAbilities.cs b/JotunnModStub/Dvergar/DvergarAbilities.cs index 11cc807..63daff3 100644 --- a/JotunnModStub/Dvergar/DvergarAbilities.cs +++ b/JotunnModStub/Dvergar/DvergarAbilities.cs @@ -45,7 +45,7 @@ namespace RacesOfValheim if (player.GetEitr() < DvergarConfig.RunicPingEitrCost) { - player.Message(MessageHud.MessageType.Center, "Not enough eitr"); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_not_enough_eitr")); return; } @@ -55,7 +55,7 @@ namespace RacesOfValheim int marked = MarkSurroundings(player); player.Message(MessageHud.MessageType.Center, - marked > 0 ? $"Runic Ping: {marked} echoes answer" : "Runic Ping: the stone is silent"); + (marked > 0 ? ModText.Get("rov_msg_dvergar_runic_ping_echoes_answer", marked) : ModText.Get("rov_msg_dvergar_runic_ping_stone_silent"))); } /// @@ -173,7 +173,7 @@ namespace RacesOfValheim if (player.GetEitr() < DvergarConfig.RunicOverchargeEitrCost) { - player.Message(MessageHud.MessageType.Center, "Not enough eitr"); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_not_enough_eitr")); return; } @@ -186,7 +186,7 @@ namespace RacesOfValheim // The charge is held, not permanent: it lapses if no favoured blow lands in time. if (se != null) se.m_ttl = DvergarConfig.RunicOverchargeWindow; - player.Message(MessageHud.MessageType.Center, "Runic Overcharge: your next blow is loaded"); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_runic_overcharge_next_blow_loaded")); } /// diff --git a/JotunnModStub/Dvergar/DvergarBanco.cs b/JotunnModStub/Dvergar/DvergarBanco.cs index b18e968..98559ee 100644 --- a/JotunnModStub/Dvergar/DvergarBanco.cs +++ b/JotunnModStub/Dvergar/DvergarBanco.cs @@ -195,7 +195,7 @@ namespace RacesOfValheim PieceDensityLimit.Register(PieceName, PieceDensityLimit.RadiusForArea(DensityAreaKm2), MaxBanksInRange, - "There is already {0} contract bank within a day's walk. One ledger per valley."); + "rov_msg_build_limit_dvergar_contractbank"); } // ---------------------------------------------------------------- the hired @@ -233,7 +233,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = MaxFollowers; thrall.m_witherSeconds = WitherSeconds; thrall.m_homeCheckRange = HomeCheckRange; - thrall.m_refusalMessage = "Your name is not on the contract."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_dvergar"; // Ten seconds unhurt, then two percent a second - the sentry's regeneration, shared with // the Trol's troops and the Fenrir's pack. A dead mercenary still stays dead. @@ -412,7 +412,7 @@ namespace RacesOfValheim if (Utils.GetPrefabName(__0.gameObject) != DvergarBanco.PieceName) return true; if (DvergarRace.IsDvergar()) return true; - __instance.Message(MessageHud.MessageType.Center, "The contract is in runic. You do not sign it."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_contract_runic_do_not_sign")); return false; } } diff --git a/JotunnModStub/Dvergar/DvergarBancoBehaviour.cs b/JotunnModStub/Dvergar/DvergarBancoBehaviour.cs index a0646a7..cb381e0 100644 --- a/JotunnModStub/Dvergar/DvergarBancoBehaviour.cs +++ b/JotunnModStub/Dvergar/DvergarBancoBehaviour.cs @@ -66,7 +66,7 @@ namespace RacesOfValheim if (!DvergarRace.IsDvergar()) { - player.Message(MessageHud.MessageType.Center, "The ledger is not written for you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_ledger_not_written")); // With an item in hand, false makes Humanoid.UseItem cover this message with its // generic "$msg_cantuseon"; true tells it the use was handled here. return item != null; @@ -93,19 +93,19 @@ namespace RacesOfValheim { if (IsUpgraded()) { - player.Message(MessageHud.MessageType.Center, "It has already had one."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_has_already_had_one")); return true; } if (BossProgressionManager.GetCurrentProgressionState() < DvergarBanco.UpgradeProgressionState) { - player.Message(MessageHud.MessageType.Center, "Not while she still sits under the mist."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_not_while_she_still_sits")); return true; } player.GetInventory().RemoveItem(item, 1); m_nview.InvokeRPC("RoV_DvergarUpgrade"); - player.Message(MessageHud.MessageType.Center, "The ledger is rewritten. Better names sign it now."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_ledger_rewritten_better_names_sign")); return true; } @@ -119,7 +119,7 @@ namespace RacesOfValheim Trader trader = GetComponent(); if (trader == null || StoreGui.instance == null) { - player.Message(MessageHud.MessageType.Center, "The ledger is shut."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_ledger_shut")); return false; } @@ -144,7 +144,7 @@ namespace RacesOfValheim if (CountGroups() >= DvergarBanco.MaxTroops) { - player.Message(MessageHud.MessageType.Center, "Five contracts is all the ledger holds."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_five_contracts_all_ledger_holds")); return; } @@ -163,7 +163,7 @@ namespace RacesOfValheim TakeCoins(inventory, price); m_nview.InvokeRPC("RoV_DvergarHire", troop.Id); - player.Message(MessageHud.MessageType.Center, $"{troop.Display} signs on."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_signs", troop.Display)); } private const string CoinsPrefab = "Coins"; diff --git a/JotunnModStub/Dvergar/DvergarBotte.cs b/JotunnModStub/Dvergar/DvergarBotte.cs index 05ee712..e0a7953 100644 --- a/JotunnModStub/Dvergar/DvergarBotte.cs +++ b/JotunnModStub/Dvergar/DvergarBotte.cs @@ -203,7 +203,7 @@ namespace RacesOfValheim if (Utils.GetPrefabName(__0.gameObject) != DvergarBotte.PieceName) return true; if (DvergarRace.IsDvergar()) return true; - __instance.Message(MessageHud.MessageType.Center, "You do not know what goes in it."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_do_not_know_what_goes")); return false; } } diff --git a/JotunnModStub/Dvergar/DvergarBotteBehaviour.cs b/JotunnModStub/Dvergar/DvergarBotteBehaviour.cs index 84b810c..32d4a82 100644 --- a/JotunnModStub/Dvergar/DvergarBotteBehaviour.cs +++ b/JotunnModStub/Dvergar/DvergarBotteBehaviour.cs @@ -77,7 +77,7 @@ namespace RacesOfValheim ItemDrop.ItemData found = FindAnyBrew(inventory); if (found == null) { - player.Message(MessageHud.MessageType.Center, "It is empty, and so are you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_empty_so_are")); return false; } @@ -106,7 +106,7 @@ namespace RacesOfValheim if (!string.IsNullOrEmpty(current) && current != prefabName && GetDoses() > 0) { player.Message(MessageHud.MessageType.Center, - $"There is still {DvergarBotte.BrewDisplayName(current)} in it."); + ModText.Get("rov_msg_dvergar_there_still", DvergarBotte.BrewDisplayName(current))); return false; } @@ -151,14 +151,14 @@ namespace RacesOfValheim StatusEffect effect = DvergarBotte.BrewEffect(brew); if (effect == null) { - player.Message(MessageHud.MessageType.Center, "Whatever is in it does nothing to anyone."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_whatever_does_nothing_anyone")); return false; } List drinkers = InRange(); if (drinkers.Count == 0) { - player.Message(MessageHud.MessageType.Center, "Nobody is at the barrel."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_nobody_at_barrel")); return false; } @@ -173,16 +173,14 @@ namespace RacesOfValheim if (served == 0) { - player.Message(MessageHud.MessageType.Center, "Not a drop went down."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_dvergar_not_drop_went_down")); return false; } m_nview.InvokeRPC("RoV_DvergarBotteSpend", served); string what = DvergarBotte.BrewDisplayName(brew); - player.Message(MessageHud.MessageType.Center, served < drinkers.Count - ? $"{served} drink {what}. The barrel runs dry." - : $"{served} drink {what}."); + player.Message(MessageHud.MessageType.Center, (served < drinkers.Count ? ModText.Get("rov_msg_dvergar_drink_barrel_runs_dry", served, what) : ModText.Get("rov_msg_dvergar_drink", served, what))); return true; } diff --git a/JotunnModStub/Dvergar/DvergarPatches.cs b/JotunnModStub/Dvergar/DvergarPatches.cs index 6de3f31..de75252 100644 --- a/JotunnModStub/Dvergar/DvergarPatches.cs +++ b/JotunnModStub/Dvergar/DvergarPatches.cs @@ -110,7 +110,7 @@ namespace RacesOfValheim DvergarAbilities.ConsumeOvercharge(Player.m_localPlayer)) { ScalePhysical(hit, DvergarConfig.RunicOverchargeMultiplier); - Player.m_localPlayer.Message(MessageHud.MessageType.TopLeft, "Runic Overcharge discharges"); + Player.m_localPlayer.Message(MessageHud.MessageType.TopLeft, ModText.Get("rov_msg_dvergar_runic_overcharge_discharges")); } } diff --git a/JotunnModStub/Fenrir/FenrirBehaviors.cs b/JotunnModStub/Fenrir/FenrirBehaviors.cs index 9b13a35..9f71886 100644 --- a/JotunnModStub/Fenrir/FenrirBehaviors.cs +++ b/JotunnModStub/Fenrir/FenrirBehaviors.cs @@ -920,7 +920,7 @@ namespace RacesOfValheim lastNoEitrMessage = Time.time; Player.m_localPlayer.Message(MessageHud.MessageType.Center, - "Only breath comes out. The fire wants eitr."); + ModText.Get("rov_msg_fenrir_only_breath_comes_out_fire")); } private void StartFire() diff --git a/JotunnModStub/Fenrir/FenrirMangiatoia.cs b/JotunnModStub/Fenrir/FenrirMangiatoia.cs index b098f0a..8280607 100644 --- a/JotunnModStub/Fenrir/FenrirMangiatoia.cs +++ b/JotunnModStub/Fenrir/FenrirMangiatoia.cs @@ -155,7 +155,7 @@ namespace RacesOfValheim PieceDensityLimit.Register(PieceName, PieceDensityLimit.RadiusForArea(DensityAreaKm2), MaxTroughsInRange, - "There is already {0} of these within a day's walk. A pack needs room."); + "rov_msg_build_limit_fenrir_packtrough"); } // ---------------------------------------------------------------- items diff --git a/JotunnModStub/Fenrir/FenrirMangiatoiaBehaviour.cs b/JotunnModStub/Fenrir/FenrirMangiatoiaBehaviour.cs index a7e2bfb..8a54e0f 100644 --- a/JotunnModStub/Fenrir/FenrirMangiatoiaBehaviour.cs +++ b/JotunnModStub/Fenrir/FenrirMangiatoiaBehaviour.cs @@ -289,7 +289,7 @@ namespace RacesOfValheim if (item == null) item = FindAnyInput(inventory); if (item == null) { - user.Message(MessageHud.MessageType.Center, "It wants meat. Any meat."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_wants_meat_any_meat")); return false; } @@ -342,19 +342,19 @@ namespace RacesOfValheim { if (IsUpgraded()) { - user.Message(MessageHud.MessageType.Center, "It has already had one."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_has_already_had_one")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < FenrirMangiatoia.UpgradeProgressionState) { - user.Message(MessageHud.MessageType.Center, "The blood will not take. Something in the plains has to fall first."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_blood_will_not_take_something")); return false; } if (inventory.CountItems(YagluthDropName()) < 1) { - user.Message(MessageHud.MessageType.Center, "It wants what Yagluth left behind."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_wants_what_yagluth_left_behind")); return false; } @@ -362,7 +362,7 @@ namespace RacesOfValheim inventory.RemoveItem(item, 1); m_nview.InvokeRPC("RoV_FenrirUpgrade"); - user.Message(MessageHud.MessageType.Center, "The trough takes it. The line runs deeper now."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_trough_takes_line_runs_deeper")); return true; } @@ -404,7 +404,7 @@ namespace RacesOfValheim if (bound.Count > 0 && Player.m_localPlayer != null) { Player.m_localPlayer.Message(MessageHud.MessageType.Center, - $"The trough is broken. {bound.Count} will not outlast it by long."); + ModText.Get("rov_msg_fenrir_trough_broken_will_not_outlast", bound.Count)); } SetFeed(0f); diff --git a/JotunnModStub/Fenrir/FenrirRace.cs b/JotunnModStub/Fenrir/FenrirRace.cs index 22c1ee6..f6ff044 100644 --- a/JotunnModStub/Fenrir/FenrirRace.cs +++ b/JotunnModStub/Fenrir/FenrirRace.cs @@ -176,7 +176,7 @@ namespace RacesOfValheim { // forms allowed by day would otherwise be locked out right after every sunrise. if (rules.NeedsNight && sunSicknessTimer > 0f) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The beast is tired"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_beast_tired")); return; } @@ -188,7 +188,7 @@ namespace RacesOfValheim { if (rules.NeedsNight && !EnvMan.IsNight()) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "The beast rests. You can only transform at night."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_beast_rests_can_only_transform")); return; } @@ -203,8 +203,9 @@ namespace RacesOfValheim { if (remaining < 0) remaining = 0; int rMin = Mathf.FloorToInt(remaining / 60f); int rSec = Mathf.FloorToInt(remaining % 60f); - string formName = rules.Form == FenrirProgression.FormType.Cultist ? "Cultist" : "Fenrir"; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"{formName} form is on cooldown ({rMin}:{rSec:00})."); + // A token, which the message's own localization pass translates along with the rest. + string formName = rules.Form == FenrirProgression.FormType.Cultist ? "$rov_msg_fenrir_formname_cultist" : "$rov_msg_fenrir_formname_fenrir"; + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_form_cooldown", formName, rMin, (rSec).ToString("00"))); return; } } @@ -410,7 +411,7 @@ namespace RacesOfValheim { Player.m_localPlayer.GetSEMan().AddStatusEffect("SE_WolfForm".GetStableHashCode(), true); var se = Player.m_localPlayer.GetSEMan().GetStatusEffect("SE_WolfForm".GetStableHashCode()); if (se != null) se.m_ttl = ttl; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are an Ulv!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_are_ulv")); } else if (prefabName == "Wolf") { @@ -418,7 +419,7 @@ namespace RacesOfValheim { Player.m_localPlayer.GetSEMan().AddStatusEffect("SE_WolfForm".GetStableHashCode(), true); var se = Player.m_localPlayer.GetSEMan().GetStatusEffect("SE_WolfForm".GetStableHashCode()); if (se != null) se.m_ttl = ttl; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are a Wolf!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_are_wolf")); } else if (prefabName == "Fenring_Cultist") { @@ -426,7 +427,7 @@ namespace RacesOfValheim { Player.m_localPlayer.GetSEMan().AddStatusEffect("SE_CultistForm".GetStableHashCode(), true); var se = Player.m_localPlayer.GetSEMan().GetStatusEffect("SE_CultistForm".GetStableHashCode()); if (se != null) se.m_ttl = ttl; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are a Cultist!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_are_cultist")); } else { @@ -434,7 +435,7 @@ namespace RacesOfValheim { Player.m_localPlayer.GetSEMan().AddStatusEffect("SE_FenrirForm".GetStableHashCode(), true); var se = Player.m_localPlayer.GetSEMan().GetStatusEffect("SE_FenrirForm".GetStableHashCode()); if (se != null) se.m_ttl = ttl; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are a Fenring!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_are_fenring")); } isTransformed = true; @@ -480,7 +481,7 @@ namespace RacesOfValheim { Player.m_localPlayer.GetSEMan().RemoveStatusEffect("SE_WolfForm".GetStableHashCode()); isTransformed = false; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You returned to human form."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_returned_human_form")); if (activeRules != null && activeRules.CooldownMinutes > 0) { diff --git a/JotunnModStub/Fenrir/FenrirStatusEffects.cs b/JotunnModStub/Fenrir/FenrirStatusEffects.cs index b519103..43de139 100644 --- a/JotunnModStub/Fenrir/FenrirStatusEffects.cs +++ b/JotunnModStub/Fenrir/FenrirStatusEffects.cs @@ -17,7 +17,7 @@ namespace RacesOfValheim base.Stop(); if (Player.m_localPlayer != null) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"{m_name} is Ready!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_fenrir_ready", m_name)); } } } diff --git a/JotunnModStub/ModText.cs b/JotunnModStub/ModText.cs index 4e43258..b5bb3e9 100644 --- a/JotunnModStub/ModText.cs +++ b/JotunnModStub/ModText.cs @@ -21,7 +21,13 @@ namespace RacesOfValheim { if (Localization.instance == null) return "[" + key + "]"; - string[] words = args.Select(a => a?.ToString() ?? "").ToArray(); + // Each argument is localized on its own before it goes in. An argument is often a token + // itself - a creature's m_name, a boss - and left for a later pass it would run into + // whatever follows the $1: "$enemy_eikthyr's power" reads as the token + // "enemy_eikthyr's", because an apostrophe does not end a token. + string[] words = args + .Select(a => Localization.instance.Localize(a?.ToString() ?? "")) + .ToArray(); return Localization.instance.Localize("$" + key, words); } diff --git a/JotunnModStub/PieceDensityLimit.cs b/JotunnModStub/PieceDensityLimit.cs index 1546e21..daf3047 100644 --- a/JotunnModStub/PieceDensityLimit.cs +++ b/JotunnModStub/PieceDensityLimit.cs @@ -62,6 +62,7 @@ namespace RacesOfValheim /// Caps a piece. Call once from the chain's Register(); calling twice just replaces the entry, /// so a Register() that runs more than once cannot stack limits. /// + /// A translation key, not text: its $1 is how many stand nearby, $2 the limit. public static void Register(string piecePrefabName, float radius, int max, string refusalMessage) { if (string.IsNullOrEmpty(piecePrefabName) || max < 1 || radius <= 0f) @@ -156,7 +157,7 @@ namespace RacesOfValheim if (player != null) { - player.Message(MessageHud.MessageType.Center, string.Format(limit.Message, nearby, limit.Max)); + player.Message(MessageHud.MessageType.Center, ModText.Get(limit.Message, nearby, limit.Max)); } return false; } diff --git a/JotunnModStub/RaceCaveBuilding.cs b/JotunnModStub/RaceCaveBuilding.cs index 4e026d7..e9ddb8f 100644 --- a/JotunnModStub/RaceCaveBuilding.cs +++ b/JotunnModStub/RaceCaveBuilding.cs @@ -155,7 +155,7 @@ namespace RacesOfValheim allowing = true; Jotunn.Logger.LogInfo($"[Races] In a troll cave: {flipped.Count} pieces temporarily allowed in dungeons."); - player.Message(MessageHud.MessageType.Center, "This cave will hold what you build in it."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_build_this_cave_will_hold_what")); } /// diff --git a/JotunnModStub/RaceClaws.cs b/JotunnModStub/RaceClaws.cs index 3fc2bbb..818ffc7 100644 --- a/JotunnModStub/RaceClaws.cs +++ b/JotunnModStub/RaceClaws.cs @@ -899,7 +899,7 @@ namespace RacesOfValheim if (owner == null) return true; if (Player.m_localPlayer == null || owner != RaceClawSet.For(Player.m_localPlayer)) return true; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "They are part of your hands."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_claws_they_are_part_hands")); return false; } } diff --git a/JotunnModStub/RaceMenuWard.cs b/JotunnModStub/RaceMenuWard.cs index 5457560..94ef37a 100644 --- a/JotunnModStub/RaceMenuWard.cs +++ b/JotunnModStub/RaceMenuWard.cs @@ -201,20 +201,20 @@ namespace RacesOfValheim string prefabName = item.m_dropPrefab != null ? item.m_dropPrefab.name : null; if (prefabName == null || !BossProgressionManager.BossDropStates.TryGetValue(prefabName, out int state)) { - user.Message(MessageHud.MessageType.Center, "The ward has no use for that."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_ward_ward_has_no_use_that")); return true; } if (!BossProgressionManager.UsePersonalProgression) { - user.Message(MessageHud.MessageType.Center, "Switch to personal progression first."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_ward_switch_personal_progression_first")); return true; } if (BossProgressionManager.PersonalState >= state) { user.Message(MessageHud.MessageType.Center, - $"You already carry {BossProgressionManager.GetBossNameForState(state)}'s power."); + ModText.Get("rov_msg_ward_already_carry_s_power", BossProgressionManager.GetBossTokenForState(state))); return true; } @@ -223,7 +223,7 @@ namespace RacesOfValheim BossProgressionManager.PersonalState = state; user.Message(MessageHud.MessageType.Center, - $"{BossProgressionManager.GetBossNameForState(state)}'s power is yours."); + ModText.Get("rov_msg_ward_s_power_yours", BossProgressionManager.GetBossTokenForState(state))); RefreshRaceState(); return true; diff --git a/JotunnModStub/RacesOfValheim.cs b/JotunnModStub/RacesOfValheim.cs index 7778632..f9d3462 100644 --- a/JotunnModStub/RacesOfValheim.cs +++ b/JotunnModStub/RacesOfValheim.cs @@ -199,16 +199,16 @@ namespace RacesOfValheim } int state = BossProgressionManager.GetCurrentProgressionState(); - string boss = BossProgressionManager.GetBossNameForState(state); + string boss = BossProgressionManager.GetBossTokenForState(state); if (clearedPersonal) - summary = $"Personal progression reset to {boss} ({state}/{BossProgressionManager.MaxState}). Claim your relics again."; + summary = ModText.Get("rov_msg_core_progression_reset", boss, state, BossProgressionManager.MaxState); else if (BossProgressionManager.UsePersonalProgression) - summary = $"Nothing to reset - you have claimed no relics yet ({state}/{BossProgressionManager.MaxState})."; + summary = ModText.Get("rov_msg_core_nothing_reset_personal", state, BossProgressionManager.MaxState); else - summary = $"Nothing to reset - you follow the world's progression: {boss} ({state}/{BossProgressionManager.MaxState})."; + summary = ModText.Get("rov_msg_core_nothing_reset_world", boss, state, BossProgressionManager.MaxState); - if (hadDebugOverride) summary += " Debug override cleared."; + if (hadDebugOverride) summary += " " + ModText.Get("rov_msg_core_debug_override_cleared"); Player player = Player.m_localPlayer; if (player != null) @@ -537,7 +537,7 @@ namespace RacesOfValheim Player.m_localPlayer.m_customData["Race"] = "Human"; ZNetView nview = Player.m_localPlayer.GetComponent(); if (nview != null && nview.IsValid()) nview.GetZDO().Set("RacesOfValheim_Race", "Human"); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose to remain Human."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_remain_human")); } CloseRaceSelectionMenu(); } @@ -552,7 +552,7 @@ namespace RacesOfValheim Player.m_localPlayer.m_customData["FenrirCurse_Active"] = "true"; Player.m_localPlayer.GetSEMan().AddStatusEffect("SE_FenrirCurse".GetStableHashCode(), true); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Fenrir."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_fenrir")); } CloseRaceSelectionMenu(); } @@ -565,7 +565,7 @@ namespace RacesOfValheim ZNetView nview = Player.m_localPlayer.GetComponent(); if (nview != null && nview.IsValid()) nview.GetZDO().Set("RacesOfValheim_Race", "Skadi"); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of Skadi."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_skadi")); // Force update skin colors VisEquipment visEq = Player.m_localPlayer.GetComponent(); @@ -594,7 +594,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Skeleton."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_skeleton")); CloseRaceSelectionMenu(); } } @@ -624,7 +624,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Aswid."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_aswid")); CloseRaceSelectionMenu(); } } @@ -652,7 +652,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Furling."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_furling")); CloseRaceSelectionMenu(); } } @@ -694,7 +694,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Trol."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_trol")); CloseRaceSelectionMenu(); } } @@ -740,7 +740,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Draugh."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_draugh")); CloseRaceSelectionMenu(); } } @@ -777,7 +777,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateVisuals", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Dvergar."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_dvergar")); CloseRaceSelectionMenu(); } } @@ -813,7 +813,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateVisuals", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Sverm."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_sverm")); CloseRaceSelectionMenu(); } } @@ -868,7 +868,7 @@ namespace RacesOfValheim visEq.GetType().GetMethod("UpdateColors", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public)?.Invoke(visEq, null); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You chose the path of the Trenta."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_chose_path_trenta")); CloseRaceSelectionMenu(); } } @@ -1015,7 +1015,7 @@ namespace RacesOfValheim if (Player.m_localPlayer != null) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"World Progression State: {state}"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_world_progression_state", state)); } } } @@ -1038,7 +1038,7 @@ namespace RacesOfValheim Console.instance.Print($"[DEBUG] Progression state increased to: {BossProgressionManager.DebugState}"); if (Player.m_localPlayer != null) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"Progression State: {BossProgressionManager.DebugState}"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_core_progression_state", BossProgressionManager.DebugState)); Traverse.Create(Player.m_localPlayer).Method("SetupEquipment").GetValue(); } } diff --git a/JotunnModStub/RaisedThrall.cs b/JotunnModStub/RaisedThrall.cs index f1ecd9c..c46aea5 100644 --- a/JotunnModStub/RaisedThrall.cs +++ b/JotunnModStub/RaisedThrall.cs @@ -53,7 +53,7 @@ namespace RacesOfValheim public float m_homeCheckRange = 20f; /// Shown in the refusal when a station is not this player's to command. - public string m_refusalMessage = "It does not answer to you."; + public string m_refusalMessage = "$rov_msg_thrall_refusal_default"; /// /// How many thralls of OTHER kinds, from the same station, come along when this one is @@ -298,7 +298,7 @@ namespace RacesOfValheim { m_monsterAI.SetFollowTarget(null); GoHome(); - if (announce) player.Message(MessageHud.MessageType.Center, $"{m_character.m_name} returns."); + if (announce) player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_thrall_returns", m_character.m_name)); return true; } @@ -308,7 +308,7 @@ namespace RacesOfValheim { if (announce) { - player.Message(MessageHud.MessageType.Center, $"Only {m_maxFollowers} may walk with you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_thrall_only_may_walk_with", m_maxFollowers)); } return false; } @@ -323,7 +323,7 @@ namespace RacesOfValheim if (m_ai != null) m_ai.ResetPatrolPoint(); m_monsterAI.SetFollowTarget(player.gameObject); - if (announce) player.Message(MessageHud.MessageType.Center, $"{m_character.m_name} follows."); + if (announce) player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_thrall_follows", m_character.m_name)); return true; } @@ -355,9 +355,7 @@ namespace RacesOfValheim if (other.SetFollowing(player, follow, announce: false)) taken++; } - player.Message(MessageHud.MessageType.Center, follow - ? $"{m_character.m_name} rises with {taken}." - : $"{m_character.m_name} stands down with {taken}."); + player.Message(MessageHud.MessageType.Center, (follow ? ModText.Get("rov_msg_thrall_rises_with", m_character.m_name, taken) : ModText.Get("rov_msg_thrall_stands_down_with", m_character.m_name, taken))); } private static int CountFollowers(Player player, string kind) @@ -445,12 +443,12 @@ namespace RacesOfValheim if (came > 0) { - player.Message(MessageHud.MessageType.Center, $"{came} answer the call."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_thrall_answer_call", came)); } else if (refused > 0) { // The only way SetFollowing refuses a thrall that may be commanded is the cap. - player.Message(MessageHud.MessageType.Center, "No more may walk with you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_thrall_no_more_may_walk_with")); } } diff --git a/JotunnModStub/Skadi/DrakeFormBehavior.cs b/JotunnModStub/Skadi/DrakeFormBehavior.cs index ffd3b74..53b9049 100644 --- a/JotunnModStub/Skadi/DrakeFormBehavior.cs +++ b/JotunnModStub/Skadi/DrakeFormBehavior.cs @@ -257,7 +257,7 @@ namespace RacesOfValheim float cost = Mathf.Min(STAMINA_PER_PROJECTILE * projCount, MAX_VOLLEY_STAMINA); if (!Player.m_localPlayer.HaveStamina(cost)) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Not enough stamina"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_not_enough_stamina")); return false; } Player.m_localPlayer.UseStamina(cost); diff --git a/JotunnModStub/Skadi/SkadiGolem.cs b/JotunnModStub/Skadi/SkadiGolem.cs index 9a1035e..99fca6a 100644 --- a/JotunnModStub/Skadi/SkadiGolem.cs +++ b/JotunnModStub/Skadi/SkadiGolem.cs @@ -306,21 +306,21 @@ namespace RacesOfValheim if (!SkadiRace.IsLocalSkadi()) { - player.Message(MessageHud.MessageType.Center, "The stone does not answer to you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_stone_does_not_answer")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < ModerProgressionState) { player.Message(MessageHud.MessageType.Center, - "The tear is cold. Nothing wakes in the stone until the mountain's queen has fallen."); + ModText.Get("rov_msg_skadi_tear_cold_nothing_wakes_stone")); return false; } CraftingStation station = FindStonecutter(position); if (station == null) { - player.Message(MessageHud.MessageType.Center, "It needs a stonecutter to be cut at."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_needs_stonecutter_cut_at")); return false; } @@ -328,7 +328,7 @@ namespace RacesOfValheim if (bound >= MaxPerStation) { player.Message(MessageHud.MessageType.Center, - $"That stonecutter already holds {bound}. It will not hold more."); + ModText.Get("rov_msg_skadi_that_stonecutter_already_holds_will", bound)); return false; } @@ -336,7 +336,7 @@ namespace RacesOfValheim if (nearby >= MaxInArea) { player.Message(MessageHud.MessageType.Center, - $"There are already {nearby} of these within a day's walk. The stone is spent."); + ModText.Get("rov_msg_skadi_there_are_already_these_within", nearby)); return false; } diff --git a/JotunnModStub/Skadi/SkadiGolemBehaviour.cs b/JotunnModStub/Skadi/SkadiGolemBehaviour.cs index b21621a..36554c4 100644 --- a/JotunnModStub/Skadi/SkadiGolemBehaviour.cs +++ b/JotunnModStub/Skadi/SkadiGolemBehaviour.cs @@ -181,7 +181,7 @@ namespace RacesOfValheim Vector3.Distance(Player.m_localPlayer.transform.position, transform.position) < 30f) { Player.m_localPlayer.Message(MessageHud.MessageType.Center, - "The stonecutter is gone. What it cut will not outlast it by long."); + ModText.Get("rov_msg_skadi_stonecutter_gone_what_cut_will")); } } diff --git a/JotunnModStub/Skadi/SkadiRace.cs b/JotunnModStub/Skadi/SkadiRace.cs index fbdffb6..16744af 100644 --- a/JotunnModStub/Skadi/SkadiRace.cs +++ b/JotunnModStub/Skadi/SkadiRace.cs @@ -246,7 +246,7 @@ namespace RacesOfValheim if (isTransformed && formExpireTime > 0f && Time.time >= formExpireTime) { formExpireTime = 0f; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Your dragon form fades."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_dragon_form_fades")); StartCoroutine(RevertToHumanRoutine()); return; } @@ -265,7 +265,7 @@ namespace RacesOfValheim DumpPrefabDebugInfo("Dragon"); DumpPrefabDebugInfo("Hatchling"); DumpPrefabDebugInfo("Fader"); - if (Player.m_localPlayer != null) Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Dumped Dragon/Drake/Fader debug info to console!"); + if (Player.m_localPlayer != null) Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_dumped_dragon_drake_fader_debug")); } } @@ -438,7 +438,7 @@ namespace RacesOfValheim // the Mistlands onward, so the old HaveEitr gate left it unusable for five tiers. if (!Player.m_localPlayer.HaveStamina(SPELL_STAMINA_COST)) { - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "Not enough stamina"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_not_enough_stamina")); return; } @@ -710,7 +710,7 @@ namespace RacesOfValheim if (remaining < 0) remaining = 0; int rMin = Mathf.FloorToInt(remaining / 60f); int rSec = Mathf.FloorToInt(remaining % 60f); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, $"Dragon Form is on cooldown ({rMin}:{rSec:00})."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_dragon_form_cooldown", rMin, (rSec).ToString("00"))); return; } } @@ -891,9 +891,9 @@ namespace RacesOfValheim DrakeFormBehavior behavior = currentTransformation.AddComponent(); behavior.Initialize(rules); - if (prefabName == "Hatchling") Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are a Drake!"); - else if (prefabName == "Dragon") Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are Moder!"); - else if (prefabName == "Fader") Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You are Fader!"); + if (prefabName == "Hatchling") Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_are_drake")); + else if (prefabName == "Dragon") Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_are_moder")); + else if (prefabName == "Fader") Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_are_fader")); isTransformed = true; StartFormTimer(rules); @@ -943,7 +943,7 @@ namespace RacesOfValheim isTransformed = false; formExpireTime = 0f; Player.m_localPlayer.GetSEMan().RemoveStatusEffect("SE_SkadiForm".GetStableHashCode(), true); - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You returned to human form."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skadi_returned_human_form")); if (activeRules != null && activeRules.CooldownMinutes > 0) { diff --git a/JotunnModStub/Skeleton/SkeletonBonePile.cs b/JotunnModStub/Skeleton/SkeletonBonePile.cs index 35fcdd9..9c6d6c1 100644 --- a/JotunnModStub/Skeleton/SkeletonBonePile.cs +++ b/JotunnModStub/Skeleton/SkeletonBonePile.cs @@ -136,7 +136,7 @@ namespace RacesOfValheim PieceDensityLimit.Register(PieceName, PieceDensityLimit.RadiusForArea(DensityAreaKm2), MaxPilesInRange, - "There are already {0} of these listening nearby. Take it further out."); + "rov_msg_build_limit_skeleton_bonepile"); } // ---------------------------------------------------------------- items @@ -282,7 +282,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = MaxFollowers; thrall.m_witherSeconds = OrphanWitherSeconds; thrall.m_homeCheckRange = HomeCheckRange; - thrall.m_refusalMessage = "These bones answer only to their own kind."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_skeleton"; thrall.m_escortCount = escortCount; PrefabManager.Instance.AddPrefab(prefab); diff --git a/JotunnModStub/Skeleton/SkeletonBonePileBehaviour.cs b/JotunnModStub/Skeleton/SkeletonBonePileBehaviour.cs index 002e2a4..f65e631 100644 --- a/JotunnModStub/Skeleton/SkeletonBonePileBehaviour.cs +++ b/JotunnModStub/Skeleton/SkeletonBonePileBehaviour.cs @@ -108,7 +108,7 @@ namespace RacesOfValheim { if (!IsUpgraded()) { - player.Message(MessageHud.MessageType.Center, "This pile cannot hold the rotten yet."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_this_pile_cannot_hold_rotten")); return false; } room = RancidCap() - GetSlots(SkeletonBonePile.KindRancid); @@ -149,7 +149,7 @@ namespace RacesOfValheim List bound = RaisedThrall.BoundTo(transform.position); if (bound.Count == 0) { - player.Message(MessageHud.MessageType.Center, "Nothing is standing yet. It wants bone."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_nothing_standing_yet_wants_bone")); return false; } @@ -169,13 +169,11 @@ namespace RacesOfValheim if (moved == 0) { // Every one of them refused, which for these means the player is not a Skeleton. - player.Message(MessageHud.MessageType.Center, "These bones answer only to their own kind."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_these_bones_answer_only_their")); return false; } - player.Message(MessageHud.MessageType.Center, anyFollowing - ? $"{moved} return to the pile." - : $"{moved} rise and follow."); + player.Message(MessageHud.MessageType.Center, (anyFollowing ? ModText.Get("rov_msg_skeleton_return_pile", moved) : ModText.Get("rov_msg_skeleton_rise_follow", moved))); return true; } @@ -183,19 +181,19 @@ namespace RacesOfValheim { if (IsUpgraded()) { - player.Message(MessageHud.MessageType.Center, "It has already had one."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_has_already_had_one")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < SkeletonBonePile.UpgradeProgressionState) { - player.Message(MessageHud.MessageType.Center, "The skull will not wake. Something older has to fall first."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_skull_will_not_wake_something")); return false; } inventory.RemoveItem(item, 1); m_nview.InvokeRPC("RoV_SkelUpgrade"); - player.Message(MessageHud.MessageType.Center, "The pile deepens. The rotten will stand here too."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_pile_deepens_rotten_will_stand")); return true; } @@ -332,7 +330,7 @@ namespace RacesOfValheim if (bound.Count > 0 && Player.m_localPlayer != null) { Player.m_localPlayer.Message(MessageHud.MessageType.Center, - $"The pile is broken. {bound.Count} fall where they stand."); + ModText.Get("rov_msg_skeleton_pile_broken_fall_where_they", bound.Count)); } } diff --git a/JotunnModStub/Skeleton/SkeletonPatches.cs b/JotunnModStub/Skeleton/SkeletonPatches.cs index 10fdf7d..6ffb291 100644 --- a/JotunnModStub/Skeleton/SkeletonPatches.cs +++ b/JotunnModStub/Skeleton/SkeletonPatches.cs @@ -80,7 +80,7 @@ namespace RacesOfValheim { if (SkeletonRace.IsSkeleton() && item.m_shared.m_itemType == ItemDrop.ItemData.ItemType.Consumable && (item.m_shared.m_food > 0 || item.m_shared.m_foodStamina > 0 || item.m_shared.m_foodEitr > 0)) { - __instance.Message(MessageHud.MessageType.Center, "Skeletons do not need to eat."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_skeletons_do_not_need_eat")); __result = false; return false; } @@ -88,7 +88,7 @@ namespace RacesOfValheim // survive this blanket refusal - everything else mortal still bounces. else if (AswidRace.IsAswid() && !AswidRace.BypassAswidFoodCheck && !AswidBloodRefinery.IsAswidMeal(item) && item.m_shared.m_itemType == ItemDrop.ItemData.ItemType.Consumable && (item.m_shared.m_food > 0 || item.m_shared.m_foodStamina > 0 || item.m_shared.m_foodEitr > 0)) { - __instance.Message(MessageHud.MessageType.Center, "Mortal food disgusts you."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_mortal_food_disgusts")); __result = false; return false; } @@ -630,7 +630,7 @@ namespace RacesOfValheim UnityEngine.Object.Instantiate(vfx, Player.m_localPlayer.transform.position, Quaternion.identity); } - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "You have been resurrected by dark magic!"); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_skeleton_have_been_resurrected_by_dark")); return false; // Skip applying this lethal damage } } diff --git a/JotunnModStub/Sverm/SvermBlisterTick.cs b/JotunnModStub/Sverm/SvermBlisterTick.cs index 507b97f..b0fd8ad 100644 --- a/JotunnModStub/Sverm/SvermBlisterTick.cs +++ b/JotunnModStub/Sverm/SvermBlisterTick.cs @@ -79,7 +79,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = -1; thrall.m_witherSeconds = SvermConfig.TroopWitherSeconds; thrall.m_homeCheckRange = SvermConfig.TroopHomeCheckRange; - thrall.m_refusalMessage = "It does not smell your colony on you."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_sverm"; // No SkeletonSentryBehaviour. A tick that healed itself would be a tick that never gets // round to exploding, which is its entire job. diff --git a/JotunnModStub/Sverm/SvermBrood.cs b/JotunnModStub/Sverm/SvermBrood.cs index f67c92d..be162e4 100644 --- a/JotunnModStub/Sverm/SvermBrood.cs +++ b/JotunnModStub/Sverm/SvermBrood.cs @@ -118,7 +118,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = -1; // the cap is the colony's, counted at the nest, not per player thrall.m_witherSeconds = SvermConfig.TroopWitherSeconds; thrall.m_homeCheckRange = SvermConfig.TroopHomeCheckRange; - thrall.m_refusalMessage = "It does not smell your colony on you."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_sverm"; // Section 11.2, reused whole: ten seconds untouched, then two percent a second. Healing // and not respawning - a dead troop is dead, and the egg it cost is already back. diff --git a/JotunnModStub/Sverm/SvermClawSlot.cs b/JotunnModStub/Sverm/SvermClawSlot.cs index 34bf82e..3d9212b 100644 --- a/JotunnModStub/Sverm/SvermClawSlot.cs +++ b/JotunnModStub/Sverm/SvermClawSlot.cs @@ -300,7 +300,7 @@ namespace RacesOfValheim if (!SvermClawSlot.IsClaws(item)) return true; if (Player.m_localPlayer == null || !SvermVisuals.IsSvermPlayer(Player.m_localPlayer)) return true; - Player.m_localPlayer.Message(MessageHud.MessageType.Center, "They are part of your hands."); + Player.m_localPlayer.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_they_are_part_hands")); return false; } } diff --git a/JotunnModStub/Sverm/SvermFood.cs b/JotunnModStub/Sverm/SvermFood.cs index dad338b..21402c9 100644 --- a/JotunnModStub/Sverm/SvermFood.cs +++ b/JotunnModStub/Sverm/SvermFood.cs @@ -235,7 +235,7 @@ namespace RacesOfValheim if (item.m_dropPrefab != null && item.m_dropPrefab.name.StartsWith("SvermMeal_") == false && IsAswidBlood(item)) { - player.Message(MessageHud.MessageType.Center, "Alchemical blood is not food."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_alchemical_blood_not_food")); return false; } diff --git a/JotunnModStub/Sverm/SvermHive.cs b/JotunnModStub/Sverm/SvermHive.cs index 3c2266b..468846b 100644 --- a/JotunnModStub/Sverm/SvermHive.cs +++ b/JotunnModStub/Sverm/SvermHive.cs @@ -178,13 +178,13 @@ namespace RacesOfValheim if (!SvermVisuals.IsSvermPlayer(player)) { - player.Message(MessageHud.MessageType.Center, "Only the Sverm can raise a hive."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_only_sverm_can_raise_hive")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < SvermConfig.HiveUnlockState) { - player.Message(MessageHud.MessageType.Center, "The colony will not wake until the Elder falls."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_colony_will_not_wake_until")); return false; } @@ -198,7 +198,7 @@ namespace RacesOfValheim private static void RegisterNestDensity() { PieceDensityLimit.Register(PieceName, SvermConfigManagement.NestRadius, SvermConfigManagement.NestMax, - "There is already a hive holding this ground."); + "rov_msg_build_limit_sverm_hive"); } /// @@ -437,7 +437,7 @@ namespace RacesOfValheim if (!SvermVisuals.IsSvermPlayer(player)) { - player.Message(MessageHud.MessageType.Center, "The hive does not know you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_hive_does_not_know")); return true; } diff --git a/JotunnModStub/Sverm/SvermHiveGoods.cs b/JotunnModStub/Sverm/SvermHiveGoods.cs index 7962d3c..7ba51e6 100644 --- a/JotunnModStub/Sverm/SvermHiveGoods.cs +++ b/JotunnModStub/Sverm/SvermHiveGoods.cs @@ -297,7 +297,7 @@ namespace RacesOfValheim // stage it was not paid for cannot be undone. if (!SvermBiomass.Spend(hive.transform, good.Price)) { - player?.Message(MessageHud.MessageType.Center, "Not enough biomass in the bank."); + player?.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_not_enough_biomass_bank")); return false; } diff --git a/JotunnModStub/Sverm/SvermHiveStore.cs b/JotunnModStub/Sverm/SvermHiveStore.cs index f63f642..fe7a064 100644 --- a/JotunnModStub/Sverm/SvermHiveStore.cs +++ b/JotunnModStub/Sverm/SvermHiveStore.cs @@ -128,7 +128,7 @@ namespace RacesOfValheim float room = SvermBiomass.Space(hive.transform); if (room <= 0f) { - player.Message(MessageHud.MessageType.Center, "The hive is full. Give it time to digest."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_hive_full_give_time_digest")); return true; } @@ -149,12 +149,12 @@ namespace RacesOfValheim inventory.RemoveItem(item, units); player.Message(MessageHud.MessageType.TopLeft, - $"{name} x{units} -> +{fed:0} biomass, digesting"); + ModText.Get("rov_msg_sverm_x_biomass_digesting", name, units, (fed).ToString("0"))); return true; } player.Message(MessageHud.MessageType.Center, - "Nothing here it will eat. Food, wood and resin - honey and royal jelly are medicine."); + ModText.Get("rov_msg_sverm_nothing_here_will_eat_food")); return true; } } @@ -202,7 +202,7 @@ namespace RacesOfValheim if (!SvermVisuals.IsSvermPlayer(player)) { - player.Message(MessageHud.MessageType.Center, "The hive does not know you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_hive_does_not_know")); return true; } @@ -389,14 +389,14 @@ namespace RacesOfValheim if (!SvermVisuals.IsSvermPlayer(player)) { - player.Message(MessageHud.MessageType.Center, "Only the Sverm can raise a market."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_only_sverm_can_raise_market")); return false; } if (SvermHive.NearestNest(position, SvermConfigManagement.AuraRadius) == null) { player.Message(MessageHud.MessageType.Center, - $"A market has to stand within {SvermConfigManagement.AuraRadius:0} metres of a hive."); + ModText.Get("rov_msg_sverm_market_has_stand_within_metres", (SvermConfigManagement.AuraRadius).ToString("0"))); return false; } @@ -410,7 +410,7 @@ namespace RacesOfValheim private static void RegisterMarketDensity() { PieceDensityLimit.Register(PieceName, SvermConfigManagement.AuraRadius, 1, - "This hive already has a market."); + "rov_msg_build_limit_sverm_market"); } } @@ -428,7 +428,7 @@ namespace RacesOfValheim if (!SvermVisuals.IsSvermPlayer(player)) { - player.Message(MessageHud.MessageType.Center, "The hive does not know you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_hive_does_not_know")); return true; } @@ -439,7 +439,7 @@ namespace RacesOfValheim if (nest == null) { player.Message(MessageHud.MessageType.Center, - $"No hive within {SvermConfigManagement.AuraRadius:0} metres. This counter is dead."); + ModText.Get("rov_msg_sverm_no_hive_within_metres_this", (SvermConfigManagement.AuraRadius).ToString("0"))); return true; } diff --git a/JotunnModStub/Sverm/SvermMedicine.cs b/JotunnModStub/Sverm/SvermMedicine.cs index 5fa46cd..3605304 100644 --- a/JotunnModStub/Sverm/SvermMedicine.cs +++ b/JotunnModStub/Sverm/SvermMedicine.cs @@ -54,7 +54,7 @@ namespace RacesOfValheim // Localized, because a creature's m_name is a token: printing it raw would put // "$enemy_seeker is not hurt" on the screen. string who = Localization.instance.Localize(patient.m_name); - player.Message(MessageHud.MessageType.Center, $"{who} is not hurt."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_not_hurt", who)); return true; } diff --git a/JotunnModStub/Sverm/SvermPatches.cs b/JotunnModStub/Sverm/SvermPatches.cs index 5d909f1..8d43fcc 100644 --- a/JotunnModStub/Sverm/SvermPatches.cs +++ b/JotunnModStub/Sverm/SvermPatches.cs @@ -76,7 +76,7 @@ namespace RacesOfValheim if (player == Player.m_localPlayer) { - player.Message(MessageHud.MessageType.Center, "Your carapace has no room for that."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_carapace_has_no_room_that")); } __result = false; diff --git a/JotunnModStub/Sverm/SvermRavagerForm.cs b/JotunnModStub/Sverm/SvermRavagerForm.cs index a8b9b88..91055b1 100644 --- a/JotunnModStub/Sverm/SvermRavagerForm.cs +++ b/JotunnModStub/Sverm/SvermRavagerForm.cs @@ -149,7 +149,7 @@ namespace RacesOfValheim if (IsActive && Time.time >= expiresAt) { - RunExit(player, spendCooldown: true, "The shell recedes."); + RunExit(player, spendCooldown: true, "$rov_msg_sverm_shell_recedes"); return; } @@ -165,13 +165,13 @@ namespace RacesOfValheim if (!SvermProgression.Current.RavagerForm) { - player.Message(MessageHud.MessageType.Center, "The strain has not taken yet."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_strain_has_not_taken_yet")); return; } if (Time.time < nextAllowedAt) { - player.Message(MessageHud.MessageType.Center, "The strain is spent."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_strain_spent")); return; } @@ -285,7 +285,7 @@ namespace RacesOfValheim PlayEffect(SvermConfig.RavagerMorphInEffects, player.transform.position); - player.Message(MessageHud.MessageType.Center, "The Ravager Strain takes hold."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_sverm_ravager_strain_takes_hold")); } private static void PlayEffect(string[] candidates, Vector3 where) diff --git a/JotunnModStub/Translations/English/messages.json b/JotunnModStub/Translations/English/messages.json new file mode 100644 index 0000000..a8b69c1 --- /dev/null +++ b/JotunnModStub/Translations/English/messages.json @@ -0,0 +1,193 @@ +{ + "rov_msg_aswid_aura_disabled": "Vampiric Aura: DISABLED", + "rov_msg_aswid_aura_enabled": "Vampiric Aura: ENABLED", + "rov_msg_aswid_dominate_cooldown_m_s": "Dominate on cooldown ($1m $2s)", + "rov_msg_aswid_dominated": "$1 dominated!", + "rov_msg_aswid_eclipse_cooldown_remaining_s": "Eclipse is on cooldown. Remaining: $1s", + "rov_msg_aswid_eclipse_descends": "An Eclipse descends...", + "rov_msg_aswid_eclipse_has_ended": "The Eclipse has ended.", + "rov_msg_aswid_following": "$1 is following.", + "rov_msg_aswid_living_blood_curdles_living_throat": "Living blood curdles in a living throat.", + "rov_msg_aswid_morning_sun_drives_bat_back": "The morning sun drives the bat back into your body", + "rov_msg_aswid_morning_sun_has_vanquished_horrible": "The morning sun has vanquished the horrible night", + "rov_msg_aswid_no_bone_grind": "No bone to grind.", + "rov_msg_aswid_no_raw_flesh_render": "No raw flesh to render.", + "rov_msg_aswid_staying": "$1 is staying.", + "rov_msg_aswid_sun_burns_can_only_take": "The sun burns. You can only take bat form at night.", + "rov_msg_aswid_tamed": "Tamed!", + "rov_msg_aswid_vae_victis": "Vae Victis", + "rov_msg_aswid_what_horrible_night_have_curse": "what a horrible night to have a curse", + "rov_msg_build_limit_cooktable": "Another cook's table stands within forty paces. One cook to a yard.", + "rov_msg_build_limit_draugh_bodypile": "The ground here already carries $1 of these. Find another country.", + "rov_msg_build_limit_dvergar_contractbank": "There is already $1 contract bank within a day's walk. One ledger per valley.", + "rov_msg_build_limit_fenrir_packtrough": "There is already $1 of these within a day's walk. A pack needs room.", + "rov_msg_build_limit_skeleton_bonepile": "There are already $1 of these listening nearby. Take it further out.", + "rov_msg_build_limit_smithtable": "Another smith's table stands within forty paces. One smith to a yard.", + "rov_msg_build_limit_sverm_hive": "There is already a hive holding this ground.", + "rov_msg_build_limit_sverm_market": "This hive already has a market.", + "rov_msg_build_limit_trenta_grove": "This country already answers to $1 of these. Plant it somewhere else.", + "rov_msg_build_this_cave_will_hold_what": "This cave will hold what you build in it.", + "rov_msg_butler_already_at_work": "It is already at work.", + "rov_msg_butler_bones_are_not_ready_s": "The bones are not ready. $1s.", + "rov_msg_butler_bones_do_not_answer_blood": "The bones do not answer to your blood.", + "rov_msg_butler_nothing_answers": "Nothing answers.", + "rov_msg_butler_only_skadi_s_hearth_kept": "Only Skadi's hearth is kept by the dead.", + "rov_msg_butler_servant_rises": "The servant rises.", + "rov_msg_claws_they_are_part_hands": "They are part of your hands.", + "rov_msg_core_chose_path_aswid": "You chose the path of the Aswid.", + "rov_msg_core_chose_path_draugh": "You chose the path of the Draugh.", + "rov_msg_core_chose_path_dvergar": "You chose the path of the Dvergar.", + "rov_msg_core_chose_path_fenrir": "You chose the path of the Fenrir.", + "rov_msg_core_chose_path_furling": "You chose the path of the Furling.", + "rov_msg_core_chose_path_skadi": "You chose the path of Skadi.", + "rov_msg_core_chose_path_skeleton": "You chose the path of the Skeleton.", + "rov_msg_core_chose_path_sverm": "You chose the path of the Sverm.", + "rov_msg_core_chose_path_trenta": "You chose the path of the Trenta.", + "rov_msg_core_chose_path_trol": "You chose the path of the Trol.", + "rov_msg_core_chose_remain_human": "You chose to remain Human.", + "rov_msg_core_debug_override_cleared": "Debug override cleared.", + "rov_msg_core_nothing_reset_personal": "Nothing to reset - you have claimed no relics yet ($1/$2).", + "rov_msg_core_nothing_reset_world": "Nothing to reset - you follow the world's progression: $1 ($2/$3).", + "rov_msg_core_progression_reset": "Personal progression reset to $1 ($2/$3). Claim your relics again.", + "rov_msg_core_progression_state": "Progression State: $1", + "rov_msg_core_world_progression_state": "World Progression State: $1", + "rov_msg_draugh_bone_will_not_wake_something": "The bone will not wake. Something older has to fall first.", + "rov_msg_draugh_draugr_consume_only_raw_flesh": "Draugr consume only raw flesh, eyes, entrails or blood.", + "rov_msg_draugh_has_already_had_one": "It has already had one.", + "rov_msg_draugh_northern_wind_blows": "The northern wind blows", + "rov_msg_draugh_pile_broken_will_not_outlast": "The pile is broken. $1 will not outlast it by more than a minute.", + "rov_msg_draugh_pile_stirs_will_keep_officers": "The pile stirs. It will keep officers now.", + "rov_msg_draugh_steal_their_breath_death_denied": "Steal Their Breath! Death is denied.", + "rov_msg_draugh_swarm_terror": "Swarm of Terror!", + "rov_msg_draugh_this_pile_keeps_no_officers": "This pile keeps no officers yet.", + "rov_msg_draugh_this_rotting_flesh_fatal_living": "This rotting flesh is fatal to the living.", + "rov_msg_draugh_wants_flesh_or_head_one": "It wants flesh, or the head of one of its own.", + "rov_msg_draugh_zombie_ritual_activated_borrowed_time": "Zombie Ritual Activated! Your borrowed time is fading...", + "rov_msg_dvergar_contract_runic_do_not_sign": "The contract is in runic. You do not sign it.", + "rov_msg_dvergar_do_not_know_what_goes": "You do not know what goes in it.", + "rov_msg_dvergar_drink": "$1 drink $2.", + "rov_msg_dvergar_drink_barrel_runs_dry": "$1 drink $2. The barrel runs dry.", + "rov_msg_dvergar_empty_so_are": "It is empty, and so are you.", + "rov_msg_dvergar_five_contracts_all_ledger_holds": "Five contracts is all the ledger holds.", + "rov_msg_dvergar_has_already_had_one": "It has already had one.", + "rov_msg_dvergar_ledger_not_written": "The ledger is not written for you.", + "rov_msg_dvergar_ledger_rewritten_better_names_sign": "The ledger is rewritten. Better names sign it now.", + "rov_msg_dvergar_ledger_shut": "The ledger is shut.", + "rov_msg_dvergar_nobody_at_barrel": "Nobody is at the barrel.", + "rov_msg_dvergar_not_drop_went_down": "Not a drop went down.", + "rov_msg_dvergar_not_enough_eitr": "Not enough eitr", + "rov_msg_dvergar_not_while_she_still_sits": "Not while she still sits under the mist.", + "rov_msg_dvergar_runic_overcharge_discharges": "Runic Overcharge discharges", + "rov_msg_dvergar_runic_overcharge_next_blow_loaded": "Runic Overcharge: your next blow is loaded", + "rov_msg_dvergar_runic_ping_echoes_answer": "Runic Ping: $1 echoes answer", + "rov_msg_dvergar_runic_ping_stone_silent": "Runic Ping: the stone is silent", + "rov_msg_dvergar_signs": "$1 signs on.", + "rov_msg_dvergar_there_still": "There is still $1 in it.", + "rov_msg_dvergar_whatever_does_nothing_anyone": "Whatever is in it does nothing to anyone.", + "rov_msg_fenrir_are_cultist": "You are a Cultist!", + "rov_msg_fenrir_are_fenring": "You are a Fenring!", + "rov_msg_fenrir_are_ulv": "You are an Ulv!", + "rov_msg_fenrir_are_wolf": "You are a Wolf!", + "rov_msg_fenrir_beast_rests_can_only_transform": "The beast rests. You can only transform at night.", + "rov_msg_fenrir_beast_tired": "The beast is tired", + "rov_msg_fenrir_blood_will_not_take_something": "The blood will not take. Something in the plains has to fall first.", + "rov_msg_fenrir_form_cooldown": "$1 form is on cooldown ($2:$3).", + "rov_msg_fenrir_formname_cultist": "Cultist", + "rov_msg_fenrir_formname_fenrir": "Fenrir", + "rov_msg_fenrir_has_already_had_one": "It has already had one.", + "rov_msg_fenrir_only_breath_comes_out_fire": "Only breath comes out. The fire wants eitr.", + "rov_msg_fenrir_ready": "$1 is Ready!", + "rov_msg_fenrir_returned_human_form": "You returned to human form.", + "rov_msg_fenrir_trough_broken_will_not_outlast": "The trough is broken. $1 will not outlast it by long.", + "rov_msg_fenrir_trough_takes_line_runs_deeper": "The trough takes it. The line runs deeper now.", + "rov_msg_fenrir_wants_meat_any_meat": "It wants meat. Any meat.", + "rov_msg_fenrir_wants_what_yagluth_left_behind": "It wants what Yagluth left behind.", + "rov_msg_skadi_are_drake": "You are a Drake!", + "rov_msg_skadi_are_fader": "You are Fader!", + "rov_msg_skadi_are_moder": "You are Moder!", + "rov_msg_skadi_dragon_form_cooldown": "Dragon Form is on cooldown ($1:$2).", + "rov_msg_skadi_dragon_form_fades": "Your dragon form fades.", + "rov_msg_skadi_dumped_dragon_drake_fader_debug": "Dumped Dragon/Drake/Fader debug info to console!", + "rov_msg_skadi_needs_stonecutter_cut_at": "It needs a stonecutter to be cut at.", + "rov_msg_skadi_not_enough_stamina": "Not enough stamina", + "rov_msg_skadi_returned_human_form": "You returned to human form.", + "rov_msg_skadi_stone_does_not_answer": "The stone does not answer to you.", + "rov_msg_skadi_stonecutter_gone_what_cut_will": "The stonecutter is gone. What it cut will not outlast it by long.", + "rov_msg_skadi_tear_cold_nothing_wakes_stone": "The tear is cold. Nothing wakes in the stone until the mountain's queen has fallen.", + "rov_msg_skadi_that_stonecutter_already_holds_will": "That stonecutter already holds $1. It will not hold more.", + "rov_msg_skadi_there_are_already_these_within": "There are already $1 of these within a day's walk. The stone is spent.", + "rov_msg_skeleton_has_already_had_one": "It has already had one.", + "rov_msg_skeleton_have_been_resurrected_by_dark": "You have been resurrected by dark magic!", + "rov_msg_skeleton_mortal_food_disgusts": "Mortal food disgusts you.", + "rov_msg_skeleton_nothing_standing_yet_wants_bone": "Nothing is standing yet. It wants bone.", + "rov_msg_skeleton_pile_broken_fall_where_they": "The pile is broken. $1 fall where they stand.", + "rov_msg_skeleton_pile_deepens_rotten_will_stand": "The pile deepens. The rotten will stand here too.", + "rov_msg_skeleton_return_pile": "$1 return to the pile.", + "rov_msg_skeleton_rise_follow": "$1 rise and follow.", + "rov_msg_skeleton_skeletons_do_not_need_eat": "Skeletons do not need to eat.", + "rov_msg_skeleton_skull_will_not_wake_something": "The skull will not wake. Something older has to fall first.", + "rov_msg_skeleton_these_bones_answer_only_their": "These bones answer only to their own kind.", + "rov_msg_skeleton_this_pile_cannot_hold_rotten": "This pile cannot hold the rotten yet.", + "rov_msg_sverm_alchemical_blood_not_food": "Alchemical blood is not food.", + "rov_msg_sverm_carapace_has_no_room_that": "Your carapace has no room for that.", + "rov_msg_sverm_colony_will_not_wake_until": "The colony will not wake until the Elder falls.", + "rov_msg_sverm_hive_does_not_know": "The hive does not know you.", + "rov_msg_sverm_hive_full_give_time_digest": "The hive is full. Give it time to digest.", + "rov_msg_sverm_market_has_stand_within_metres": "A market has to stand within $1 metres of a hive.", + "rov_msg_sverm_no_hive_within_metres_this": "No hive within $1 metres. This counter is dead.", + "rov_msg_sverm_not_enough_biomass_bank": "Not enough biomass in the bank.", + "rov_msg_sverm_not_hurt": "$1 is not hurt.", + "rov_msg_sverm_nothing_here_will_eat_food": "Nothing here it will eat. Food, wood and resin - honey and royal jelly are medicine.", + "rov_msg_sverm_only_sverm_can_raise_hive": "Only the Sverm can raise a hive.", + "rov_msg_sverm_only_sverm_can_raise_market": "Only the Sverm can raise a market.", + "rov_msg_sverm_ravager_strain_takes_hold": "The Ravager Strain takes hold.", + "rov_msg_sverm_shell_recedes": "The shell recedes.", + "rov_msg_sverm_strain_has_not_taken_yet": "The strain has not taken yet.", + "rov_msg_sverm_strain_spent": "The strain is spent.", + "rov_msg_sverm_they_are_part_hands": "They are part of your hands.", + "rov_msg_sverm_x_biomass_digesting": "$1 x$2 -> +$3 biomass, digesting", + "rov_msg_thrall_answer_call": "$1 answer the call.", + "rov_msg_thrall_follows": "$1 follows.", + "rov_msg_thrall_no_more_may_walk_with": "No more may walk with you.", + "rov_msg_thrall_only_may_walk_with": "Only $1 may walk with you.", + "rov_msg_thrall_refusal_default": "It does not answer to you.", + "rov_msg_thrall_refusal_draugh": "The dead do not take orders from the living.", + "rov_msg_thrall_refusal_dvergar": "Your name is not on the contract.", + "rov_msg_thrall_refusal_skeleton": "These bones answer only to their own kind.", + "rov_msg_thrall_refusal_sverm": "It does not smell your colony on you.", + "rov_msg_thrall_refusal_trol": "They were not paid by you.", + "rov_msg_thrall_returns": "$1 returns.", + "rov_msg_thrall_rises_with": "$1 rises with $2.", + "rov_msg_thrall_stands_down_with": "$1 stands down with $2.", + "rov_msg_trenta_are_muspell_ash_ember_given": "You are Muspell, ash and ember given shape.", + "rov_msg_trenta_elder_has_not_fallen_yet": "The Elder has not fallen yet.", + "rov_msg_trenta_grows": "It grows.", + "rov_msg_trenta_no_raw_flesh_rot": "No raw flesh to rot.", + "rov_msg_trenta_nothing_feed_wants_fertilizer": "Nothing to feed it. It wants Fertilizer.", + "rov_msg_trenta_nothing_there_feed": "Nothing there to feed.", + "rov_msg_trenta_return_rooted_form": "You return to your rooted form.", + "rov_msg_trenta_ripe_already": "It is ripe already.", + "rov_msg_trenta_root_will_not_take_hold": "The root will not take hold for you.", + "rov_msg_trenta_still_growing_minutes": "Still growing. $1 minutes.", + "rov_msg_trenta_still_rotting_minutes": "Still rotting. $1 minutes.", + "rov_msg_trenta_this_one_not_well_nothing": "This one is not well. Nothing will hurry it.", + "rov_msg_trenta_trenta_eat_only_what_grows": "The Trenta eat only what grows from root and leaf - no meat, fish, egg or honey.", + "rov_msg_trol_answers": "$1 answers.", + "rov_msg_trol_are_already_holding_log": "You are already holding a log!", + "rov_msg_trol_five_warbands_all_can_shout": "Five warbands is all it can shout for.", + "rov_msg_trol_has_already_had_one": "It has already had one.", + "rov_msg_trol_head_has_nothing_say": "The head has nothing to say.", + "rov_msg_trol_head_will_not_shout": "The head will not shout for you.", + "rov_msg_trol_must_true_form_lift_this": "You must be in True Form to lift this!", + "rov_msg_trol_no_room_lift": "No room to lift it!", + "rov_msg_trol_not_until_one_belonged_has": "Not until the one it belonged to has fallen.", + "rov_msg_trol_totem_wears_king_now": "The totem wears a king now.", + "rov_msg_ward_already_carry_s_power": "You already carry $1's power.", + "rov_msg_ward_s_power_yours": "$1's power is yours.", + "rov_msg_ward_switch_personal_progression_first": "Switch to personal progression first.", + "rov_msg_ward_ward_has_no_use_that": "The ward has no use for that.", + "rov_msg_warvulture_bird_does_not_know": "The bird does not know you.", + "rov_msg_warvulture_vulture_does_not_answer": "The vulture does not answer.", + "rov_msg_warvulture_vulture_settles_into_glide": "The vulture settles into a glide.", + "rov_msg_warvulture_vulture_spirals_down": "The vulture spirals down." +} diff --git a/JotunnModStub/Translations/Italian/messages.json b/JotunnModStub/Translations/Italian/messages.json new file mode 100644 index 0000000..b03faf1 --- /dev/null +++ b/JotunnModStub/Translations/Italian/messages.json @@ -0,0 +1,193 @@ +{ + "rov_msg_aswid_aura_disabled": "Aura vampirica: DISATTIVATA", + "rov_msg_aswid_aura_enabled": "Aura vampirica: ATTIVATA", + "rov_msg_aswid_dominate_cooldown_m_s": "Dominio in ricarica ($1m $2s)", + "rov_msg_aswid_dominated": "$1 dominato!", + "rov_msg_aswid_eclipse_cooldown_remaining_s": "L'Eclissi è in ricarica. Mancano: $1s", + "rov_msg_aswid_eclipse_descends": "Un'Eclissi discende...", + "rov_msg_aswid_eclipse_has_ended": "L'Eclissi è finita.", + "rov_msg_aswid_following": "$1 ti segue.", + "rov_msg_aswid_living_blood_curdles_living_throat": "Il sangue vivo si rapprende in una gola viva.", + "rov_msg_aswid_morning_sun_drives_bat_back": "Il sole del mattino ricaccia il pipistrello nel tuo corpo", + "rov_msg_aswid_morning_sun_has_vanquished_horrible": "Il sole del mattino ha sconfitto l'orribile notte", + "rov_msg_aswid_no_bone_grind": "Nessun osso da macinare.", + "rov_msg_aswid_no_raw_flesh_render": "Nessuna carne cruda da raffinare.", + "rov_msg_aswid_staying": "$1 resta qui.", + "rov_msg_aswid_sun_burns_can_only_take": "Il sole brucia. Puoi prendere la forma di pipistrello solo di notte.", + "rov_msg_aswid_tamed": "Addomesticato!", + "rov_msg_aswid_vae_victis": "Vae Victis", + "rov_msg_aswid_what_horrible_night_have_curse": "che notte orribile per avere una maledizione", + "rov_msg_build_limit_cooktable": "C'è già un altro tavolo del cuoco entro quaranta passi. Un cuoco per cortile.", + "rov_msg_build_limit_draugh_bodypile": "Questo terreno ne porta già $1. Trova un'altra contrada.", + "rov_msg_build_limit_dvergar_contractbank": "C'è già $1 banca dei contratti a una giornata di cammino. Un registro per valle.", + "rov_msg_build_limit_fenrir_packtrough": "Ce n'è già $1 a una giornata di cammino. Un branco ha bisogno di spazio.", + "rov_msg_build_limit_skeleton_bonepile": "Ce ne sono già $1 in ascolto qui vicino. Portalo più lontano.", + "rov_msg_build_limit_smithtable": "C'è già un altro tavolo del fabbro entro quaranta passi. Un fabbro per cortile.", + "rov_msg_build_limit_sverm_hive": "C'è già un alveare che occupa questo terreno.", + "rov_msg_build_limit_sverm_market": "Questo alveare ha già un mercato.", + "rov_msg_build_limit_trenta_grove": "Questa contrada ne ospita già $1. Piantalo altrove.", + "rov_msg_build_this_cave_will_hold_what": "Questa grotta terrà ciò che vi costruisci.", + "rov_msg_butler_already_at_work": "È già al lavoro.", + "rov_msg_butler_bones_are_not_ready_s": "Le ossa non sono pronte. $1s.", + "rov_msg_butler_bones_do_not_answer_blood": "Le ossa non rispondono al tuo sangue.", + "rov_msg_butler_nothing_answers": "Niente risponde.", + "rov_msg_butler_only_skadi_s_hearth_kept": "Solo il focolare di Skadi è tenuto dai morti.", + "rov_msg_butler_servant_rises": "Il servitore si alza.", + "rov_msg_claws_they_are_part_hands": "Fanno parte delle tue mani.", + "rov_msg_core_chose_path_aswid": "Hai scelto la via degli Aswid.", + "rov_msg_core_chose_path_draugh": "Hai scelto la via dei Draugh.", + "rov_msg_core_chose_path_dvergar": "Hai scelto la via dei Dvergar.", + "rov_msg_core_chose_path_fenrir": "Hai scelto la via dei Fenrir.", + "rov_msg_core_chose_path_furling": "Hai scelto la via dei Furling.", + "rov_msg_core_chose_path_skadi": "Hai scelto la via di Skadi.", + "rov_msg_core_chose_path_skeleton": "Hai scelto la via degli Scheletri.", + "rov_msg_core_chose_path_sverm": "Hai scelto la via degli Sverm.", + "rov_msg_core_chose_path_trenta": "Hai scelto la via dei Trenta.", + "rov_msg_core_chose_path_trol": "Hai scelto la via dei Trol.", + "rov_msg_core_chose_remain_human": "Hai scelto di restare Umano.", + "rov_msg_core_debug_override_cleared": "Override di debug rimosso.", + "rov_msg_core_nothing_reset_personal": "Niente da azzerare: non hai ancora reclamato reliquie ($1/$2).", + "rov_msg_core_nothing_reset_world": "Niente da azzerare: segui la progressione del mondo: $1 ($2/$3).", + "rov_msg_core_progression_reset": "Progressione personale azzerata a $1 ($2/$3). Reclama di nuovo le tue reliquie.", + "rov_msg_core_progression_state": "Stato di progressione: $1", + "rov_msg_core_world_progression_state": "Stato di progressione del mondo: $1", + "rov_msg_draugh_bone_will_not_wake_something": "L'osso non si sveglia. Qualcosa di più antico deve cadere prima.", + "rov_msg_draugh_draugr_consume_only_raw_flesh": "I Draugr consumano solo carne cruda, occhi, interiora o sangue.", + "rov_msg_draugh_has_already_had_one": "Ne ha già avuto uno.", + "rov_msg_draugh_northern_wind_blows": "Soffia il vento del nord", + "rov_msg_draugh_pile_broken_will_not_outlast": "Il mucchio è distrutto. $1 non gli sopravviveranno più di un minuto.", + "rov_msg_draugh_pile_stirs_will_keep_officers": "Il mucchio si agita. Ora terrà anche degli ufficiali.", + "rov_msg_draugh_steal_their_breath_death_denied": "Ruba il loro respiro! La morte è negata.", + "rov_msg_draugh_swarm_terror": "Sciame del terrore!", + "rov_msg_draugh_this_pile_keeps_no_officers": "Questo mucchio non tiene ancora ufficiali.", + "rov_msg_draugh_this_rotting_flesh_fatal_living": "Questa carne putrefatta è letale per i vivi.", + "rov_msg_draugh_wants_flesh_or_head_one": "Vuole carne, o la testa di uno dei suoi.", + "rov_msg_draugh_zombie_ritual_activated_borrowed_time": "Rituale zombie attivato! Il tuo tempo in prestito sta svanendo...", + "rov_msg_dvergar_contract_runic_do_not_sign": "Il contratto è in runico. Non lo firmi.", + "rov_msg_dvergar_do_not_know_what_goes": "Non sai cosa ci va dentro.", + "rov_msg_dvergar_drink": "$1 bevono $2.", + "rov_msg_dvergar_drink_barrel_runs_dry": "$1 bevono $2. Il barile si svuota.", + "rov_msg_dvergar_empty_so_are": "È vuoto, e lo sei anche tu.", + "rov_msg_dvergar_five_contracts_all_ledger_holds": "Cinque contratti è tutto ciò che il registro contiene.", + "rov_msg_dvergar_has_already_had_one": "Ne ha già avuto uno.", + "rov_msg_dvergar_ledger_not_written": "Il registro non è scritto per te.", + "rov_msg_dvergar_ledger_rewritten_better_names_sign": "Il registro è riscritto. Ora lo firmano nomi migliori.", + "rov_msg_dvergar_ledger_shut": "Il registro è chiuso.", + "rov_msg_dvergar_nobody_at_barrel": "Non c'è nessuno al barile.", + "rov_msg_dvergar_not_drop_went_down": "Non è andata giù nemmeno una goccia.", + "rov_msg_dvergar_not_enough_eitr": "Eitr insufficiente", + "rov_msg_dvergar_not_while_she_still_sits": "Non finché lei siede ancora sotto la nebbia.", + "rov_msg_dvergar_runic_overcharge_discharges": "Il sovraccarico runico si scarica", + "rov_msg_dvergar_runic_overcharge_next_blow_loaded": "Sovraccarico runico: il tuo prossimo colpo è carico", + "rov_msg_dvergar_runic_ping_echoes_answer": "Richiamo runico: rispondono $1 echi", + "rov_msg_dvergar_runic_ping_stone_silent": "Richiamo runico: la pietra tace", + "rov_msg_dvergar_signs": "$1 firma.", + "rov_msg_dvergar_there_still": "C'è ancora $1 dentro.", + "rov_msg_dvergar_whatever_does_nothing_anyone": "Qualunque cosa ci sia dentro, non fa niente a nessuno.", + "rov_msg_fenrir_are_cultist": "Sei un Cultista!", + "rov_msg_fenrir_are_fenring": "Sei un Fenring!", + "rov_msg_fenrir_are_ulv": "Sei un Ulv!", + "rov_msg_fenrir_are_wolf": "Sei un Lupo!", + "rov_msg_fenrir_beast_rests_can_only_transform": "La bestia riposa. Puoi trasformarti solo di notte.", + "rov_msg_fenrir_beast_tired": "La bestia è stanca", + "rov_msg_fenrir_blood_will_not_take_something": "Il sangue non attecchisce. Qualcosa nelle pianure deve cadere prima.", + "rov_msg_fenrir_form_cooldown": "La forma $1 è in ricarica ($2:$3).", + "rov_msg_fenrir_formname_cultist": "Cultista", + "rov_msg_fenrir_formname_fenrir": "Fenrir", + "rov_msg_fenrir_has_already_had_one": "Ne ha già avuto uno.", + "rov_msg_fenrir_only_breath_comes_out_fire": "Esce solo fiato. Il fuoco vuole eitr.", + "rov_msg_fenrir_ready": "$1 è pronto!", + "rov_msg_fenrir_returned_human_form": "Sei tornato in forma umana.", + "rov_msg_fenrir_trough_broken_will_not_outlast": "La mangiatoia è distrutta. $1 non le sopravviveranno a lungo.", + "rov_msg_fenrir_trough_takes_line_runs_deeper": "La mangiatoia lo accetta. Ora la discendenza va più a fondo.", + "rov_msg_fenrir_wants_meat_any_meat": "Vuole carne. Qualsiasi carne.", + "rov_msg_fenrir_wants_what_yagluth_left_behind": "Vuole ciò che Yagluth ha lasciato.", + "rov_msg_skadi_are_drake": "Sei un Drake!", + "rov_msg_skadi_are_fader": "Sei Fader!", + "rov_msg_skadi_are_moder": "Sei Moder!", + "rov_msg_skadi_dragon_form_cooldown": "La forma di drago è in ricarica ($1:$2).", + "rov_msg_skadi_dragon_form_fades": "La tua forma di drago svanisce.", + "rov_msg_skadi_dumped_dragon_drake_fader_debug": "Info di debug Dragon/Drake/Fader scritte nella console!", + "rov_msg_skadi_needs_stonecutter_cut_at": "Ha bisogno di uno scalpellino per essere tagliato.", + "rov_msg_skadi_not_enough_stamina": "Stamina insufficiente", + "rov_msg_skadi_returned_human_form": "Sei tornato in forma umana.", + "rov_msg_skadi_stone_does_not_answer": "La pietra non ti risponde.", + "rov_msg_skadi_stonecutter_gone_what_cut_will": "Lo scalpellino non c'è più. Ciò che ha tagliato non gli sopravviverà a lungo.", + "rov_msg_skadi_tear_cold_nothing_wakes_stone": "La lacrima è fredda. Niente si sveglia nella pietra finché la regina della montagna non è caduta.", + "rov_msg_skadi_that_stonecutter_already_holds_will": "Quello scalpellino ne tiene già $1. Non ne terrà altri.", + "rov_msg_skadi_there_are_already_these_within": "Ce ne sono già $1 a una giornata di cammino. La pietra è esaurita.", + "rov_msg_skeleton_has_already_had_one": "Ne ha già avuto uno.", + "rov_msg_skeleton_have_been_resurrected_by_dark": "Sei stato resuscitato dalla magia oscura!", + "rov_msg_skeleton_mortal_food_disgusts": "Il cibo dei mortali ti disgusta.", + "rov_msg_skeleton_nothing_standing_yet_wants_bone": "Non c'è ancora niente in piedi. Vuole ossa.", + "rov_msg_skeleton_pile_broken_fall_where_they": "Il mucchio è distrutto. $1 cadono dove si trovano.", + "rov_msg_skeleton_pile_deepens_rotten_will_stand": "Il mucchio si fa più profondo. Anche i rancidi si alzeranno qui.", + "rov_msg_skeleton_return_pile": "$1 tornano al mucchio.", + "rov_msg_skeleton_rise_follow": "$1 si alzano e ti seguono.", + "rov_msg_skeleton_skeletons_do_not_need_eat": "Gli scheletri non hanno bisogno di mangiare.", + "rov_msg_skeleton_skull_will_not_wake_something": "Il teschio non si sveglia. Qualcosa di più antico deve cadere prima.", + "rov_msg_skeleton_these_bones_answer_only_their": "Queste ossa rispondono solo ai loro simili.", + "rov_msg_skeleton_this_pile_cannot_hold_rotten": "Questo mucchio non può ancora tenere i rancidi.", + "rov_msg_sverm_alchemical_blood_not_food": "Il sangue alchemico non è cibo.", + "rov_msg_sverm_carapace_has_no_room_that": "Il tuo carapace non ha spazio per quello.", + "rov_msg_sverm_colony_will_not_wake_until": "La colonia non si sveglierà finché l'Antico non sarà caduto.", + "rov_msg_sverm_hive_does_not_know": "L'alveare non ti conosce.", + "rov_msg_sverm_hive_full_give_time_digest": "L'alveare è pieno. Dagli tempo di digerire.", + "rov_msg_sverm_market_has_stand_within_metres": "Un mercato deve stare entro $1 metri da un alveare.", + "rov_msg_sverm_no_hive_within_metres_this": "Nessun alveare entro $1 metri. Questo bancone è morto.", + "rov_msg_sverm_not_enough_biomass_bank": "Non c'è abbastanza biomassa nella riserva.", + "rov_msg_sverm_not_hurt": "$1 non è ferito.", + "rov_msg_sverm_nothing_here_will_eat_food": "Qui non c'è niente che mangerebbe. Cibo, legno e resina: miele e pappa reale sono medicine.", + "rov_msg_sverm_only_sverm_can_raise_hive": "Solo gli Sverm possono far sorgere un alveare.", + "rov_msg_sverm_only_sverm_can_raise_market": "Solo gli Sverm possono far sorgere un mercato.", + "rov_msg_sverm_ravager_strain_takes_hold": "Il Ceppo Devastatore attecchisce.", + "rov_msg_sverm_shell_recedes": "Il guscio si ritrae.", + "rov_msg_sverm_strain_has_not_taken_yet": "Il ceppo non ha ancora attecchito.", + "rov_msg_sverm_strain_spent": "Il ceppo è esaurito.", + "rov_msg_sverm_they_are_part_hands": "Fanno parte delle tue mani.", + "rov_msg_sverm_x_biomass_digesting": "$1 x$2 -> +$3 biomassa, in digestione", + "rov_msg_thrall_answer_call": "$1 rispondono alla chiamata.", + "rov_msg_thrall_follows": "$1 ti segue.", + "rov_msg_thrall_no_more_may_walk_with": "Nessun altro può camminare con te.", + "rov_msg_thrall_only_may_walk_with": "Solo $1 possono camminare con te.", + "rov_msg_thrall_refusal_default": "Non ti risponde.", + "rov_msg_thrall_refusal_draugh": "I morti non prendono ordini dai vivi.", + "rov_msg_thrall_refusal_dvergar": "Il tuo nome non è sul contratto.", + "rov_msg_thrall_refusal_skeleton": "Queste ossa rispondono solo ai loro simili.", + "rov_msg_thrall_refusal_sverm": "Non sente l'odore della tua colonia su di te.", + "rov_msg_thrall_refusal_trol": "Non li hai pagati tu.", + "rov_msg_thrall_returns": "$1 torna indietro.", + "rov_msg_thrall_rises_with": "$1 si alza con $2.", + "rov_msg_thrall_stands_down_with": "$1 si ritira con $2.", + "rov_msg_trenta_are_muspell_ash_ember_given": "Sei Muspell, cenere e brace fatte forma.", + "rov_msg_trenta_elder_has_not_fallen_yet": "L'Antico non è ancora caduto.", + "rov_msg_trenta_grows": "Cresce.", + "rov_msg_trenta_no_raw_flesh_rot": "Nessuna carne cruda da far marcire.", + "rov_msg_trenta_nothing_feed_wants_fertilizer": "Niente con cui nutrirlo. Vuole fertilizzante.", + "rov_msg_trenta_nothing_there_feed": "Non c'è niente da nutrire.", + "rov_msg_trenta_return_rooted_form": "Torni alla tua forma radicata.", + "rov_msg_trenta_ripe_already": "È già maturo.", + "rov_msg_trenta_root_will_not_take_hold": "La radice non attecchisce per te.", + "rov_msg_trenta_still_growing_minutes": "Sta ancora crescendo. $1 minuti.", + "rov_msg_trenta_still_rotting_minutes": "Sta ancora marcendo. $1 minuti.", + "rov_msg_trenta_this_one_not_well_nothing": "Questo non sta bene. Niente lo farà affrettare.", + "rov_msg_trenta_trenta_eat_only_what_grows": "I Trenta mangiano solo ciò che nasce da radice e foglia: niente carne, pesce, uova o miele.", + "rov_msg_trol_answers": "$1 risponde.", + "rov_msg_trol_are_already_holding_log": "Stai già tenendo un tronco!", + "rov_msg_trol_five_warbands_all_can_shout": "Cinque bande da guerra è tutto ciò che può chiamare.", + "rov_msg_trol_has_already_had_one": "Ne ha già avuto uno.", + "rov_msg_trol_head_has_nothing_say": "La testa non ha niente da dire.", + "rov_msg_trol_head_will_not_shout": "La testa non urlerà per te.", + "rov_msg_trol_must_true_form_lift_this": "Devi essere nella Vera forma per sollevarlo!", + "rov_msg_trol_no_room_lift": "Non c'è spazio per sollevarlo!", + "rov_msg_trol_not_until_one_belonged_has": "Non finché colui a cui apparteneva non sarà caduto.", + "rov_msg_trol_totem_wears_king_now": "Ora il totem porta un re.", + "rov_msg_ward_already_carry_s_power": "Porti già il potere di $1.", + "rov_msg_ward_s_power_yours": "Il potere di $1 è tuo.", + "rov_msg_ward_switch_personal_progression_first": "Passa prima alla progressione personale.", + "rov_msg_ward_ward_has_no_use_that": "Al sigillo non serve.", + "rov_msg_warvulture_bird_does_not_know": "L'uccello non ti conosce.", + "rov_msg_warvulture_vulture_does_not_answer": "L'avvoltoio non risponde.", + "rov_msg_warvulture_vulture_settles_into_glide": "L'avvoltoio si mette a planare.", + "rov_msg_warvulture_vulture_spirals_down": "L'avvoltoio scende a spirale." +} diff --git a/JotunnModStub/Trenta/ComposterBehaviour.cs b/JotunnModStub/Trenta/ComposterBehaviour.cs index 4dd7524..82c9871 100644 --- a/JotunnModStub/Trenta/ComposterBehaviour.cs +++ b/JotunnModStub/Trenta/ComposterBehaviour.cs @@ -98,7 +98,7 @@ namespace RacesOfValheim if (state == State.Composting) { - user.Message(MessageHud.MessageType.Center, $"Still rotting. {MinutesLeft()} minutes."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_still_rotting_minutes", MinutesLeft())); return false; } @@ -108,7 +108,7 @@ namespace RacesOfValheim if (item == null) item = FindFlesh(inventory); if (item == null) { - user.Message(MessageHud.MessageType.Center, "No raw flesh to rot."); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_no_raw_flesh_rot")); return false; } diff --git a/JotunnModStub/Trenta/GroveBehaviour.cs b/JotunnModStub/Trenta/GroveBehaviour.cs index 0d0fde3..64f3989 100644 --- a/JotunnModStub/Trenta/GroveBehaviour.cs +++ b/JotunnModStub/Trenta/GroveBehaviour.cs @@ -274,9 +274,7 @@ namespace RacesOfValheim if (item == null) item = FindFertilizer(inventory); if (item == null) { - user.Message(MessageHud.MessageType.Center, IsGrown() - ? "Nothing to feed it. It wants Fertilizer." - : $"Still growing. {MinutesLeft()} minutes."); + user.Message(MessageHud.MessageType.Center, (IsGrown() ? ModText.Get("rov_msg_trenta_nothing_feed_wants_fertilizer") : ModText.Get("rov_msg_trenta_still_growing_minutes", MinutesLeft()))); return false; } diff --git a/JotunnModStub/Trenta/TrentaComposter.cs b/JotunnModStub/Trenta/TrentaComposter.cs index 914ec5e..64bcf5d 100644 --- a/JotunnModStub/Trenta/TrentaComposter.cs +++ b/JotunnModStub/Trenta/TrentaComposter.cs @@ -387,19 +387,19 @@ namespace RacesOfValheim { case GrowOutcome.Grown: if (inventory != null) inventory.RemoveItem(item, 1); - player.Message(MessageHud.MessageType.Center, "It grows."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_grows")); break; case GrowOutcome.AlreadyRipe: - player.Message(MessageHud.MessageType.Center, "It is ripe already."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_ripe_already")); break; case GrowOutcome.Unhealthy: - player.Message(MessageHud.MessageType.Center, "This one is not well. Nothing will hurry it."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_this_one_not_well_nothing")); break; case GrowOutcome.NoTarget: - player.Message(MessageHud.MessageType.Center, "Nothing there to feed."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_nothing_there_feed")); break; default: diff --git a/JotunnModStub/Trenta/TrentaElderRoot.cs b/JotunnModStub/Trenta/TrentaElderRoot.cs index d36d67c..ba21936 100644 --- a/JotunnModStub/Trenta/TrentaElderRoot.cs +++ b/JotunnModStub/Trenta/TrentaElderRoot.cs @@ -291,13 +291,13 @@ namespace RacesOfValheim if (!TrentaRace.IsTrenta()) { - __instance.Message(MessageHud.MessageType.Center, "The root will not take hold for you."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_root_will_not_take_hold")); return false; } if (BossProgressionManager.GetCurrentProgressionState() < TrentaConfig.ElderRootUnlockState) { - __instance.Message(MessageHud.MessageType.Center, "The Elder has not fallen yet."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_elder_has_not_fallen_yet")); return false; } diff --git a/JotunnModStub/Trenta/TrentaFoodPatches.cs b/JotunnModStub/Trenta/TrentaFoodPatches.cs index f083369..bc17d19 100644 --- a/JotunnModStub/Trenta/TrentaFoodPatches.cs +++ b/JotunnModStub/Trenta/TrentaFoodPatches.cs @@ -81,7 +81,7 @@ namespace RacesOfValheim if (TrentaConfig.VeganFoodPrefabNames.Contains(prefabName)) return true; - player.Message(MessageHud.MessageType.Center, "The Trenta eat only what grows from root and leaf - no meat, fish, egg or honey."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_trenta_eat_only_what_grows")); return false; // Block consumption } } diff --git a/JotunnModStub/Trenta/TrentaHeartwoodGrove.cs b/JotunnModStub/Trenta/TrentaHeartwoodGrove.cs index a8ca08c..ce9f741 100644 --- a/JotunnModStub/Trenta/TrentaHeartwoodGrove.cs +++ b/JotunnModStub/Trenta/TrentaHeartwoodGrove.cs @@ -39,7 +39,7 @@ namespace RacesOfValheim PieceDensityLimit.Register(TrentaConfig.GrovePieceName, PieceDensityLimit.RadiusForArea(TrentaConfig.GroveDensityAreaKm2), TrentaConfig.GroveMaxInRange, - "This country already answers to {0} of these. Plant it somewhere else."); + "rov_msg_build_limit_trenta_grove"); } // ---------------------------------------------------------------- the seed diff --git a/JotunnModStub/Trenta/TrentaMuspell.cs b/JotunnModStub/Trenta/TrentaMuspell.cs index 6f7fbf6..2864acf 100644 --- a/JotunnModStub/Trenta/TrentaMuspell.cs +++ b/JotunnModStub/Trenta/TrentaMuspell.cs @@ -185,7 +185,7 @@ namespace RacesOfValheim IsTransformed = true; - player.Message(MessageHud.MessageType.Center, "You are Muspell, ash and ember given shape."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_are_muspell_ash_ember_given")); } private static void ExecuteReversion(Player player) @@ -208,7 +208,7 @@ namespace RacesOfValheim IsTransformed = false; - player.Message(MessageHud.MessageType.Center, "You return to your rooted form."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trenta_return_rooted_form")); } } diff --git a/JotunnModStub/Trol/TrolLogWeapon.cs b/JotunnModStub/Trol/TrolLogWeapon.cs index fa42538..f315494 100644 --- a/JotunnModStub/Trol/TrolLogWeapon.cs +++ b/JotunnModStub/Trol/TrolLogWeapon.cs @@ -19,7 +19,7 @@ namespace RacesOfValheim if (!seman.HaveStatusEffect("SE_TrolTrueForm".GetStableHashCode())) { - user.Message(MessageHud.MessageType.Center, "You must be in True Form to lift this!"); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_must_true_form_lift_this")); return; } @@ -47,7 +47,7 @@ namespace RacesOfValheim ItemDrop.ItemData rightItem = HarmonyLib.Traverse.Create(user).Field("m_rightItem").Value; if (rightItem != null && rightItem.m_dropPrefab != null && rightItem.m_dropPrefab.name.StartsWith("TrolWeapon_")) { - user.Message(MessageHud.MessageType.Center, "You are already holding a log!"); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_are_already_holding_log")); return; } @@ -80,7 +80,7 @@ namespace RacesOfValheim Vector2i gridPos = HarmonyLib.Traverse.Create(user.GetInventory()).Method("FindEmptySlot", false).GetValue(); if (gridPos.x == -1) { - user.Message(MessageHud.MessageType.Center, "No room to lift it!"); + user.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_no_room_lift")); return; } newItem.m_gridPos = gridPos; diff --git a/JotunnModStub/Trol/TrolTotem.cs b/JotunnModStub/Trol/TrolTotem.cs index 512437b..9187631 100644 --- a/JotunnModStub/Trol/TrolTotem.cs +++ b/JotunnModStub/Trol/TrolTotem.cs @@ -190,7 +190,7 @@ namespace RacesOfValheim thrall.m_maxFollowers = MaxFollowers; thrall.m_witherSeconds = WitherSeconds; thrall.m_homeCheckRange = HomeCheckRange; - thrall.m_refusalMessage = "They were not paid by you."; + thrall.m_refusalMessage = "$rov_msg_thrall_refusal_trol"; // The sentry's regeneration, reused whole: untouched for ten seconds, then two percent a // second. "Rigenerarsi come i nostri scheletri" is the healing, not a respawn - a dead @@ -374,7 +374,7 @@ namespace RacesOfValheim if (Utils.GetPrefabName(__0.gameObject) != TrolTotem.PieceName) return true; if (TrolRace.IsTrol()) return true; - __instance.Message(MessageHud.MessageType.Center, "The head will not shout for you."); + __instance.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_head_will_not_shout")); return false; } } diff --git a/JotunnModStub/Trol/TrolTotemBehaviour.cs b/JotunnModStub/Trol/TrolTotemBehaviour.cs index 4543646..b567f9d 100644 --- a/JotunnModStub/Trol/TrolTotemBehaviour.cs +++ b/JotunnModStub/Trol/TrolTotemBehaviour.cs @@ -70,7 +70,7 @@ namespace RacesOfValheim if (!TrolRace.IsTrol()) { - player.Message(MessageHud.MessageType.Center, "The head will not shout for you."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_head_will_not_shout")); // With an item in hand, false makes Humanoid.UseItem cover this message with its // generic "$msg_cantuseon"; true tells it the use was handled here. return item != null; @@ -97,19 +97,19 @@ namespace RacesOfValheim { if (IsUpgraded()) { - player.Message(MessageHud.MessageType.Center, "It has already had one."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_has_already_had_one")); return true; } if (BossProgressionManager.GetCurrentProgressionState() < TrolTotem.UpgradeProgressionState) { - player.Message(MessageHud.MessageType.Center, "Not until the one it belonged to has fallen."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_not_until_one_belonged_has")); return true; } player.GetInventory().RemoveItem(item, 1); m_nview.InvokeRPC("RoV_TrolUpgrade"); - player.Message(MessageHud.MessageType.Center, "The totem wears a king now."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_totem_wears_king_now")); return true; } @@ -123,7 +123,7 @@ namespace RacesOfValheim Trader trader = GetComponent(); if (trader == null || StoreGui.instance == null) { - player.Message(MessageHud.MessageType.Center, "The head has nothing to say."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_head_has_nothing_say")); return false; } @@ -148,7 +148,7 @@ namespace RacesOfValheim if (CountGroups() >= TrolTotem.MaxTroops) { - player.Message(MessageHud.MessageType.Center, "Five warbands is all it can shout for."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_five_warbands_all_can_shout")); return; } @@ -163,7 +163,7 @@ namespace RacesOfValheim TakeCoins(inventory, troop.Price); m_nview.InvokeRPC("RoV_TrolHire", troop.Id); - player.Message(MessageHud.MessageType.Center, $"{troop.Display} answers."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_trol_answers", troop.Display)); } private const string CoinsPrefab = "Coins"; diff --git a/JotunnModStub/WarVulture/WarVultureMount.cs b/JotunnModStub/WarVulture/WarVultureMount.cs index 1d8646a..3667b5d 100644 --- a/JotunnModStub/WarVulture/WarVultureMount.cs +++ b/JotunnModStub/WarVulture/WarVultureMount.cs @@ -113,13 +113,13 @@ namespace RacesOfValheim if (!WarVultureConfig.RaceAllowed(race)) { - rider.Message(MessageHud.MessageType.Center, "The bird does not know you."); + rider.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_warvulture_bird_does_not_know")); return; } if (!WarVultureVisual.Ready) { - rider.Message(MessageHud.MessageType.Center, "The vulture does not answer."); + rider.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_warvulture_vulture_does_not_answer")); Jotunn.Logger.LogWarning($"[{Label}] Call refused: the stripped model template was never built, " + "so there is no bird to show. The reason is logged at startup - and " + "refusing is deliberate, because the alternative is putting an unstripped " + @@ -245,7 +245,7 @@ namespace RacesOfValheim { landing = true; landingStartedAt = Time.time; - player.Message(MessageHud.MessageType.Center, "The vulture spirals down."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_warvulture_vulture_spirals_down")); } private void UpdateLanding() @@ -304,7 +304,7 @@ namespace RacesOfValheim wind = Mathf.Max(0f, wind - dt); if (wind <= 0f) { - player.Message(MessageHud.MessageType.Center, "The vulture settles into a glide."); + player.Message(MessageHud.MessageType.Center, ModText.Get("rov_msg_warvulture_vulture_settles_into_glide")); } } else if (wind < WarVultureConfig.SprintSeconds.Value)