Skip to content

Commit

Permalink
新版本翻译补充
Browse files Browse the repository at this point in the history
  • Loading branch information
MeowZWR committed Jun 2, 2024
1 parent c873848 commit e0cf40e
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 33 deletions.
2 changes: 1 addition & 1 deletion Glamourer/Gui/MainWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ private string GetLabel()
(true, true) => "Glamourer(匿名模式)###GlamourerMainWindow",
(true, false) => "Glamourer###GlamourerMainWindow",
(false, false) => $"Glamourer v{Glamourer.Version}###GlamourerMainWindow",
(false, true) => $"Glamourer v{Glamourer.Version} (Incognito Mode)###GlamourerMainWindow",
(false, true) => $"Glamourer v{Glamourer.Version}(匿名模式)###GlamourerMainWindow",
};

private void DrawProblemWindow(string text)
Expand Down
16 changes: 8 additions & 8 deletions Glamourer/Gui/Tabs/DesignTab/RenameField.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Glamourer.Gui.Tabs.DesignTab;
namespace Glamourer.Gui.Tabs.DesignTab;

public enum RenameField
{
Expand All @@ -14,13 +14,13 @@ public static class RenameFieldExtensions
public static (string Name, string Desc) GetData(this RenameField value)
=> value switch
{
RenameField.None => ("None", "Show no rename fields in the context menu for designs."),
RenameField.RenameSearchPath => ("Search Path", "Show only the search path / move field in the context menu for designs."),
RenameField.RenameData => ("Design Name", "Show only the design name field in the context menu for designs."),
RenameField.BothSearchPathPrio => ("Both (Focus Search Path)",
"Show both rename fields in the context menu for designs, but put the keyboard cursor on the search path field."),
RenameField.BothDataPrio => ("Both (Focus Design Name)",
"Show both rename fields in the context menu for designs, but put the keyboard cursor on the design name field"),
RenameField.None => ("", "在设计的上下文菜单中不显示重命名字段。"),
RenameField.RenameSearchPath => ("搜索路径", "在设计的上下文菜单中仅显示搜索路径 / 移动字段。"),
RenameField.RenameData => ("设计名称", "在设计的上下文菜单中仅显示设计名称字段。"),
RenameField.BothSearchPathPrio => ("两者(焦点在搜索路径)",
"在设计的上下文菜单中显示两个重命名字段,但将键盘光标放在搜索路径字段上。"),
RenameField.BothDataPrio => ("两者(焦点在设计名称)",
"在设计的上下文菜单中显示两个重命名字段,但将键盘光标放在设计名称字段上。"),
_ => (string.Empty, string.Empty),
};
}
22 changes: 11 additions & 11 deletions Glamourer/Gui/Tabs/SettingsTab/CodeDrawer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ namespace Glamourer.Gui.Tabs.SettingsTab;
public class CodeDrawer(Configuration config, CodeService codeService, FunModule funModule) : IUiService
{
private static ReadOnlySpan<byte> Tooltip
=> "Cheat Codes are not actually for cheating in the game, but for 'cheating' in Glamourer. "u8
+ "They allow for some fun easter-egg modes that usually manipulate the appearance of all players you see (including yourself) in some way."u8;
=> "作弊代码实际上不是为了在游戏中作弊,而是为了在 Glamourer 中“作弊”。 "u8
+ "它们允许插件执行一些有趣的彩蛋模式,这些模式通常会以某种方式改变您看到的所有玩家(包括您自己)的外观。"u8;

private static ReadOnlySpan<byte> DragDropLabel
=> "##CheatDrag"u8;
Expand All @@ -26,7 +26,7 @@ private static ReadOnlySpan<byte> DragDropLabel

public void Draw()
{
var show = ImGui.CollapsingHeader("Cheat Codes");
var show = ImGui.CollapsingHeader("作弊代码");
DrawTooltip();

if (!show)
Expand All @@ -43,7 +43,7 @@ private void DrawCodeInput()
var color = codeService.CheckCode(_currentCode).Item2 is not 0 ? ColorId.ActorAvailable : ColorId.ActorUnavailable;
using var border = ImRaii.PushFrameBorder(ImUtf8.GlobalScale, color.Value(), _currentCode.Length > 0);
ImGui.SetNextItemWidth(500 * ImUtf8.GlobalScale + ImUtf8.ItemSpacing.X);
if (ImUtf8.InputText("##Code"u8, ref _currentCode, "Enter Cheat Code..."u8, ImGuiInputTextFlags.EnterReturnsTrue))
if (ImUtf8.InputText("##Code"u8, ref _currentCode, "输入作弊代码..."u8, ImGuiInputTextFlags.EnterReturnsTrue))
{
codeService.AddCode(_currentCode);
_currentCode = string.Empty;
Expand All @@ -60,14 +60,14 @@ private void DrawCopyButtons()
if (ImUtf8.Button("Who am I?!?"u8, buttonSize))
funModule.WhoAmI();
ImUtf8.HoverTooltip(
"Copy your characters actual current appearance including cheat codes or holiday events to the clipboard as a design."u8);
"将你的角色当前的实际外观(包括作弊代码或节日活动)复制到剪贴板作为一个设计。"u8);

ImGui.SameLine();

if (ImUtf8.Button("Who is that!?!"u8, buttonSize))
funModule.WhoIsThat();
ImUtf8.HoverTooltip(
"Copy your targets actual current appearance including cheat codes or holiday events to the clipboard as a design."u8);
"将你的目标当前的实际外观(包括作弊代码或节日活动)复制到剪贴板作为一个设计。"u8);
}

