Merge pull request #2345 from Owain94/merge1502
project: Merge upstream
This commit is contained in:
@@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
object ProjectVersions {
|
object ProjectVersions {
|
||||||
const val launcherVersion = "2.0.4"
|
const val launcherVersion = "2.0.4"
|
||||||
const val rlVersion = "1.6.6-SNAPSHOT"
|
const val rlVersion = "1.6.6"
|
||||||
|
|
||||||
const val openosrsVersion = "3.0.0"
|
const val openosrsVersion = "3.0.0"
|
||||||
|
|
||||||
|
|||||||
@@ -92,6 +92,7 @@ public class HiscoreResult
|
|||||||
private Skill kreearra;
|
private Skill kreearra;
|
||||||
private Skill krilTsutsaroth;
|
private Skill krilTsutsaroth;
|
||||||
private Skill mimic;
|
private Skill mimic;
|
||||||
|
private Skill nightmare;
|
||||||
private Skill obor;
|
private Skill obor;
|
||||||
private Skill sarachnis;
|
private Skill sarachnis;
|
||||||
private Skill scorpia;
|
private Skill scorpia;
|
||||||
@@ -237,6 +238,8 @@ public class HiscoreResult
|
|||||||
return krilTsutsaroth;
|
return krilTsutsaroth;
|
||||||
case MIMIC:
|
case MIMIC:
|
||||||
return mimic;
|
return mimic;
|
||||||
|
case NIGHTMARE:
|
||||||
|
return nightmare;
|
||||||
case OBOR:
|
case OBOR:
|
||||||
return obor;
|
return obor;
|
||||||
case SARACHNIS:
|
case SARACHNIS:
|
||||||
|
|||||||
@@ -117,6 +117,7 @@ class HiscoreResultBuilder
|
|||||||
hiscoreResult.setKreearra(skills.get(index++));
|
hiscoreResult.setKreearra(skills.get(index++));
|
||||||
hiscoreResult.setKrilTsutsaroth(skills.get(index++));
|
hiscoreResult.setKrilTsutsaroth(skills.get(index++));
|
||||||
hiscoreResult.setMimic(skills.get(index++));
|
hiscoreResult.setMimic(skills.get(index++));
|
||||||
|
hiscoreResult.setNightmare(skills.get(index++));
|
||||||
hiscoreResult.setObor(skills.get(index++));
|
hiscoreResult.setObor(skills.get(index++));
|
||||||
hiscoreResult.setSarachnis(skills.get(index++));
|
hiscoreResult.setSarachnis(skills.get(index++));
|
||||||
hiscoreResult.setScorpia(skills.get(index++));
|
hiscoreResult.setScorpia(skills.get(index++));
|
||||||
|
|||||||
@@ -96,6 +96,7 @@ public enum HiscoreSkill
|
|||||||
KREEARRA("Kree'Arra", BOSS),
|
KREEARRA("Kree'Arra", BOSS),
|
||||||
KRIL_TSUTSAROTH("K'ril Tsutsaroth", BOSS),
|
KRIL_TSUTSAROTH("K'ril Tsutsaroth", BOSS),
|
||||||
MIMIC("Mimic", BOSS),
|
MIMIC("Mimic", BOSS),
|
||||||
|
NIGHTMARE("Nightmare", BOSS),
|
||||||
OBOR("Obor", BOSS),
|
OBOR("Obor", BOSS),
|
||||||
SARACHNIS("Sarachnis", BOSS),
|
SARACHNIS("Sarachnis", BOSS),
|
||||||
SCORPIA("Scorpia", BOSS),
|
SCORPIA("Scorpia", BOSS),
|
||||||
|
|||||||
@@ -80,12 +80,26 @@ public abstract class WidgetItemOverlay extends Overlay
|
|||||||
Widget parent = widget.getParent();
|
Widget parent = widget.getParent();
|
||||||
Rectangle parentBounds = parent.getBounds();
|
Rectangle parentBounds = parent.getBounds();
|
||||||
Rectangle itemCanvasBounds = widgetItem.getCanvasBounds();
|
Rectangle itemCanvasBounds = widgetItem.getCanvasBounds();
|
||||||
|
boolean dragging = widgetItem.getDraggingCanvasBounds() != null;
|
||||||
|
|
||||||
boolean shouldClip;
|
boolean shouldClip;
|
||||||
shouldClip = itemCanvasBounds.y < parentBounds.y && itemCanvasBounds.y + itemCanvasBounds.height >= parentBounds.y;
|
if (dragging)
|
||||||
shouldClip |= itemCanvasBounds.y < parentBounds.y + parentBounds.height && itemCanvasBounds.y + itemCanvasBounds.height >= parentBounds.y + parentBounds.height;
|
{
|
||||||
shouldClip |= itemCanvasBounds.x < parentBounds.x && (itemCanvasBounds.x + itemCanvasBounds.width) >= parentBounds.x;
|
// If dragging, clip if the dragged item is outside of the parent bounds
|
||||||
shouldClip |= itemCanvasBounds.x < parentBounds.x + parentBounds.width && itemCanvasBounds.x + itemCanvasBounds.width >= parentBounds.x + parentBounds.width;
|
shouldClip = itemCanvasBounds.x < parentBounds.x;
|
||||||
|
shouldClip |= itemCanvasBounds.x + itemCanvasBounds.width >= parentBounds.x + parentBounds.width;
|
||||||
|
shouldClip |= itemCanvasBounds.y < parentBounds.y;
|
||||||
|
shouldClip |= itemCanvasBounds.y + itemCanvasBounds.height >= parentBounds.y + parentBounds.height;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Otherwise, we only need to clip the overlay if it intersects the parent bounds,
|
||||||
|
// since items completely outside of the parent bounds are not drawn
|
||||||
|
shouldClip = itemCanvasBounds.y < parentBounds.y && itemCanvasBounds.y + itemCanvasBounds.height >= parentBounds.y;
|
||||||
|
shouldClip |= itemCanvasBounds.y < parentBounds.y + parentBounds.height && itemCanvasBounds.y + itemCanvasBounds.height >= parentBounds.y + parentBounds.height;
|
||||||
|
shouldClip |= itemCanvasBounds.x < parentBounds.x && itemCanvasBounds.x + itemCanvasBounds.width >= parentBounds.x;
|
||||||
|
shouldClip |= itemCanvasBounds.x < parentBounds.x + parentBounds.width && itemCanvasBounds.x + itemCanvasBounds.width >= parentBounds.x + parentBounds.width;
|
||||||
|
}
|
||||||
if (shouldClip)
|
if (shouldClip)
|
||||||
{
|
{
|
||||||
if (curClipParent != parent)
|
if (curClipParent != parent)
|
||||||
|
|||||||
Reference in New Issue
Block a user