-
Notifications
You must be signed in to change notification settings - Fork 1
API documentation
This is documentation of fields and method in our program. BE CAREFUL ABOUT STATIC AND NON-STATIC FIELD AND METHOD.
public static void waitingTime(int t)
makes the Program stops for a while for amount
t
. t = 1000 is 1 second.
Returns nothing
public static int randomNum(int a, int b)
returns a random number greater than equal to a and less than equal to b thus inclusive.
Returns
int x
that a ≤ x ≤ b
public static boolean percentProb(int a)
input a% and results in
true
orfalse
based on the probability. Iftrue
, within the probability. Iffalse
, outside the probability.
Returns
boolean
type :true
orfalse
public static char scanChar()
scanning a character typed from keyboard
Returns
char
type
public static String scanString()
scanning a
String
value from keyboard
Returns
String
type
public static int scanInt()
scanning a
int
value from keyboard
Returns
int
type
public static void stop()
just Program needed for scanner. NOT ACTUALLY USED
Returns nothing
static String name; //Character name
static String classType; //Character class
static int lv; //level
static int age; // age
static int str; //strength
static int wis; //wisdom
static int agi; //agility
static int hpMax; //maximum HP
static int hpNow; //current HP
static int mpMax; //maximum MP
static int mpNow; //current MP
static int atk; //attack damage, this must be calulated in regard to other effects(weapon damage etc.)
static int coin; //money
static int currentPart; //current part in the story
static String currentState; //tells what the charcter is doing idle, fighting, shoping etc.
public static void makeStats(String nameChoice, String classTypeChoice, int lvChoice, int ageChoice, int strChoice, int wisChoice, int agiChoice, int hpMaxChoice, int hpNowChoice, int mpMaxChoice, int mpNowChoice, int atkChoice, int coinChoice)
declaring field, creating a character
returns nothing
public static void statPage()
printing out stats of the character
Nothing