Skip to content

Commit 9d9ae1b

Browse files
committed
misc: clean up unit descriptors for new EM units
1 parent da5266f commit 9d9ae1b

4 files changed

Lines changed: 52 additions & 4 deletions

File tree

Editor/Descriptors/EMAddPointsUnitDescriptor.cs

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public EMAddPointsUnitDescriptor(EMAddPointsUnit target) : base(target)
3030
protected override string DefinedSummary()
3131
{
3232
return "This node takes an incoming point value and pulses values to that can be used to simulate adding points to a score reel. "
33-
+ "For example, an incoming point value of 500 will provide 5 pulses of 100.";
33+
+ "\n\nFor example, an incoming point value of 500 will provide 5 pulses of 100.";
3434
}
3535

3636
protected override EditorTexture DefinedIcon() => EditorTexture.Single(Unity.Editor.Icons.Mech(Unity.Editor.IconSize.Large, Unity.Editor.IconColor.Orange));
@@ -40,6 +40,29 @@ protected override void DefinedPort(IUnitPort port, UnitPortDescription desc)
4040
base.DefinedPort(port, desc);
4141

4242
switch (port.key) {
43+
case nameof(EMAddPointsUnit.pointValue):
44+
desc.summary = "The total amount of points to add.";
45+
break;
46+
47+
case nameof(EMAddPointsUnit.duration):
48+
desc.summary = "The amount of time (in ms) the score motor runs.";
49+
break;
50+
51+
case nameof(EMAddPointsUnit.started):
52+
desc.summary = "Triggered when score motor starts.";
53+
break;
54+
55+
case nameof(EMAddPointsUnit.stopped):
56+
desc.summary = "Triggered when score motor finishes.";
57+
break;
58+
59+
case nameof(EMAddPointsUnit.pulse):
60+
desc.summary = "Triggered during each pulse of the score motor.";
61+
break;
62+
63+
case nameof(EMAddPointsUnit.OutputPointValue):
64+
desc.summary = "The current pulses calculated points value that can be used to increment a score value and update a score reel.";
65+
break;
4366
}
4467
}
4568
}

Editor/Descriptors/EMResetPointsUnitDescriptor.cs

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public EMResetPointsUnitDescriptor(EMResetPointsUnit target) : base(target)
3030
protected override string DefinedSummary()
3131
{
3232
return "This node takes an incoming point value and pulses values to that can be used to simulate the resetting of a score reel. "
33-
+ "For example, an incoming point value of 2041 will provide the following pulses: 3052, 4063, 5074, 6085, 7096, 8007, 9008, 0009, 0000";
33+
+ "\n\nFor example, an incoming point value of 2041 will provide the following pulses: 3052, 4063, 5074, 6085, 7096, 8007, 9008, 0009, 0000";
3434
}
3535

3636
protected override EditorTexture DefinedIcon() => EditorTexture.Single(Unity.Editor.Icons.Mech(Unity.Editor.IconSize.Large, Unity.Editor.IconColor.Orange));
@@ -40,6 +40,29 @@ protected override void DefinedPort(IUnitPort port, UnitPortDescription desc)
4040
base.DefinedPort(port, desc);
4141

4242
switch (port.key) {
43+
case nameof(EMResetPointsUnit.pointValue):
44+
desc.summary = "The starting points value used to seed the reset sequence.";
45+
break;
46+
47+
case nameof(EMResetPointsUnit.duration):
48+
desc.summary = "The amount of time (in ms) the score motor runs.";
49+
break;
50+
51+
case nameof(EMResetPointsUnit.started):
52+
desc.summary = "Triggered when score motor starts.";
53+
break;
54+
55+
case nameof(EMResetPointsUnit.stopped):
56+
desc.summary = "Triggered when score motor finishes.";
57+
break;
58+
59+
case nameof(EMResetPointsUnit.pulse):
60+
desc.summary = "Triggered during each pulse of the score motor.";
61+
break;
62+
63+
case nameof(EMResetPointsUnit.OutputPointValue):
64+
desc.summary = "The current pulses calculated points value that can be used to update a score reel.";
65+
break;
4366
}
4467
}
4568
}

Runtime/Nodes/EM/EMAddPointsUnit.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ public class EMAddPointsUnit : GleUnit
4949
[DoNotSerialize]
5050
public ValueInput pointValue { get; private set; }
5151

52-
[DoNotSerialize, PortLabel("Point Value"), Inspectable]
52+
[DoNotSerialize]
53+
[PortLabel("Point Value")]
5354
public ValueOutput OutputPointValue { get; private set; }
5455

5556
private Bool running = false;

Runtime/Nodes/EM/EMResetPointsUnit.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ public class EMResetPointsUnit : GleUnit
4949
[DoNotSerialize]
5050
public ValueInput pointValue { get; private set; }
5151

52-
[DoNotSerialize, PortLabel("Point Value"), Inspectable]
52+
[DoNotSerialize]
53+
[PortLabel("Point Value")]
5354
public ValueOutput OutputPointValue { get; private set; }
5455

5556
private Bool running = false;

0 commit comments

Comments
 (0)