Skip to content

Commit

Permalink
Merge branch 'master' into add-paste-tooltip
Browse files Browse the repository at this point in the history
  • Loading branch information
BlueSoapTurtle committed Oct 27, 2024
2 parents d5863ce + 76480f0 commit f45e86e
Show file tree
Hide file tree
Showing 14 changed files with 523 additions and 304 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,30 @@

### Changelog

#### V1.6.0
* Adds support for potion order reordering in the interface. For now, the only available options are: Vanilla (default) & By Station type
* Customizable notifications for digweed spawns

#### V1.5.0
* Removal of the potion highlighting strategies, these were conceived when you could only deliver one potion at a time, now it is almost always better to fulfill all orders before delivering.
* Improved quick-action highlighting behavior.
* An option to display the amount of resin you have has been added, it is set to disabled by default.

#### V1.4.1
* Fix repeated potion orders not being marked as fulfilled
* Fix `ready!` indicator when using the `NONE` strategy
* Replaced the `ready!` indicator with `done!`

#### V1.4.0
* Separated quick-action from station highlighting
* Station highlighting is now based on potions in the inventory instead of what you're currently mixing, this should greatly help those who mix multiple potions at the same time
* Added a `ready!` indicator whenever you finish refining a potion that fulfills an order
* Added inventory potion identification similar to the Item Identification plugin, this can be disabled in the plugin settings

#### V1.3.0
* Added lever highlighting
* Fixed potion experience values

#### V1.2.0
* Fixed a bug where using another station rather than the highlighted would not dismiss it even after delivering the potions
* Fixed a bug where disabling station highlights would still keep them highlighted until fulfilling an order
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ dependencies {
}

group = 'work.fking.rlplugins'
version = '1.2.0'
version = '1.6.0'

tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
package work.fking.masteringmixology;

import net.runelite.api.widgets.WidgetItem;
import net.runelite.client.ui.FontManager;
import net.runelite.client.ui.overlay.WidgetItemOverlay;

import javax.inject.Inject;
import java.awt.Color;
import java.awt.Graphics2D;

public class InventoryPotionOverlay extends WidgetItemOverlay {

private final MasteringMixologyPlugin plugin;
private final MasteringMixologyConfig config;

@Inject
InventoryPotionOverlay(MasteringMixologyPlugin plugin, MasteringMixologyConfig config) {
this.plugin = plugin;
this.config = config;
showOnInventory();
}

@Override
public void renderItemOverlay(Graphics2D graphics2D, int itemId, WidgetItem widgetItem) {
if (!plugin.isInLab() || !config.identifyPotions()) {
return;
}

var potion = PotionType.fromItemId(itemId);
if (potion == null) {
return;
}

var bounds = widgetItem.getCanvasBounds();
graphics2D.setFont(FontManager.getRunescapeSmallFont());

graphics2D.setColor(Color.WHITE);
graphics2D.drawString(potion.abbreviation(), bounds.x - 1, bounds.y + 15);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import net.runelite.client.config.ConfigGroup;
import net.runelite.client.config.ConfigItem;
import net.runelite.client.config.ConfigSection;
import net.runelite.client.config.Notification;

import java.awt.Color;

Expand All @@ -22,13 +23,23 @@ public interface MasteringMixologyConfig extends Config {
String HIGHLIGHTS = "Highlights";

@ConfigItem(
keyName = "strategy",
name = "Strategy",
description = "Selects the potion order highlighting strategy",
keyName = "potionOrderSorting",
name = "Order sorting",
description = "Determines how potion orders are sorted in the interface",
position = 1
)
default Strategy strategy() {
return Strategy.FAVOR_EXPERIENCE;
default PotionOrderSorting potionOrderSorting() {
return PotionOrderSorting.VANILLA;
}

@ConfigItem(
keyName = "highlightLevers",
name = "Highlight levers",
description = "Highlight levers",
position = 2
)
default boolean highlightLevers() {
return true;
}

@ConfigItem(
Expand All @@ -41,6 +52,36 @@ default boolean highlightStations() {
return true;
}

@ConfigItem(
keyName = "highlightQuickActionEvents",
name = "Highlight quick-action events",
description = "Toggles station quick-action events highlighting on or off",
position = 2
)
default boolean highlightQuickActionEvents() {
return true;
}

@ConfigItem(
keyName = "identifyPotions",
name = "Identify potions",
description = "Identify potions in your inventory",
position = 2
)
default boolean identifyPotions() {
return true;
}

@ConfigItem(
keyName = "displayResin",
name = "Display resin amount",
description = "Display total resin amounts",
position = 2
)
default boolean displayResin() {
return false;
}

@ConfigItem(
keyName = "stationHighlightColor",
name = "Station color",
Expand All @@ -67,8 +108,8 @@ default Color stationQuickActionHighlightColor() {
description = "Toggles digweed notifications on or off",
position = 5
)
default boolean notifyDigWeed() {
return true;
default Notification notifyDigWeed() {
return Notification.ON;
}

@ConfigItem(
Expand Down
Loading

0 comments on commit f45e86e

Please sign in to comment.