com.planet_ink.coffee_mud.core.interfaces
Interface ShopKeeper

All Superinterfaces:
Behavable, java.lang.Cloneable, CMModifiable, CMObject, java.lang.Comparable<CMObject>, Economics, Environmental, MsgListener, StatsAffecting, Tickable
All Known Subinterfaces:
Auctioneer, Banker, PostOffice
All Known Implementing Classes:
GenAuctioneer, GenBanker, GenPostman, GenShopkeeper, Merchant, StdAuctioneer, StdBanker, StdPostman, StdShopKeeper

public interface ShopKeeper
extends Environmental, Economics

An interface for objects capable of being a shopkeeper, usually a MOB or an Ability.


Nested Class Summary
static class ShopKeeper.ShopPrice
          This class represents a given price for a given item in the shopkeepers inventory.
 
Field Summary
static int DEAL_ALCHEMIST
          shopkeeper type constant, means they buy potions
static int DEAL_ANYTECHNOLOGY
          shopkeeper type constant, means they buy electronics items
static int DEAL_ANYTHING
          shopkeeper type constant, means they buy anything
static int DEAL_ARMOR
          shopkeeper type constant, means they buy armor
static int DEAL_AUCTIONEER
          shopkeeper type constant, means they handle auctions, and implement the Auctioneer interface
static int DEAL_BANKER
          shopkeeper type constant, means they are a banker for players, and implement the Banker interface
static int DEAL_BUTCHER
          shopkeeper type constant, means they buy and sell raw meats
static int DEAL_CASTER
          shopkeeper type constant, means they cast spells they sell on players
static int DEAL_CLANBANKER
          shopkeeper type constant, means they are a banker for clans, and implement the Banker interface
static int DEAL_CLANDSELLER
          shopkeeper type constant, means they buy and sell property in their area to clans
static int DEAL_CLANPOSTMAN
          shopkeeper type constant, means they handle mail for clans, and implement the Postman interface
static int DEAL_CSHIPSELLER
          shopkeeper type constant, means they buy and sell SpaceShip areas to clans
static java.lang.String[] DEAL_DESCS
          A list of strings describing the DEAL_* constants, in their numeric value order.
static int DEAL_FOODSELLER
          shopkeeper type constant, means they buy and sell raw foodstuff
static int DEAL_GENERAL
          shopkeeper type constant, means they buy items not covered by other constants
static int DEAL_GROWER
          shopkeeper type constant, means they buy and sell raw non-meat foodstuffs
static int DEAL_HIDESELLER
          shopkeeper type constant, means they buy raw leathers and hides
static int DEAL_INNKEEPER
          shopkeeper type constant, means they sell InnKeys
static int DEAL_INVENTORYONLY
          shopkeeper type constant, means they buy only what they are told to sell
static int DEAL_JEWELLER
          shopkeeper type constant, means they buy jewelry
static int DEAL_LANDSELLER
          shopkeeper type constant, means they buy and sell property in their area to players
static int DEAL_LEATHER
          shopkeeper type constant, means they buy leather stuff
static int DEAL_LUMBERER
          shopkeeper type constant, means they buy raw lumber
static int DEAL_MAGIC
          shopkeeper type constant, means they buy magic items
static int DEAL_METALSMITH
          shopkeeper type constant, means they buy raw metals
static int DEAL_PETS
          shopkeeper type constant, means they buy pets
static int DEAL_POSTMAN
          shopkeeper type constant, means they handle mail for players, and implement the Postman interface
static int DEAL_SHIPSELLER
          shopkeeper type constant, means they buy and sell SpaceShip areas to players
static int DEAL_SLAVES
          shopkeeper type constant, means they buy and sell intelligent mobs as slaves
static int DEAL_STONEYARDER
          shopkeeper type constant, means they buy raw stones
static int DEAL_TRAINER
          shopkeeper type constant, means they train players in skills they sell
static int DEAL_WEAPONS
          shopkeeper type constant, means they buy weapons
 
Method Summary
 boolean doISellThis(Environmental thisThang)
          Returns whether this ShopKeeper deals in the type of item passed in.
 CoffeeShop getShop()
          the CoffeeShop method to access the shopkeepers store of goods
 void setWhatIsSold(int newSellCode)
          Sets the ShopKeeper DEAL_* constant describing what is sold or bought by this ShopKeeper
 java.lang.String storeKeeperString()
          Based on the value of this ShopKeepers whatIsSold() method, this will return a displayable string describing that type.
 int whatIsSold()
          Returns the ShopKeeper DEAL_* constant describing what is sold or bought by this ShopKeeper
 
Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Economics
budget, devalueRate, finalBudget, finalDevalueRate, finalIgnoreMask, finalInvResetRate, finalItemPricingAdjustments, finalPrejudiceFactors, ignoreMask, invResetRate, itemPricingAdjustments, prejudiceFactors, setBudget, setDevalueRate, setIgnoreMask, setInvResetRate, setItemPricingAdjustments, setPrejudiceFactors
 

Field Detail

DEAL_ANYTHING

static final int DEAL_ANYTHING
shopkeeper type constant, means they buy anything

See Also:
Constant Field Values

DEAL_GENERAL

static final int DEAL_GENERAL
shopkeeper type constant, means they buy items not covered by other constants

See Also:
Constant Field Values

DEAL_ARMOR

static final int DEAL_ARMOR
shopkeeper type constant, means they buy armor

See Also:
Constant Field Values

DEAL_MAGIC

static final int DEAL_MAGIC
shopkeeper type constant, means they buy magic items

See Also:
Constant Field Values

DEAL_WEAPONS

static final int DEAL_WEAPONS
shopkeeper type constant, means they buy weapons