private CodeService.CodeFlag DrawCodes()
Expand All @@ -85,7 +85,7 @@ private CodeService.CodeFlag DrawCodes()
var data = CodeService.GetData(flag);

if (ImUtf8.IconButton(FontAwesomeIcon.Trash,
$"Delete this cheat code.{(canDelete ? string.Empty : $"\nHold {config.DeleteDesignModifier} while clicking to delete.")}",
$"删除此作弊代码。{(canDelete ? string.Empty : $"\n按住 {config.DeleteDesignModifier} 键并单击以删除。")}",
!canDelete))
{
action!(false);
Expand Down Expand Up @@ -125,7 +125,7 @@ private void DrawSource(int idx, string code)

if (!DragDropSource.SetPayload(DragDropLabel))
_dragCodeIdx = idx;
ImUtf8.Text($"Dragging {code}...");
ImUtf8.Text($"拖拽 {code}...");
}

private void DrawTarget(int idx)
Expand All @@ -144,7 +144,7 @@ private void DrawCodeHints(CodeService.CodeFlag knownFlags)
if (knownFlags.HasFlag(CodeService.AllHintCodes))
return;

if (ImUtf8.Button(_showCodeHints ? "Hide Hints"u8 : "Show Hints"u8))
if (ImUtf8.Button(_showCodeHints ? "隐藏提示"u8 : "显示提示"u8))
_showCodeHints = !_showCodeHints;

if (!_showCodeHints)
Expand All @@ -166,8 +166,8 @@ private void DrawCodeHints(CodeService.CodeFlag knownFlags)
using var indent = ImRaii.PushIndent(2);
using (ImUtf8.Group())
{
ImUtf8.Text("Capitalized letters: "u8);
ImUtf8.Text("Punctuation: "u8);
ImUtf8.Text("大写字母:"u8);
ImUtf8.Text("标点符号:"u8);
}

ImUtf8.SameLineInner();
Expand Down
2 changes: 1 addition & 1 deletion Glamourer/Gui/Tabs/SettingsTab/CollectionOverrideDrawer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ private void DrawNewOverride(Vector2 buttonSize)
{
var (currentId, currentName) = penumbra.CurrentCollection;
ImGui.TableNextColumn();
if (ImGuiUtil.DrawDisabledButton(FontAwesomeIcon.PersonCirclePlus.ToIconString(), buttonSize, "Add override for current player.",
if (ImGuiUtil.DrawDisabledButton(FontAwesomeIcon.PersonCirclePlus.ToIconString(), buttonSize, "添加对当前玩家的覆盖。",
!objects.Player.Valid && currentId != Guid.Empty, true))
collectionOverrides.AddOverride([objects.PlayerData.Identifier], currentId, currentName);

Expand Down
16 changes: 8 additions & 8 deletions Glamourer/Gui/Tabs/SettingsTab/SettingsTab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ private void DrawRenameSettings()
"选择在打开设计选择器中设计右键上下文菜单时可见的两个重命名输入字段中的哪一个。";
ImGuiComponents.HelpMarker(tt);
ImGui.SameLine();
ImGui.TextUnformatted("设计中上下文菜单的重命名字段");
ImGui.TextUnformatted("设计上下文菜单中的重命名字段");
ImGuiUtil.HoverTooltip(tt);
}

Expand All @@ -393,21 +393,21 @@ private void DrawHeightUnitSettings()
}

ImGui.SameLine();
const string tt = "Select how to display the height of characters in real-world units, if at all.";
const string tt = "选择如何以真实世界单位显示角色的身高。";
ImGuiComponents.HelpMarker(tt);
ImGui.SameLine();
ImGui.TextUnformatted("Character Height Display Type");
ImGui.TextUnformatted("人物身高显示单位");
ImGuiUtil.HoverTooltip(tt);
}

