public class BattleEngine extends Object
| Modifier and Type | Field and Description |
|---|---|
static BattleHandler |
battleHandler |
static DeathHandler |
deathHandler |
static InputHandler |
inputHandler |
static HashMap<String,Item> |
itemList
An HashMap that can be used to store items, using an id (it's recommended
to use namespace:item_id for this).
|
static LocalizationHandler |
localizationHandler |
static SoundHandler |
soundHandler |
| Constructor and Description |
|---|
BattleEngine() |
| Modifier and Type | Method and Description |
|---|---|
static void |
end()
Ends the engine's operation
|
static Object[] |
getEngineInfo()
Returns some info about the Engine in an Object[], in the following
format.
|
static Object[] |
getJVMInfo()
Returns some info about the JVM in an Object[], in the following format.
|
static void |
init() |
static void |
init(BattleHandler bHandler,
InputHandler iHandler,
LocalizationHandler locHandler,
SoundHandler sHandler,
DeathHandler dHandler)
Used to change handlers to custom ones (leave any null to use default
one/one's you already set)
|
static void |
playSound(File sound,
int repeatTime) |
static void |
playSound(InputStream sound,
int repeatTime) |
static void |
playSound(URI sound,
int repeatTime) |
static void |
startBattle(boolean canRun,
Enemy[] en) |
static void |
switchLang(String key) |
public static BattleHandler battleHandler
public static InputHandler inputHandler
public static LocalizationHandler localizationHandler
public static SoundHandler soundHandler
public static DeathHandler deathHandler
public static void init()
public static void end()
public static void init(BattleHandler bHandler, InputHandler iHandler, LocalizationHandler locHandler, SoundHandler sHandler, DeathHandler dHandler)
bHandler - iHandler - locHandler - sHandler - dHandler - public static void switchLang(String key)
public static void startBattle(boolean canRun,
Enemy[] en)
public static void playSound(URI sound, int repeatTime)
public static void playSound(File sound, int repeatTime)
public static void playSound(InputStream sound, int repeatTime)
public static Object[] getJVMInfo()
public static Object[] getEngineInfo()
Copyright © 2022. All rights reserved.