|
| | __construct (Level $level, CompoundTag $nbt) |
| |
| | getColor () |
| |
| | setColor (int $color) |
| |
| | getSpawnCompound () |
| |
| | spawnTo (Player $player) |
| |
| | __construct (Level $level, CompoundTag $nbt) |
| |
| | spawnToAll () |
| |
| | getSpawnCompound () |
| |
| | updateCompoundTag (CompoundTag $nbt, Player $player) |
| |
| | getSaveId () |
| |
| | __construct (Level $level, CompoundTag $nbt) |
| |
| | getId () |
| |
| | saveNBT () |
| |
| | getBlock () |
| |
| | onUpdate () |
| |
| | scheduleUpdate () |
| |
| | __destruct () |
| |
| | close () |
| |
| | getName () |
| |
| | __construct ($x=0, $y=0, $z=0, Level $level=null) |
| |
| | asPosition () |
| |
| | add ($x, $y=0, $z=0) |
| |
| | getLevel () |
| |
| | setLevel (Level $level=null) |
| |
| | isValid () |
| |
| | getSide ($side, $step=1) |
| |
| | __toString () |
| |
| | setComponents ($x, $y, $z) |
| |
| | fromObjectAdd (Vector3 $pos, $x, $y, $z) |
| |
| | __construct ($x=0, $y=0, $z=0) |
| |
| | getX () |
| |
| | getY () |
| |
| | getZ () |
| |
| | getFloorX () |
| |
| | getFloorY () |
| |
| | getFloorZ () |
| |
| | getRight () |
| |
| | getUp () |
| |
| | getForward () |
| |
| | getSouth () |
| |
| | getWest () |
| |
| | add ($x, $y=0, $z=0) |
| |
| | subtract ($x=0, $y=0, $z=0) |
| |
| | multiply ($number) |
| |
| | divide ($number) |
| |
| | ceil () |
| |
| | floor () |
| |
| | round () |
| |
| | abs () |
| |
| | getSide ($side, $step=1) |
| |
| | asVector3 () |
| |
| | distance (Vector3 $pos) |
| |
| | distanceSquared (Vector3 $pos) |
| |
| | maxPlainDistance ($x=0, $z=0) |
| |
| | length () |
| |
| | lengthSquared () |
| |
| | normalize () |
| |
| | dot (Vector3 $v) |
| |
| | cross (Vector3 $v) |
| |
| | equals (Vector3 $v) |
| |
| | getIntermediateWithXValue (Vector3 $v, $x) |
| |
| | getIntermediateWithYValue (Vector3 $v, $y) |
| |
| | getIntermediateWithZValue (Vector3 $v, $z) |
| |
| | setComponents ($x, $y, $z) |
| |
| | fromObjectAdd (Vector3 $pos, $x, $y, $z) |
| |
| | __toString () |
| |
◆ __construct()
Bed constructor.
- Parameters
-
| Level | $level | |
| CompoundTag | $nbt | |
26 if(!isset($nbt->color) or !($nbt->color instanceof
ByteTag)){
27 $nbt->color =
new ByteTag(
"color", 14);
29 parent::__construct(
$level, $nbt);
◆ getColor()
- Returns
- int
36 return $this->namedtag->color->getValue();
◆ getSpawnCompound()
- Returns
- CompoundTag
53 new IntTag(
"x", (
int) $this->x),
54 new IntTag(
"y", (
int) $this->y),
55 new IntTag(
"z", (
int) $this->z),
56 $this->namedtag->color
◆ setColor()
- Parameters
-
43 $this->namedtag[
"color"] = $color & 0x0f;
The documentation for this class was generated from the following file:
- src/pocketmine/tile/Bed.php