void meleeDefend(int aSt, int aA, int aP, int aD, int aI,int aSp,int aC/*, int AttackersLocation*/){
/// r is short cut to Random which is used a lot
Random r = new Random();
/// int below
/// fate is
int fate = 30;
/// Array of Entities stats. Defense Stats array
int[] dStats = { Strength, Agility, Perception, Dexterity,
Intelligence, Speed, Constitution };
///array of attackers stats. Attack Stats Array
int[] aStats = {aSt, aA, aP, aD, aI, aSp, aC};
/// loop will give fate out until fate has value or the loop ends
for(int i = 0; i==13; i=i+1){
/// int t is a random bonus given to stats. Maxumam points given is 30
int t = r.nextInt(Math.min(fate, 10)+1);
/// if statement is equal or less than 7| use Defense stats array
if(i <7){
dStats[i] = dStats[i] + t;
fate = fate - t;
}
if(i>=7){
dStats[i-7] = dStats[i] + t;
fate = fate - t;
}
}
/// NOTE TO SELF, Split this up in to private methods. It looks horrible.
///check to see if Agility
int temp = r.nextInt(100) +1;
if(temp >= 100 - dStats[1]){
//in the intrest of a test i will brute the code.
hpLower(aStats[0]);
}///should do direct attack
if(temp <= aStats[1]){}/// should do counter attack
else{}///do another check
alive();/// check to see if
}
void hpLower(int hp){
this.HP = this.HP - Math.min(0, hp);
}
boolean alive(){
if(HP < 1) Alive = false;
return Alive;
}
FMC Wrote:For some reason that reminds of me Clause from Linter (in the first FMA anime, not manga or brotherhood). She was... quite different.
Also, there's a manga about a girl dressing up as a guy to get into an all guys school to get together with the guy she loved, and it was about her exploits at the school to protect her identity and get the guy out of the 'funk' he was having. I forgot the name of the anime, though... though I wish I'd remember so I could check it out again...
FMC Wrote:I'm a chick, for one. xD
Users browsing this forum: No registered users