Package rs.kreme.ksbot.api.game
Class Statistics
- java.lang.Object
-
- rs.kreme.ksbot.api.game.Statistics
-
public class Statistics extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Statistics(rs.kreme.ksbot.api.KSContext ctx)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddecrement(java.lang.String key, long amount)Decrement a specific stat by amountjava.util.Map<java.lang.String,java.lang.Long>export()Export a flat key/value map for JSON serializationlongget(java.lang.String key)Retrieve a stat valuevoidincrement(java.lang.String key, long amount)Increment a specific stat by amountvoidreset()Reset all statisticsvoidset(java.lang.String key, long value)Set a specific stat to an exact value
-
-
-
Method Detail
-
increment
public void increment(java.lang.String key, long amount)Increment a specific stat by amount
-
decrement
public void decrement(java.lang.String key, long amount)Decrement a specific stat by amount
-
set
public void set(java.lang.String key, long value)Set a specific stat to an exact value
-
get
public long get(java.lang.String key)
Retrieve a stat value
-
export
public java.util.Map<java.lang.String,java.lang.Long> export()
Export a flat key/value map for JSON serialization
-
reset
public void reset()
Reset all statistics
-
-