private string HeightDisplayTypeName(HeightDisplayType type)
=> type switch
{
HeightDisplayType.None => "Do Not Display",
HeightDisplayType.Centimetre => "Centimetres (000.0 cm)",
HeightDisplayType.Metre => "Metres (0.00 m)",
HeightDisplayType.Wrong => "Inches (00.0 in)",
HeightDisplayType.WrongFoot => "Feet (0'00'')",
HeightDisplayType.None => "不显示",
HeightDisplayType.Centimetre => "厘米 (000.0 cm)",
HeightDisplayType.Metre => " (0.00 m)",
HeightDisplayType.Wrong => "英寸 (00.0 in)",
HeightDisplayType.WrongFoot => "英尺 (0'00'')",
_ => string.Empty,
};
}
2 changes: 1 addition & 1 deletion Glamourer/Interop/ScalingService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ private float CalculateHeightDetour(Character* character)

/// <summary> We do not change the Customize gender because the functions use the GetGender() vfunc, which uses the game objects gender value. </summary>
private static (byte Race, byte Clan, byte Gender) GetScaleRelevantCustomize(Character* character)
=> (character->DrawData.CustomizeData.Race, character->DrawData.CustomizeData.Clan, character->GameObject.Gender);//国际服6.58hotfix后,Clan改Tribe,Gender改Sex
=> (character->DrawData.CustomizeData.Race, character->DrawData.CustomizeData.Tribe, character->GameObject.Sex);//国际服6.58hotfix后,Clan改Tribe,Gender改Sex

private static (byte Gender, byte BodyType, byte Clan, byte Height) GetHeightRelevantCustomize(Character* character)
=> (character->DrawData.CustomizeData.Sex, character->DrawData.CustomizeData.BodyType,
Expand Down
2 changes: 1 addition & 1 deletion Penumbra.Api
Submodule Penumbra.Api updated 61 files
+62 −0 Api/Collection.cs
+28 −0 Api/Editing.cs
+52 −0 Api/GameState.cs
+41 −0 Api/IPenumbraApi.cs
+3 −5 Api/IPenumbraApiBase.cs
+13 −0 Api/Meta.cs
+62 −0 Api/ModSettings.cs
+65 −0 Api/Mods.cs
+26 −0 Api/PluginState.cs
+23 −0 Api/Redraw.cs
+64 −0 Api/Resolve.cs
+73 −0 Api/ResourceTree.cs
+64 −0 Api/Temporary.cs
+59 −0 Api/Ui.cs
+8 −18 Delegates.cs
+6 −0 Enums/GroupType.cs
+12 −12 Helpers/ActionSubscriber.cs
+152 −0 Helpers/ConvertingDict.cs
+53 −0 Helpers/DtoClasses.cs
+142 −140 Helpers/EventProvider.cs
+1 −1 Helpers/EventSubscriber.cs
+31 −0 Helpers/FuncProvider.cs
+40 −91 Helpers/FuncSubscriber.cs
+0 −632 IPenumbraApi.cs
+0 −133 Ipc/Collection.cs
+0 −44 Ipc/Configuration.cs
+0 −34 Ipc/Editing.cs
+0 −81 Ipc/GameState.cs
+0 −43 Ipc/Meta.cs
+0 −135 Ipc/ModSettings.cs
+0 −134 Ipc/Mods.cs
+0 −92 Ipc/PluginState.cs
+0 −69 Ipc/Redraw.cs
+0 −129 Ipc/Resolve.cs
+0 −112 Ipc/ResourceTree.cs
+0 −128 Ipc/Temporary.cs
+0 −111 Ipc/Ui.cs
+137 −0 IpcSubscribers/Collection.cs
+38 −0 IpcSubscribers/Editing.cs
+100 −0 IpcSubscribers/GameState.cs
+99 −0 IpcSubscribers/Legacy/Collection.cs
+43 −0 IpcSubscribers/Legacy/GameState.cs
+24 −0 IpcSubscribers/Legacy/Meta.cs
+92 −0 IpcSubscribers/Legacy/ModSettings.cs
+70 −0 IpcSubscribers/Legacy/Mods.cs
+15 −0 IpcSubscribers/Legacy/PluginState.cs
+44 −0 IpcSubscribers/Legacy/Redraw.cs
+24 −0 IpcSubscribers/Legacy/Resolve.cs
+83 −0 IpcSubscribers/Legacy/ResourceTree.cs
+88 −0 IpcSubscribers/Legacy/Temporary.cs
+16 −0 IpcSubscribers/Legacy/Ui.cs
+37 −0 IpcSubscribers/Meta.cs
+165 −0 IpcSubscribers/ModSettings.cs
+186 −0 IpcSubscribers/Mods.cs
+128 −0 IpcSubscribers/PluginState.cs
+53 −0 IpcSubscribers/Redraw.cs
+133 −0 IpcSubscribers/Resolve.cs
+116 −0 IpcSubscribers/ResourceTree.cs
+121 −0 IpcSubscribers/Temporary.cs
+130 −0 IpcSubscribers/Ui.cs
+14 −5 Penumbra.Api.csproj
2 changes: 1 addition & 1 deletion Penumbra.String

0 comments on commit e0cf40e

Please sign in to comment.