|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.planet_ink.coffee_mud.Items.interfaces.RawMaterial.CODES
public static class RawMaterial.CODES
Global resource/raw material code data collector
Constructor Summary | |
---|---|
RawMaterial.CODES()
Constructs a CODES object for the current thread. |
Method Summary | |
---|---|
void |
add(int material,
java.lang.String name,
java.lang.String smell,
int value,
int frequ,
int hardness,
int bouancy,
boolean fish,
boolean berry,
boolean woody,
java.lang.String abilityID)
Adds a new resource to the official CODES object. |
static int[] |
ALL_SBN()
Returns an array of the numeric codes for all resources |
int[] |
all()
Returns an array of the numeric codes for all resources |
static int[] |
ALL()
Returns an array of the numeric codes for all resources |
int[] |
berries()
Returns an array of the numeric codes for the berry resources |
static int[] |
BERRIES()
Returns an array of the numeric codes for the berry resources |
int |
bouancy(int code)
Returns the bouancy of the resource, from 0-20000 |
static int |
BOUANCY(int code)
Returns the bouancy of the resource, from 0-20000 |
static RawMaterial.CODES |
c(byte c)
Returns the CODES object for the given thread group code, or null |
static java.util.List<java.lang.Integer> |
COMPOSE_RESOURCES(int mat)
Search and compose a complete list of all resources of the given material |
java.lang.String |
effect(int code)
Returns the description of the code smell |
static java.lang.String |
EFFECT(int code)
Returns the description of the code smell |
static Ability[] |
EFFECTA(int code)
Parses, if necessary, EFFECT strings into ability objects, complete with parms, ready for copying. |
static java.lang.String[] |
EFFECTS()
Returns the smells of the various resources |
static int |
FIND_CaseSensitive(java.lang.String rsc)
Returns the code of the names resource, or -1 |
static int |
FIND_IgnoreCase(java.lang.String rsc)
Returns the code of the names resource, or -1 |
static int |
FIND_StartsWith(java.lang.String rsc)
Returns the code of the names resource, or -1 |
int[] |
fishes()
Returns an array of the numeric codes for the fishy resources |
static int[] |
FISHES()
Returns an array of the numeric codes for the fishy resources |
int |
frequency(int code)
Returns the frequency of the resource, or how rare it is. |
static int |
FREQUENCY(int code)
Returns the frequency of the resource, or how rare it is. |
int |
get(int x)
Returns an the numeric codes of the indexes resource code |
static int |
GET(int x)
Returns an the numeric codes of the indexes resource code |
PairList<java.lang.Integer,java.lang.Double> |
getValueSortedBucket(int material)
For the given material, returns a value-sorted list of all resources that are made of that material and their values. |
int |
hardness(int code)
Returns the hardness of the resource, from 1-10 |
static int |
HARDNESS(int code)
Returns the hardness of the resource, from 1-10 |
static RawMaterial.CODES |
instance()
Returns the CODES object for the current thread group, or creates one. |
static boolean |
IS_VALID(int code)
Returns whether the code is valid |
static int |
MOST_FREQUENT(int material)
Returns the resource code of the most frequently found resource of the given material mask |
int |
mostFrequent(int material)
Returns the resource code of the most frequently found resource of the given material mask |
java.lang.String |
name(int code)
Returns the name of the code |
static java.lang.String |
NAME(int code)
Returns the name of the code |
java.lang.String[] |
names()
Returns the names of the various resources |
static java.lang.String[] |
NAMES()
Returns the names of the various resources |
void |
replace(int resourceCode,
int material,
java.lang.String name,
java.lang.String smell,
int value,
int frequ,
int hardness,
int bouancy,
boolean fish,
boolean berry,
boolean woody,
java.lang.String abilityID)
Replaces a resource of the given code with new data |
static void |
reset()
Destroys and recreates the CODES object for the current thread group |
java.lang.String |
smell(int code)
Returns the description of the code smell |
static java.lang.String |
SMELL(int code)
Returns the description of the code smell |
static java.lang.String[] |
SMELLS()
Returns the smells of the various resources |
int |
total()
Returns total number of codes 0 - this-1 |
static int |
TOTAL()
Returns total number of codes 0 - this-1 |
int |
value(int code)
Returns the value of the resource |
static int |
VALUE(int code)
Returns the value of the resource |
int[] |
woodies()
Returns an array of the numeric codes for the wood-choppy resources |
static int[] |
WOODIES()
Returns an array of the numeric codes for the wood-choppy resources |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RawMaterial.CODES()
Method Detail |
---|
public static RawMaterial.CODES c(byte c)
c
- the thread group code
public static RawMaterial.CODES instance()
public static void reset()
public static int[] BERRIES()
public int[] berries()
public static int[] WOODIES()
public int[] woodies()
public static int[] FISHES()
public int[] fishes()
public static int TOTAL()
public int total()
public static int[] ALL_SBN()
public static int[] ALL()
public int[] all()
public static int GET(int x)
x
- the indexed resource code
public int get(int x)
x
- the indexed resource code
public static int FIND_CaseSensitive(java.lang.String rsc)
rsc
- the names resource
public static int FIND_IgnoreCase(java.lang.String rsc)
rsc
- the names resource
public static int FIND_StartsWith(java.lang.String rsc)
rsc
- the names resource
public static boolean IS_VALID(int code)
code
- the resource code
public static java.lang.String[] NAMES()
public java.lang.String[] names()
public static java.lang.String NAME(int code)
code
- the code
public java.lang.String name(int code)
code
- the code
public static java.lang.String[] SMELLS()
public static java.lang.String SMELL(int code)
code
- the code smell
public java.lang.String smell(int code)
code
- the code smell
public static java.lang.String[] EFFECTS()
public static java.lang.String EFFECT(int code)
code
- the code smell
public java.lang.String effect(int code)
code
- the code smell
public static int VALUE(int code)
code
- the resource code
public int value(int code)
code
- the resource code
public static int FREQUENCY(int code)
code
- the resource code
public int frequency(int code)
code
- the resource code
public static int MOST_FREQUENT(int material)
material
- the material mask
public int mostFrequent(int material)
material
- the material mask
public static int HARDNESS(int code)
code
- the resource code
public int hardness(int code)
code
- the resource code
public static int BOUANCY(int code)
code
- the resource code
public int bouancy(int code)
code
- the resource code
public static java.util.List<java.lang.Integer> COMPOSE_RESOURCES(int mat)
mat
- the resource code
public static Ability[] EFFECTA(int code)
code
- the material/resource code
public PairList<java.lang.Integer,java.lang.Double> getValueSortedBucket(int material)
material
- the material type to get resources of
public void add(int material, java.lang.String name, java.lang.String smell, int value, int frequ, int hardness, int bouancy, boolean fish, boolean berry, boolean woody, java.lang.String abilityID)
material
- the material type of the new resourcename
- the name of the resourcesmell
- the smell of the resourcevalue
- the value of the resource in base currencyfrequ
- the frequency of the resource 0-10hardness
- the hardness of the resource 0-10bouancy
- the bouancy of the resource 0-10000fish
- true if its a fishy-typeberry
- true if its a berry typewoody
- true if its a wood-choppy typeabilityID
- effects listpublic void replace(int resourceCode, int material, java.lang.String name, java.lang.String smell, int value, int frequ, int hardness, int bouancy, boolean fish, boolean berry, boolean woody, java.lang.String abilityID)
resourceCode
- the old resource codematerial
- the material type of the new resourcename
- the name of the resourcesmell
- the smell of the resourcevalue
- the value of the resource in base currencyfrequ
- the frequency of the resource 0-10hardness
- the hardness of the resource 0-10bouancy
- the bouancy of the resource 0-10000fish
- true if its a fishy-typeberry
- true if its a berry typewoody
- true if its a wood-choppy typeabilityID
- effects list
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |