mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 11:39:43 +00:00
Added leather achievement
This commit is contained in:
parent
0a32bfb06c
commit
3434615f43
2 changed files with 10 additions and 2 deletions
|
|
@ -91,6 +91,11 @@ class AchievementAPI{
|
|||
"acquireIron",
|
||||
),
|
||||
),
|
||||
"leather" => array(
|
||||
"name" => "Get leather",
|
||||
"requires" => array(
|
||||
"buildSword",
|
||||
),
|
||||
|
||||
);
|
||||
|
||||
|
|
@ -102,9 +107,9 @@ class AchievementAPI{
|
|||
$result = ServerAPI::request()->api->dhandle("achievement.broadcast", array("player" => $player, "achievementId" => $achievementId));
|
||||
if($result !== false and $result !== true){
|
||||
if(ServerAPI::request()->api->getProperty("announce-player-achievements") == true){
|
||||
ServerAPI::request()->api->chat->broadcast($player->username." has just earned the achievement ".self::$achievements[$achievementId]["name"]);
|
||||
ServerAPI::request()->api->chat->broadcast($player->username." has just earned the achievement [".self::$achievements[$achievementId]["name"]."]");
|
||||
}else{
|
||||
$player->sendChat("You have just earned the achievement ".self::$achievements[$achievementId]["name"]);
|
||||
$player->sendChat("You have just earned the achievement [".self::$achievements[$achievementId]["name"]."]");
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue