diff --git a/KillRate/README.md b/KillRate/README.md index b594eea..72bdbad 100644 --- a/KillRate/README.md +++ b/KillRate/README.md @@ -221,3 +221,4 @@ The contents of these "ini" files are key-value pairs: You should have received a copy of the GNU General Public License along with this program. If not, see . + diff --git a/KillRate/resources/KillRateEx.php b/KillRate/resources/KillRateEx.php index f972b4a..9cee7bb 100644 --- a/KillRate/resources/KillRateEx.php +++ b/KillRate/resources/KillRateEx.php @@ -46,6 +46,7 @@ use aliuly\killrate\api\KillRateResetEvent; use aliuly\killrate\common\MPMU; + class KillRateEx extends PluginBase implements CommandExecutor,Listener{ public $kr; public $pp; @@ -78,7 +79,7 @@ public function onScoreAdd(KillRateScoreEvent $ev) { if ($clevel >= 5) return; // max level is 5! if (!$ev->getPoints() || $ev->getPoints() < 0) return; // Actually deducting points! - $cscore = $this->kr->getScore($ev->getPlayer()); + $cscore = $this->kr->api->getScore($ev->getPlayer()); $threshold = ($clevel + 1) * ($clevel + 1) * 1000; //echo "cscore=$cscore - threshold=$threshold\n";//##DEBUG