/SimpleTCP

Simple TCP server for PocketMine-MP (PMMP). Simple as never before.

Primary LanguagePHPMIT LicenseMIT

SimpleTCP

Usage

Very simple usage:

$server = SimpleTCP::start("0.0.0.0", 2000, CustomSession::class);

CustomSession.php:

class CustomSession extends Session{

	public function handlePacket(string $packet) : void{
		//packet handling stuff here
		//now I just send back packet I got from client
		$this->write($packet);
	}
}