I'am making a box game. The user can choose out of three actions (kill, kick and fight). The computer can choose random out of three actions, it doesn't matter which one
Here is my whole code http://ift.tt/1C6l5Ii
//alle drie de boksers
bokser[0] = {
id:0,
name:"bokser1",
life:100,
kick:5,
fight:7,
kill:9
};
bokser[1] = {
id:1,
name:"bokser2",
life:100,
kick:7,
fight:10,
kill:4
};
bokser[2] = {
id:2,
name:"bokser3",
life:100,
kick:9,
fight:4,
kill:4
};
Here are the different actions where the user can choose, the computer can also choose between these actions but random. The actions the computer chooses, is -- of the life of the userchoice
Can anyone help me?
Aucun commentaire:
Enregistrer un commentaire