Paper/Bukkit-Patches/0025-Add-Score.isScoreSet-Z-API.patch
Zach Brown 06c1cf41ab Update Spigot's Patches
Fix Build 2339ac14a8e
Regen the patches 89d3fcbdfaf

This new system breaks a lot :(
2014-11-28 18:03:01 -06:00

32 lines
967 B
Diff

From 2dd486923aa364890c40ab072b20bd601d038431 Mon Sep 17 00:00:00 2001
From: md_5 <git@md-5.net>
Date: Thu, 17 Apr 2014 19:35:13 +1000
Subject: [PATCH] Add Score.isScoreSet()Z API.
diff --git a/src/main/java/org/bukkit/scoreboard/Score.java b/src/main/java/org/bukkit/scoreboard/Score.java
index 4c10346..2410cbd 100644
--- a/src/main/java/org/bukkit/scoreboard/Score.java
+++ b/src/main/java/org/bukkit/scoreboard/Score.java
@@ -51,6 +51,17 @@ public interface Score {
*/
void setScore(int score) throws IllegalStateException;
+ // Spigot start
+ /**
+ * Shows if this score has been set at any point in time.
+ *
+ * @return if this score has been set before
+ * @throws IllegalStateException if the associated objective has been
+ * unregistered
+ */
+ boolean isScoreSet() throws IllegalStateException;
+ // Spigot end
+
/**
* Gets the scoreboard for the associated objective.
*
--
2.1.0