Overview

Namespaces

  • aliuly
    • common
      • selectors
    • loader
  • xPaw

Classes

  • ArmorItems
  • BasicCli
  • BasicHelp
  • BasicPlugin
  • ChatSession
  • Cmd
  • CmdSelector
  • ExpandVars
  • FastTransfer
  • FileUtils
  • FreezeSession
  • GetMotd
  • GetMotdAsyncTask
  • InvisibleSession
  • InvUtils
  • ItemName
  • mc
  • mc2
  • MoneyAPI
  • MPMU
  • Npc
  • PermUtils
  • PluginAsyncTask
  • PluginCallbackTask
  • PMScript
  • QueryAsyncTask
  • Rcon
  • RconTask
  • Session
  • ShieldSession
  • ShoppingCart
  • SignUtils
  • SkinUtils
  • SpySession
  • SubCommandMap
  • TPUtils
  • Overview
  • Namespace
  • Class

Class MoneyAPI

This class allows you to use a number of miscellaneous Economy plugins.

Abstract
Namespace: aliuly\common
Located at aliuly/common/MoneyAPI.php
Methods summary
public static
# noMoney( pocketmine\plugin\PluginBase $plugin, LogLevel $level = aliuly\common\LogLevel::WARNING )

Show a warning when the money API is missing

Show a warning when the money API is missing

Parameters

$plugin
  • current plugin
$level
  • optional log level
public static
# foundMoney( pocketmine\plugin\PluginBase $plugin, pocketmine\plugin\PluginBase $api, LogLevel $level = aliuly\common\LogLevel::INFO )

Show a notice when the money API is found

Show a notice when the money API is found

Parameters

$plugin
  • current plugin
$api
  • found plugin
$level
  • optional log level
public static null|Plugin
# moneyPlugin( var $obj )

Find a supported money plugin

Find a supported money plugin

Parameters

$obj
  • Server or Plugin object

Returns

null|Plugin
public static boolean
# grantMoney( Plugin $api, str|pocketmine\IPlayer $p, integer $money )

Gives money to a player.

Gives money to a player.

Parameters

$api
Economy plugin (from moneyPlugin)
$p
Player to pay
$money
Amount of money to play (can be negative)

Returns

boolean
public static integer
# getMoney( Plugin $api, str|pocketmine\IPlayer $player )

Gets player balance

Gets player balance

Parameters

$api
Economy plugin (from moneyPlugin)
$player
Player to lookup

Returns

integer
API documentation generated by ApiGen