Phpcraft
Public Member Functions | Public Attributes | List of all members
Phpcraft\Event\ServerTickEvent Class Reference
Inheritance diagram for Phpcraft\Event\ServerTickEvent:
Inheritance graph
[legend]
Collaboration diagram for Phpcraft\Event\ServerTickEvent:
Collaboration graph
[legend]

Public Member Functions

 __construct (Server $server, bool $lagging)
 
- Public Member Functions inherited from Phpcraft\Event\ServerEvent
 __construct (Server $server)
 

Public Attributes

 $lagging
 
- Public Attributes inherited from Phpcraft\Event\ServerEvent
 $server
 
- Public Attributes inherited from Phpcraft\Event\Event
const PRIORITY_HIGHEST = 2
 
const PRIORITY_HIGH = 1
 
const PRIORITY_NORMAL = 0
 
const PRIORITY_LOW = -1
 
const PRIORITY_LOWEST = -2
 
 $cancelled = false
 

Constructor & Destructor Documentation

◆ __construct()

Phpcraft\Event\ServerTickEvent::__construct ( Server  $server,
bool  $lagging 
)
Parameters
Server$serverThe server emitting the event.
bool$lagging

Member Data Documentation

◆ $lagging

bool Phpcraft\Event\ServerTickEvent::$lagging

True if this tick event should've been fired much earlier but wasn't because the server was busy. If your task is complex and/or doesn't need to be executed every tick, try not doing it if this is true.