mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
better fall dmg, tweaks to tnt motion, spam remove
This commit is contained in:
parent
9ee4b08657
commit
f3a0705c66
5 changed files with 8 additions and 8 deletions
|
|
@ -859,7 +859,7 @@ class Entity extends Position
|
|||
$clz::fallOn($this->level, $x, $y, $z, $this, floor($this->fallStart - $this->y));
|
||||
}
|
||||
|
||||
$dmg = floor($this->fallStart - $this->y) - 3;
|
||||
$dmg = ceil($this->fallStart - $this->y - 3);
|
||||
if($dmg > 0){
|
||||
$this->harm($dmg, "fall");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ abstract class Living extends Entity implements Pathfindable{
|
|||
//if(self::$despawnMobs) $this->server->schedule(self::$despawnTimer, [$this, "close"]); //900*20
|
||||
}
|
||||
public function fall(){
|
||||
$dmg = floor($this->fallDistance - 3);
|
||||
$dmg = ceil($this->fallDistance - 3);
|
||||
if($dmg > 0){
|
||||
$this->harm($dmg, "fall");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ class Painting extends Entity{
|
|||
const TYPE = OBJECT_PAINTING;
|
||||
public function __construct(Level $level, $eid, $class, $type = 0, $data = []){
|
||||
parent::__construct($level, $eid, $class, $type, $data);
|
||||
$this->x = isset($this->data["TileX"]) ? $this->data["TileX"]:$this->x;
|
||||
$this->y = isset($this->data["TileY"]) ? $this->data["TileY"]:$this->y;
|
||||
$this->z = isset($this->data["TileZ"]) ? $this->data["TileZ"]:$this->z;
|
||||
$this->x = isset($this->data["TileX"]) ? $this->data["TileX"] : $this->x;
|
||||
$this->y = isset($this->data["TileY"]) ? $this->data["TileY"] : $this->y;
|
||||
$this->z = isset($this->data["TileZ"]) ? $this->data["TileZ"] : $this->z;
|
||||
$this->setHealth(1, "generic");
|
||||
$this->canBeAttacked = true;
|
||||
$this->width = 1;
|
||||
|
|
|
|||
|
|
@ -43,8 +43,8 @@ class PrimedTNT extends Entity{
|
|||
$this->speedZ *= 0.98;
|
||||
|
||||
if($this->onGround){
|
||||
$this->speedX *= 0.6;
|
||||
$this->speedZ *= 0.6;
|
||||
$this->speedX *= 0.7;
|
||||
$this->speedZ *= 0.7;
|
||||
|
||||
$this->speedY *= -0.5;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue