refactor: Update Unity to 2022.3.62

This commit is contained in:
2025-06-21 01:22:02 +08:00
parent d71bf7d4a5
commit 283783954f
112 changed files with 778 additions and 907 deletions

View File

@@ -29,7 +29,7 @@ namespace Cryville.Crtr.Config.UI {
int _targetDim;
PhysicalDimension? _targetPDim;
bool _targetNotNull;
readonly Dictionary<InputSource, InputDialogEntry> _recvsrcs = new Dictionary<InputSource, InputDialogEntry>();
readonly Dictionary<InputSource, InputDialogEntry> _recvsrcs = new();
void ShowInternal(Action<InputSource?> callback, string message, InputDefinition def, InputProxy proxy) {
_active = true;
_callback = callback;
@@ -56,7 +56,7 @@ namespace Cryville.Crtr.Config.UI {
var result = new PhysicalDimension();
foreach (var comp in comps) {
int dim = 1;
if (comp.Length > 1) dim = int.Parse(comp.Substring(1));
if (comp.Length > 1) dim = int.Parse(comp[1..]);
switch (comp[0]) {
case 'T': result.Time += dim; break;
case 'L': result.Length += dim; break;
@@ -98,8 +98,7 @@ namespace Cryville.Crtr.Config.UI {
Action<InputEvent> _d_HandleInputEvent;
void HandleInputEvent(InputEvent ev) {
InputSource src = ev.Identifier.Source;
InputDialogEntry entry;
if (!_recvsrcs.TryGetValue(src, out entry)) {
if (!_recvsrcs.TryGetValue(src, out InputDialogEntry entry)) {
_recvsrcs.Add(src, entry = AddSourceItem(src));
if (_proxy.IsUsed(src)) {
entry.Status |= InputDeviceStatus.Used;