Skip to content

Commit

Permalink
Minor PR review fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Shushishtok committed Sep 9, 2024
1 parent 747d272 commit bfe98de
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/TSMapEditor/UI/Windows/TriggersWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ public TriggersWindow(WindowManager windowManager, Map map, EditorState editorSt
changeAttachedTagCursorAction = new ChangeAttachedTagCursorAction(cursorActionTarget);
}

public event EventHandler<TeamTypeEventArgs> TeamTypeOpened;

private readonly Map map;
private readonly ICursorActionTarget cursorActionTarget;
private readonly PlaceCellTagCursorAction placeCellTagCursorAction;
Expand All @@ -48,8 +50,6 @@ public TriggersWindow(WindowManager windowManager, Map map, EditorState editorSt
TriggerParamType.Waypoint,
TriggerParamType.WaypointZZ
};
public event EventHandler<TeamTypeEventArgs> TeamTypeOpened;


private XNADropDown ddActions;

Expand Down Expand Up @@ -1093,12 +1093,8 @@ private void btnActionGoToTarget_LeftClick(object sender, EventArgs e)
waypointNumber = Helpers.GetWaypointNumberFromAlphabeticalString(triggerAction.Parameters[paramIndex]);
}
else
{
var success = int.TryParse(triggerAction.Parameters[paramIndex], out waypointNumber);
if (!success)
{
waypointNumber = -1;
}
{
waypointNumber = Conversions.IntFromString(triggerAction.Parameters[paramIndex], -1);
}

if (waypointNumber == -1)
Expand Down

0 comments on commit bfe98de

Please sign in to comment.