From bcf932d616195ae008554127b829bd154f29e038 Mon Sep 17 00:00:00 2001 From: fullwall Date: Fri, 12 Jun 2020 19:31:36 +0800 Subject: [PATCH] Add message about cycle parameter --- .../citizensnpcs/trait/waypoint/LinearWaypointProvider.java | 3 ++- main/src/main/resources/messages_en.properties | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/main/src/main/java/net/citizensnpcs/trait/waypoint/LinearWaypointProvider.java b/main/src/main/java/net/citizensnpcs/trait/waypoint/LinearWaypointProvider.java index 7558e6257..d391b0945 100644 --- a/main/src/main/java/net/citizensnpcs/trait/waypoint/LinearWaypointProvider.java +++ b/main/src/main/java/net/citizensnpcs/trait/waypoint/LinearWaypointProvider.java @@ -552,7 +552,8 @@ public class LinearWaypointProvider implements EnumerableWaypointProvider { @Override public void onCompletion(@Nullable CancelReason cancelReason) { if (npc.isSpawned() && currentDestination != null - && Util.locationWithinRange(npc.getStoredLocation(), currentDestination.getLocation(), 2)) { + && Util.locationWithinRange(npc.getStoredLocation(), currentDestination.getLocation(), + Setting.DEFAULT_DISTANCE_MARGIN.asDouble())) { currentDestination.onReach(npc); if (cachePaths && cancelReason == null) { cachedPaths.put(new SourceDestinationPair(npcLoc, currentDestination), diff --git a/main/src/main/resources/messages_en.properties b/main/src/main/resources/messages_en.properties index 131255285..2c3970e72 100644 --- a/main/src/main/resources/messages_en.properties +++ b/main/src/main/resources/messages_en.properties @@ -311,7 +311,7 @@ citizens.editors.waypoints.guided.added-guide=Added a [[guide]] waypoint. This w citizens.editors.waypoints.guided.added-available=Added a [[destination]] waypoint. This will be available for NPCs to path to. citizens.editors.waypoints.guided.already-taken=There is already a waypoint here. citizens.editors.waypoints.linear.added-waypoint=[[Added]] a waypoint at ({0}) ([[{1}]], [[{2}]]). -citizens.editors.waypoints.linear.begin=Entered the linear waypoint editor!
[[Left click]] to add a waypoint, [[right click]] to remove.
Type [[toggle path]] to toggle showing entities at waypoints,
[[triggers]] to enter the trigger editor,
[[clear]] to clear all waypoints. +citizens.editors.waypoints.linear.begin=Entered the linear waypoint editor!
[[Left click]] to add a waypoint, [[right click]] to remove.
Type [[toggle path]] to toggle showing entities at waypoints,
[[triggers]] to enter the trigger editor,
[[clear]] to clear all waypoints
[[cycle]] to make NPCs go back to cycle through waypoints instead of looping. citizens.editors.waypoints.linear.edit-slot-set=Editing slot set to [[{0}]] ({1}). citizens.editors.waypoints.linear.end=Exited the linear waypoint editor. citizens.editors.waypoints.linear.not-showing-markers=[[Stopped]] showing waypoint markers.