Merge pull request #3870 from jplsek/swap-assign

Menu Swapper - Add Age/Assignment Swapping
This commit is contained in:
Tomas Slusny
2018-06-22 21:42:12 +02:00
committed by GitHub
2 changed files with 33 additions and 0 deletions

View File

@@ -232,4 +232,26 @@ public interface MenuEntrySwapperConfig extends Config
{
return true;
}
@ConfigItem(
position = 18,
keyName = "swapAge",
name = "Age",
description = "Swap Talk-to with Age for Hans"
)
default boolean swapAge()
{
return true;
}
@ConfigItem(
position = 19,
keyName = "swapAssignment",
name = "Assignment",
description = "Swap Talk-to with Assignment for Slayer Masters. This will take priority over swapping Trade."
)
default boolean swapAssignment()
{
return true;
}
}

View File

@@ -351,6 +351,12 @@ public class MenuEntrySwapperPlugin extends Plugin
swap("exchange", option, target, true);
}
// make sure assignment swap is higher priority than trade swap for slayer masters
if (config.swapAssignment())
{
swap("assignment", option, target, true);
}
if (config.swapTrade())
{
swap("trade", option, target, true);
@@ -379,6 +385,11 @@ public class MenuEntrySwapperPlugin extends Plugin
{
swap("pay", option, target, true);
}
if (config.swapAge())
{
swap("age", option, target, true);
}
}
else if (config.swapTravel() && option.equals("pass") && target.equals("energy barrier"))
{