diff --git a/KillRate/README.md b/KillRate/README.md index 363678e..32a9c25 100644 --- a/KillRate/README.md +++ b/KillRate/README.md @@ -24,13 +24,13 @@ that. You are more likely to get a response and help that way. _NOTE:_ -This documentation was last updated for version **1.2.2**. +This documentation was last updated for version **1.2.3**. Please go to [github](https://github.com/alejandroliu/pocketmine-plugins/tree/master/KillRate) for the most up-to-date documentation. -You can also download this plugin from this [page](https://github.com/alejandroliu/pocketmine-plugins/releases/tag/KillRate-1.2.2). +You can also download this plugin from this [page](https://github.com/alejandroliu/pocketmine-plugins/releases/tag/KillRate-1.2.3). @@ -183,7 +183,7 @@ $server->getPluginManager()->getPlugin("KillRate")->function() * 1.2.3: * MySqlMgr: Fixed typo - + * Fixed bug with setting rewards/points to false (Reported by @reidq7) * 1.2.2 * small tweaks on the comments of the config file... * Added achievements diff --git a/KillRate/plugin.yml b/KillRate/plugin.yml index d8e1703..347ad14 100644 --- a/KillRate/plugin.yml +++ b/KillRate/plugin.yml @@ -1,5 +1,5 @@ name: KillRate -version: 1.2.2 +version: 1.2.3 main: aliuly\killrate\Main api: 1.10.0 load: POSTWORLD diff --git a/KillRate/src/aliuly/killrate/Main.php b/KillRate/src/aliuly/killrate/Main.php index 131c488..e8f0666 100644 --- a/KillRate/src/aliuly/killrate/Main.php +++ b/KillRate/src/aliuly/killrate/Main.php @@ -295,13 +295,13 @@ public function updateScores($perp,$vic) { //echo "VIC=$vic PERP=$perp\n";//##DEBUG $this->updateDb($perp,$vic); $awards = [ false,false]; - if (isset($this->cfg["settings"]["points"])) { + if ($this->cfg["settings"]["points"]) { // Add points... list($points,$money) = $this->getPrizes($vic); $this->updateDb($perp,"points",$points); $awards[0] = $points; } - if (isset($this->cfg["settings"]["rewards"])) { + if ($this->cfg["settings"]["rewards"]) { // Add money... list($points,$money) = $this->getPrizes($vic); MoneyAPI::grantMoney($this->money,$perp,$money); @@ -399,7 +399,7 @@ public function deadDealer($pv) { if ($streak > $this->cfg["settings"]["kill-streak"]) { if ($this->cfg["settings"]["achievements"]) $pp->awardAchievement("serialKiller"); $this->getServer()->broadcastMessage(TextFormat::YELLOW.mc::_("%1% has a %2% kill streak",$pp->getName(),$streak)); - if (isset($this->cfg["settings"]["rewards"])) { + if ($this->cfg["settings"]["rewards"]) { list($points,$money) = $this->getPrizes($vic); $pp->sendMessage(TextFormat::GREEN. mc::_("You earn an additional $%1% for being in kill-streak!",$money));