See Also:
Constant Field Values

DEAL_PETS

static final int DEAL_PETS
shopkeeper type constant, means they buy pets

See Also:
Constant Field Values

DEAL_LEATHER

static final int DEAL_LEATHER
shopkeeper type constant, means they buy leather stuff

See Also:
Constant Field Values

DEAL_INVENTORYONLY

static final int DEAL_INVENTORYONLY
shopkeeper type constant, means they buy only what they are told to sell

See Also:
Constant Field Values

DEAL_TRAINER

static final int DEAL_TRAINER
shopkeeper type constant, means they train players in skills they sell

See Also:
Constant Field Values

DEAL_CASTER

static final int DEAL_CASTER
shopkeeper type constant, means they cast spells they sell on players

See Also:
Constant Field Values

DEAL_JEWELLER

static final int DEAL_JEWELLER
shopkeeper type constant, means they buy jewelry

See Also:
Constant Field Values

DEAL_ALCHEMIST

static final int DEAL_ALCHEMIST
shopkeeper type constant, means they buy potions

See Also:
Constant Field Values

DEAL_BANKER

static final int DEAL_BANKER
shopkeeper type constant, means they are a banker for players, and implement the Banker interface

See Also:
Constant Field Values

DEAL_LANDSELLER

static final int DEAL_LANDSELLER
shopkeeper type constant, means they buy and sell property in their area to players

See Also:
Constant Field Values

DEAL_ANYTECHNOLOGY

static final int DEAL_ANYTECHNOLOGY
shopkeeper type constant, means they buy electronics items

See Also:
Constant Field Values

DEAL_CLANDSELLER

static final int DEAL_CLANDSELLER
shopkeeper type constant, means they buy and sell property in their area to clans

See Also:
Constant Field Values

DEAL_FOODSELLER

static final int DEAL_FOODSELLER
shopkeeper type constant, means they buy and sell raw foodstuff

See Also:
Constant Field Values

DEAL_BUTCHER

static final int DEAL_BUTCHER
shopkeeper type constant, means they buy and sell raw meats

See Also:
Constant Field Values

DEAL_GROWER

static final int DEAL_GROWER
shopkeeper type constant, means they buy and sell raw non-meat foodstuffs

See Also:
Constant Field Values

DEAL_HIDESELLER

static final int DEAL_HIDESELLER
shopkeeper type constant, means they buy raw leathers and hides

See Also:
Constant Field Values

DEAL_LUMBERER

static final int DEAL_LUMBERER
shopkeeper type constant, means they buy raw lumber

See Also:
Constant Field Values

DEAL_METALSMITH

static final int DEAL_METALSMITH
shopkeeper type constant, means they buy raw metals

See Also:
Constant Field Values

DEAL_STONEYARDER

static final int DEAL_STONEYARDER
shopkeeper type constant, means they buy raw stones

See Also:
Constant Field Values

DEAL_CLANBANKER

static final int DEAL_CLANBANKER
shopkeeper type constant, means they are a banker for clans, and implement the Banker interface

See Also:
Constant Field Values

DEAL_INNKEEPER

static final int DEAL_INNKEEPER
shopkeeper type constant, means they sell InnKeys

See Also:
Constant Field Values

DEAL_SHIPSELLER

static final int DEAL_SHIPSELLER
shopkeeper type constant, means they buy and sell SpaceShip areas to players

See Also:
Constant Field Values

DEAL_CSHIPSELLER

static final int DEAL_CSHIPSELLER
shopkeeper type constant, means they buy and sell SpaceShip areas to clans

See Also:
Constant Field Values

DEAL_SLAVES

static final int DEAL_SLAVES
shopkeeper type constant, means they buy and sell intelligent mobs as slaves

See Also:
Constant Field Values

DEAL_POSTMAN

static final int DEAL_POSTMAN
shopkeeper type constant, means they handle mail for players, and implement the Postman interface

See Also:
Constant Field Values

DEAL_CLANPOSTMAN

static final int DEAL_CLANPOSTMAN
shopkeeper type constant, means they handle mail for clans, and implement the Postman interface

See Also:
Constant Field Values

DEAL_AUCTIONEER

static final int DEAL_AUCTIONEER
shopkeeper type constant, means they handle auctions, and implement the Auctioneer interface

See Also:
Constant Field Values

DEAL_DESCS

static final java.lang.String[] DEAL_DESCS
A list of strings describing the DEAL_* constants, in their numeric value order.

Method Detail

getShop

CoffeeShop getShop()
the CoffeeShop method to access the shopkeepers store of goods

Returns:
the CoffeeShop object
See Also:
CoffeeShop

whatIsSold

int whatIsSold()
Returns the ShopKeeper DEAL_* constant describing what is sold or bought by this ShopKeeper

Returns:
the dealer constant
See Also:
ShopKeeper

setWhatIsSold

void setWhatIsSold(int newSellCode)
Sets the ShopKeeper DEAL_* constant describing what is sold or bought by this ShopKeeper

Parameters:
newSellCode - the dealer type constant
See Also:
ShopKeeper

storeKeeperString

java.lang.String storeKeeperString()
Based on the value of this ShopKeepers whatIsSold() method, this will return a displayable string describing that type.

Returns:
a description of the whatIsSold() code
See Also:
whatIsSold()

doISellThis

boolean doISellThis(Environmental thisThang)
Returns whether this ShopKeeper deals in the type of item passed in. The determination is based on the whatIsSold() code.

Parameters:
thisThang - the item to determine if the shopkeeper deals in
Returns:
whether the shopkeeper deals in the type of item passed in
See Also:
whatIsSold()