Adds given spell to player's spell book (makes him knowing it).
Adds given spell to player's spell book (makes him knowing it).
Parameters:
API Tags:
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.4 |
| Throws: | PDOException On PDO operation error. |
Adds player to VIP list.
Adds player to VIP list.
Parameters:
API Tags:
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.3 |
| Throws: | PDOException On PDO operation error. |
void ban(
[int
$time = 0]
)
|
|
Parameters:
|
int |
$time: |
Time for time until expires (0 - forever). |
API Tags:
| Deprecated: | 0.1.5 Use OTS_PlayerBan class. |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Deletes player.
Deletes player.
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Removes given spell from player's spell book.
Removes given spell from player's spell book.
Parameters:
API Tags:
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.4 |
| Throws: | PDOException On PDO operation error. |
Deletes player from VIP list.
Deletes player from VIP list.
Parameters:
API Tags:
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.3 |
| Throws: | PDOException On PDO operation error. |
void find(
string
$name
)
|
|
Loads player by it's name.
Loads player by it's name.
Parameters:
|
string |
$name: |
Player's name. |
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.0.2 |
Redefinition of:
- OTS_Row_DAO::find()
- Loads row by it's name.
Returns account of this player.
Returns account of this player.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Owning account. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Throws: | PDOException On PDO operation error. |
Bank balance.
Bank balance.
API Tags:
| Return: | Amount of money stored in bank. |
| Access: | public |
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.2 |
Capacity.
Capacity.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Capacity. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Conditions.
Conditions.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Conditions binary string. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
string getCustomField(
string
$field
)
|
|
Reads custom field.
Reads custom field.
Reads field by it's name. Can read any field of given record that exists in database.
Note: You should use this method only for fields that are not provided in standard setters/getters (SVN fields). This method runs SQL query each time you call it so it highly overloads used resources.
Parameters:
|
string |
$field: |
Field name. |
API Tags:
| Return: | Field value. |
| Access: | public |
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
Returns items tree from given depot.
Returns items tree from given depot.
You need global items list resources loaded in order to use this method.
Parameters:
|
int |
$depot: |
Depot ID to get items. |
API Tags:
| Return: | Item in given depot (items tree if in given depot there is a container). If there is no item in depot then null value will be returned. |
| Access: | public |
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotAContainer If item which is not of type container contains sub items. |
| Throws: | E_OTS_NotLoaded If player is not loaded or there is no global items list resource loaded. |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.0.3 |
Looking direction.
Looking direction.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Looking direction. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Experience points.
Experience points.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Experience points. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Returns group of this player.
Returns group of this player.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Group of which current character is member. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Throws: | PDOException On PDO operation error. |
Guild nick.
Guild nick.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Guild title. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Current HP.
Current HP.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Current HP. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Maximum HP.
Maximum HP.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Maximum HP. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Returns house rented by this player.
Returns house rented by this player.
You need global houses list resource loaded in order to use this method.
API Tags:
| Return: | House rented by player. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded or global houses list is not loaded. |
| Since: | 0.1.0 |
| Throws: | PDOException On PDO operation error. |
Player ID.
Player ID.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Player ID. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Last login IP.
Last login IP.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Last login IP. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Last login timestamp.
Last login timestamp.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Last login timestamp. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Last logout timestamp.
Last logout timestamp.
API Tags:
| Return: | Last logout timestamp. |
| Access: | public |
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.6 |
Experience level.
Experience level.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Experience level. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Addons.
Addons.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Addons. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Body color.
Body color.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Body color. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Boots color.
Boots color.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Boots color. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Hair color.
Hair color.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Hair color. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Legs color.
Legs color.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Legs color. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Outfit.
Outfit.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Outfit. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Percentage of experience lost after dead.
Percentage of experience lost after dead.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Percentage of experience lost after dead. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Percentage of items lost after dead.
Percentage of items lost after dead.
API Tags:
| Return: | Percentage of items lost after dead. |
| Access: | public |
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.4 |
Percentage of used mana lost after dead.
Percentage of used mana lost after dead.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Percentage of used mana lost after dead. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Percentage of skills lost after dead.
Percentage of skills lost after dead.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Percentage of skills lost after dead. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Magic level.
Magic level.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Magic level. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Current mana.
Current mana.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Current mana. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Maximum mana.
Maximum mana.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Maximum mana. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Mana spent.
Mana spent.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Mana spent. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Player name.
Player name.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Player's name. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
X map coordinate.
X map coordinate.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | X map coordinate. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Y map coordinate.
Y map coordinate.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Y map coordinate. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Z map coordinate.
Z map coordinate.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Z map coordinate. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Player's Premium Account expiration timestamp.
Player's Premium Account expiration timestamp.
API Tags:
| Return: | Player PACC expiration timestamp. |
| Deprecated: | 0.1.5 Use OTS_Account->getPremiumEnd(). |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Since: | 0.0.3 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Assigned guild rank.
Assigned guild rank.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Guild rank (null if not member of any). |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Throws: | PDOException On PDO operation error. |
API Tags:
| Return: | Guild rank ID. |
| Deprecated: | 0.0.4 Use getRank(). |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Red skulled time remained.
Red skulled time remained.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Red skulled time remained. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
API Tags:
| Return: | Save counter. |
| Deprecated: | 0.0.7 Save field is back as flag not a counter. |
| Access: | public |
Information Tags:
| Version: | 0.0.7 |
| Version: | 0.0.1 |
| Since: | 0.0.6 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Player gender.
Player gender.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Player gender. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
int getSkill(
int
$skill
)
|
|
Returns player's skill.
Returns player's skill.
Parameters:
API Tags:
| Return: | Skill value. |
| Access: | public |
Information Tags:
| Version: | 0.0.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.2 |
int getSkillTries(
int
$skill
)
|
|
Returns player's skill's tries for next level.
Returns player's skill's tries for next level.
Parameters:
API Tags:
| Return: | Skill tries. |
| Access: | public |
Information Tags:
| Version: | 0.0.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.2 |
Returns items tree from given slot.
Returns items tree from given slot.
You need global items list resources loaded in order to use this method.
Parameters:
|
int |
$slot: |
Slot to get items. |
API Tags:
| Return: | Item in given slot (items tree if in given slot there is a container). If there is no item in slot then null value will be returned. |
| Access: | public |
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotAContainer If item which is not of type container contains sub items. |
| Throws: | E_OTS_NotLoaded If player is not loaded or there is no global items list resource loaded. |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.0.3 |
Soul points.
Soul points.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Soul points. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Returns list of known spells.
Returns list of known spells.
You need global spells list resource loaded in order to use this method.
API Tags:
| Return: | List of known spells. |
| Access: | public |
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.4 |
| Throws: | PDOException On PDO operation error. |
Stamina.
Stamina.
API Tags:
| Return: | Miliseconds of stamina left. |
| Access: | public |
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.6 |
int|null getStorage(
int
$key
)
|
|
Returns value of storage record.
Returns value of storage record.
Parameters:
API Tags:
| Return: | Stored value (null if not set). |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.2 |
| Throws: | PDOException On PDO operation error. |
Residence town's ID.
Residence town's ID.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Residence town's ID. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Player residence town name.
Player residence town name.
You need global map resource loaded in order to use this method.
API Tags:
| Return: | Player town name. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded or global map is not loaded. |
| Since: | 0.1.0 |
Returns list of VIPs.
Returns list of VIPs.
It means list of players which this player have on his/her list.
API Tags:
| Return: | List of VIPs. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.3 |
| Throws: | PDOException On PDO operation error. |
Player proffesion.
Player proffesion.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Player proffesion. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
string getVocationName(
)
|
|
Player proffesion name.
Player proffesion name.
You need global vocations list resource loaded in order to use this method.
API Tags:
| Return: | Player proffesion name. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded or global vocations list is not loaded. |
| Since: | 0.0.6 |
Checks if player has red skull.
Checks if player has red skull.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Red skull state. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Checks if player knows given spell.
Checks if player knows given spell.
Parameters:
API Tags:
| Return: | True if player knows given spell, false otherwise. |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.4 |
| Throws: | PDOException On PDO operation error. |
API Tags:
| Return: | True if player is banned, false otherwise. |
| Deprecated: | 0.1.5 Use OTS_PlayerBan class. |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Checks if object is loaded.
Checks if object is loaded.
API Tags:
| Return: | Load state. |
| Access: | public |
Information Tags:
Checks if save flag is set.
Checks if save flag is set.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | PACC days. |
| Access: | public |
Information Tags:
| Version: | 0.0.7 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
Checks if given player is a VIP for current one.
Checks if given player is a VIP for current one.
Parameters:
API Tags:
| Return: | True, if given player is on VIP list. |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.3 |
| Throws: | PDOException On PDO operation error. |
Loads player with given id.
Loads player with given id.
Parameters:
API Tags:
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
Redefinition of:
- OTS_Row_DAO::load()
- Loads row by it's ID.
Saves player in database.
Saves player in database.
If player is not loaded to represent any existing group it will create new row for it.
API Tags:
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
Assigns character to account.
Assigns character to account.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If passed $account parameter is not loaded. |
void setBalance(
int
$balance
)
|
|
Sets bank balance value.
Sets bank balance value.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$balance: |
Amount of money to be set in bank. |
API Tags:
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Since: | 0.1.2 |
Sets capacity.
Sets capacity.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setConditions(
string
$conditions
)
|
|
Sets conditions.
Sets conditions.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
string |
$conditions: |
Condition binary string. |
API Tags:
Information Tags:
void setCustomField(
string
$field, mixed
$value
)
|
|
Writes custom field.
Writes custom field.
Write field by it's name. Can write any field of given record that exists in database.
Note: You should use this method only for fields that are not provided in standard setters/getters (SVN fields). This method runs SQL query each time you call it so it highly overloads used resources.
Note: Make sure that you pass $value argument of correct type. This method determinates whether to quote field value. It is safe - it makes you sure that no unproper queries that could lead to SQL injection will be executed, but it can make your code working wrong way. For example: $object->setCustomField('foo', '1'); will quote 1 as as string ('1') instead of passing it as a integer.
Parameters:
|
string |
$field: |
Field name. |
|
mixed |
$value: |
Field value. |
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
void setDepot(
int
$depot, [OTS_Item
$item = null], [int
$pid = 0], [int
$depot_id = 0]
)
|
|
Sets depot content.
Sets depot content.
Parameters:
|
int |
$depot: |
Depot ID to save items. |
|
OTS_Item |
$item: |
Item (can be a container with content) for given depot. Leave this parameter blank to clear depot. |
|
int |
$pid: |
Deprecated, not used anymore. |
|
int |
$depot_id: |
Internal, for further use. |
API Tags:
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
void setDirection(
int
$direction
)
|
|
Sets looking direction.
Sets looking direction.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$direction: |
Looking direction. |
API Tags:
Information Tags:
void setExperience(
int
$experience
)
|
|
Sets experience points.
Sets experience points.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$experience: |
Experience points. |
API Tags:
Information Tags:
Assigns character to group.
Assigns character to group.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If passed $group parameter is not loaded. |
void setGuildNick(
string
$guildnick
)
|
|
Sets guild nick.
Sets guild nick.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setHealth(
int
$health
)
|
|
Sets current HP.
Sets current HP.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setHealthMax(
int
$healthmax
)
|
|
Sets maximum HP.
Sets maximum HP.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$healthmax: |
Maximum HP. |
API Tags:
Information Tags:
void setLastIP(
int
$lastip
)
|
|
Sets last login IP.
Sets last login IP.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lastip: |
Last login IP. |
API Tags:
Information Tags:
void setLastLogin(
int
$lastlogin
)
|
|
Sets last login timestamp.
Sets last login timestamp.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lastlogin: |
Last login timestamp. |
API Tags:
Information Tags:
void setLastLogout(
int
$lastlogout
)
|
|
Sets last logout timestamp.
Sets last logout timestamp.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lastlogout: |
Last logout timestamp. |
API Tags:
Information Tags:
void setLevel(
int
$level
)
|
|
Sets experience level.
Sets experience level.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$level: |
Experience level. |
API Tags:
Information Tags:
void setLookAddons(
int
$lookaddons
)
|
|
Sets addons.
Sets addons.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setLookBody(
int
$lookbody
)
|
|
Sets body color.
Sets body color.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lookbody: |
Body color. |
API Tags:
Information Tags:
void setLookFeet(
int
$lookfeet
)
|
|
Sets boots color.
Sets boots color.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lookfeet: |
Boots color. |
API Tags:
Information Tags:
void setLookHead(
int
$lookhead
)
|
|
Sets hair color.
Sets hair color.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$lookhead: |
Hair color. |
API Tags:
Information Tags:
void setLookLegs(
int
$looklegs
)
|
|
Sets legs color.
Sets legs color.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$looklegs: |
Legs color. |
API Tags:
Information Tags:
void setLookType(
int
$looktype
)
|
|
Sets outfit.
Sets outfit.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setLossExperience(
int
$loss_experience
)
|
|
Sets percentage of experience lost after dead.
Sets percentage of experience lost after dead.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$loss_experience: |
Percentage of experience lost after dead. |
API Tags:
Information Tags:
void setLossItems(
int
$loss_items
)
|
|
Sets percentage of items lost after dead.
Sets percentage of items lost after dead.
Parameters:
|
int |
$loss_items: |
Percentage of items lost after dead. |
API Tags:
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Since: | 0.1.4 |
void setLossMana(
int
$loss_mana
)
|
|
Sets percentage of used mana lost after dead.
Sets percentage of used mana lost after dead.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$loss_mana: |
Percentage of used mana lost after dead. |
API Tags:
Information Tags:
void setLossSkills(
int
$loss_skills
)
|
|
Sets percentage of skills lost after dead.
Sets percentage of skills lost after dead.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$loss_skills: |
Percentage of skills lost after dead. |
API Tags:
Information Tags:
void setMagLevel(
int
$maglevel
)
|
|
Sets magic level.
Sets magic level.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$maglevel: |
Magic level. |
API Tags:
Information Tags:
void setMana(
int
$mana
)
|
|
Sets current mana.
Sets current mana.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setManaMax(
int
$manamax
)
|
|
Sets maximum mana.
Sets maximum mana.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$manamax: |
Maximum mana. |
API Tags:
Information Tags:
void setManaSpent(
int
$manaspent
)
|
|
Sets mana spent.
Sets mana spent.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$manaspent: |
Mana spent. |
API Tags:
Information Tags:
void setName(
string
$name
)
|
|
Sets players's name.
Sets players's name.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setPosX(
int
$posx
)
|
|
Sets X map coordinate.
Sets X map coordinate.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$posx: |
X map coordinate. |
API Tags:
Information Tags:
void setPosY(
int
$posy
)
|
|
Sets Y map coordinate.
Sets Y map coordinate.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$posy: |
Y map coordinate. |
API Tags:
Information Tags:
void setPosZ(
int
$posz
)
|
|
Sets Z map coordinate.
Sets Z map coordinate.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$posz: |
Z map coordinate. |
API Tags:
Information Tags:
void setPremiumEnd(
int
$premend
)
|
|
Sets player's Premium Account expiration timestamp.
Sets player's Premium Account expiration timestamp.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$premend: |
PACC expiration timestamp. |
API Tags:
| Deprecated: | 0.1.5 Use OTS_Account->setPremiumEnd(). |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Since: | 0.0.3 |
Assigns guild rank.
Assigns guild rank.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
OTS_GuildRank|null |
$guildRank: |
Guild rank (null to clear assign). |
API Tags:
Information Tags:
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If passed $guildRank parameter is not loaded. |
void setRankId(
int
$rank_id
)
|
|
Parameters:
|
int |
$rank_id: |
Guild rank ID. |
API Tags:
| Deprecated: | 0.0.4 Use setRank(). |
| Access: | public |
Information Tags:
Sets red skull flag.
Sets red skull flag.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
API Tags:
Information Tags:
void setRedSkullTime(
int
$redskulltime
)
|
|
Sets red skulled time remained.
Sets red skulled time remained.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$redskulltime: |
Red skulled time remained. |
API Tags:
Information Tags:
void setSave(
[int
$save = 1]
)
|
|
Sets save flag.
Sets save flag.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$save: |
Deprecated, unused, optional. |
API Tags:
Information Tags:
| Version: | 0.0.7 |
| Version: | 0.0.1 |
Sets player gender.
Sets player gender.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setSkill(
int
$skill, int
$value
)
|
|
Sets skill value.
Sets skill value.
Parameters:
|
int |
$skill: |
Skill ID. |
|
int |
$value: |
Skill value. |
API Tags:
Information Tags:
| Version: | 0.0.2 |
| Version: | 0.0.1 |
| Since: | 0.0.2 |
void setSkillTries(
int
$skill, int
$tries
)
|
|
Sets skill's tries for next level.
Sets skill's tries for next level.
Parameters:
|
int |
$skill: |
Skill ID. |
|
int |
$tries: |
Skill tries. |
API Tags:
Information Tags:
| Version: | 0.0.2 |
| Version: | 0.0.1 |
| Since: | 0.0.2 |
void setSlot(
int
$slot, [OTS_Item
$item = null], [int
$pid = 0]
)
|
|
Sets slot content.
Sets slot content.
Parameters:
|
int |
$slot: |
Slot to save items. |
|
OTS_Item |
$item: |
Item (can be a container with content) for given slot. Leave this parameter blank to clear slot. |
|
int |
$pid: |
Deprecated, not used anymore. |
API Tags:
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
void setSoul(
int
$soul
)
|
|
Sets soul points.
Sets soul points.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setStamina(
int
$stamina
)
|
|
Sets stamina time left.
Sets stamina time left.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$stamina: |
Miliseconds of stamina. |
API Tags:
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Since: | 0.1.6 |
void setStorage(
int
$key, int
$value
)
|
|
Sets value of storage record.
Sets value of storage record.
Parameters:
|
int |
$key: |
Storage key. |
|
int |
$value: |
Stored value. |
API Tags:
Information Tags:
| Version: | 0.1.2 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If player is not loaded. |
| Since: | 0.1.2 |
| Throws: | PDOException On PDO operation error. |
void setTownId(
int
$town_id
)
|
|
Sets residence town's ID.
Sets residence town's ID.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$town_id: |
Residence town's ID. |
API Tags:
Information Tags:
void setVocation(
int
$vocation
)
|
|
Sets player proffesion.
Sets player proffesion.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$vocation: |
Player proffesion. |
API Tags:
Information Tags:
API Tags:
| Deprecated: | 0.1.5 Use OTS_PlayerBan class. |
| Access: | public |
Information Tags:
| Version: | 0.1.5 |
| Version: | 0.0.1 |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Unsets red skull flag.
Unsets red skull flag.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
API Tags:
Information Tags:
Unsets save flag.
Unsets save flag.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
API Tags:
Information Tags:
| Version: | 0.0.7 |
| Version: | 0.0.1 |
mixed __get(
string
$name
)
|
|
Magic PHP5 method.
Magic PHP5 method.
Parameters:
|
string |
$name: |
Property name. |
API Tags:
| Return: | Property value. |
| Access: | public |
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | OutOfBoundsException For non-supported properties. |
| Throws: | E_OTS_NotLoaded When player is not loaded. |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.1.0 |
void __set(
string
$name, mixed
$value
)
|
|
Magic PHP5 method.
Magic PHP5 method.
Parameters:
|
string |
$name: |
Property name. |
|
mixed |
$value: |
Property value. |
API Tags:
Information Tags:
| Version: | 0.1.6 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded When passing object value which represents not-initialised instance. |
| Since: | 0.1.0 |
| Throws: | OutOfBoundsException For non-supported properties. |
Magic PHP5 method.
Magic PHP5 method.
Allows object serialisation.
API Tags:
| Return: | List of properties that should be saved. |
| Access: | public |
Information Tags:
| Version: | 0.0.4 |
| Version: | 0.0.1 |
| Since: | 0.0.4 |
Redefinition of:
- OTS_Base_DAO::__sleep()
- Magic PHP5 method.
Returns string representation of object.
Returns string representation of object.
If any display driver is currently loaded then it uses it's method. Else it returns character name.
API Tags:
| Return: | String representation of object. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.0.1 |
| Since: | 0.1.0 |