Class: DpNpc
SOURCE LOCATION: /dpuniverse/std/DpNpc.php
Class Overview
|
A 'non playing character', a bot
Creates the following DutchPIPE properties:
- boolean isNpc - Set to TRUE
DpProperties
|
--DpObject
|
--DpLiving
|
--DpNpc
|
METHODS:
|
Methods Summary
| void |
createDpNpc() |
Sets this NPC up at the time it is created |
| void |
tell() |
Tells data (message, window, location, ...) to this NPC |
Methods
void createDpNpc(
)
Sets this NPC up at the time it is created
An empty function which can be redefined by the NPC class extending on DpNpc. When the object is created, it has no title, HTML body, et cetera, so in this method methods like DpObject::setTitle() are called.
void eventDpLiving(
$name
)
void resetDpNpc(
)
Resets this NPC
Called by this NPC at regular intervals as defined in dpuniverse-ini.php. An empty function which can be redefined by the NPC class extending on DpNpc. To be used to periodically do stuff such as alter the state of the NPC.
void tell(
string
$data
)
Tells data (message, window, location, ...) to this NPC
Tells a message to this NPC, for instance a chat line or a new location.
|
|