mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 03:59:43 +00:00
Unnecessary ":?" (2)
This commit is contained in:
parent
0f26e45638
commit
69385e16f2
21 changed files with 36 additions and 48 deletions
|
|
@ -14,7 +14,7 @@ abstract class Animal extends Creature implements Ageable, Breedable{
|
|||
|
||||
public function __construct(Level $level, $eid, $class, $type = 0, $data = []){
|
||||
parent::__construct($level, $eid, $class, $type, $data);
|
||||
$this->setAge(isset($data["Age"]) ? $data["Age"] : 0);
|
||||
$this->setAge($data["Age"] ?? 0);
|
||||
if(isset($this->data["IsBaby"]) && $this->data["IsBaby"] && $this->getAge() >= 0){
|
||||
$this->setAge(-24000);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue