Int64 5.46.0
Wrapping 64-bit integer arithmetic with Java long semantics. PHP turns overflowing int + and * into floats, so these helpers work on 16/32-bit limbs instead. They are only used when seeding random sources, never in per-block loops.
Methods
add()
php
public static function add(int $a, int $b) : intjavaStringHash()
php
public static function javaStringHash(string $s) : intJava's String.hashCode().
mul()
php
public static function mul(int $a, int $b) : intmulInt32()
php
public static function mulInt32(int $a, int $b) : intJava's 32-bit int * int with overflow.
positionSeed()
php
public static function positionSeed(int $x, int $y, int $z) : intMinecraft's positional seed hash (Mth.getSeed).
rotl()
php
public static function rotl(int $value, int $shift) : intsub()
php
public static function sub(int $a, int $b) : inttoInt32()
php
public static function toInt32(int $value) : intJava's (int) cast of a long.
ushr()
php
public static function ushr(int $value, int $shift) : intJava's >>>
