Skip to content

Commit 633383b

Browse files
committed
Use replace to change protoflux string inputs
1 parent 2e435b4 commit 633383b

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

DynamicVariablePowerTools/DynamicVariablePowerTools.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<PackageId>DynamicVariablePowerTools</PackageId>
55
<Title>Dynamic Variable Power Tools</Title>
66
<Authors>Banane9</Authors>
7-
<Version>0.1.0-beta</Version>
7+
<Version>0.1.1-beta</Version>
88
<Description>This MonkeyLoader mod for Resonite adds a variety of powerful functions to dynamic variables and their spaces.</Description>
99
<PackageReadmeFile>README.md</PackageReadmeFile>
1010
<PackageLicenseExpression>LGPL-3.0-or-later</PackageLicenseExpression>

DynamicVariablePowerTools/RenameDirectlyLinkedVariables.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,12 @@ private static void RenameSpace(DynamicVariableSpace space, string newName)
6060
{
6161
space.Slot.ForeachComponentInChildren<IInput<string>>(stringInput =>
6262
{
63+
// this eats variables like: Space/{0} - so can't construct new name from {newName}/{variableName}
6364
DynamicVariableHelper.ParsePath(stringInput.Value, out var spaceName, out var variableName);
6465
if (spaceName == null || spaceName != currentName)
6566
return;
6667

67-
stringInput.Value = $"{newName}/{variableName}";
68+
stringInput.Value = stringInput.Value.Replace(spaceName, newName);
6869
}, includeLocal: true, cacheItems: true);
6970
}
7071

0 commit comments

Comments
 (0)