Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var slaying = true;
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- var bronsonHealth = 10;
- var samsonHealth = 10;
- var andreiHealth = 3;
- var rhyanHealth = 3;
- while (slaying){
- if(andreiAttackLands){
- console.log("-Andrei hit buttered-up Bronson for " + damageThisRound + " damage!");
- bronsonHealth -= damageThisRound;
- if (bronsonHealth > 0){
- console.log("-Bronson, glistening with butter, has " + bronsonHealth + " health left.");
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- }
- if (bronsonHealth <= 0){
- slaying = false;
- console.log("-Andrei managed to subdue Bronson before Rhyan could match Samson. Andrei wins!");
- if (samsonHealth > 9){
- console.log("-Samson still has all his health left. I thought you played Dark Souls, Rhyan!");
- }else{
- console.log("-Samson still has " + samsonHealth + " health left. Better luck next time, Rhyan.");
- }
- }else if(rhyanAttackLands){
- console.log("-Rhyan hit godly Samson for " + damageThisRound + " damage!");
- samsonHealth -= damageThisRound;
- if (samsonHealth > 0){
- console.log("-Samson, blessed by God, has " + samsonHealth + " health left.");
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- }else{
- slaying = false;
- console.log("-Rhyan managed to cut off Samson's hair and shrivel the demigod into an old man before Andrei could finish Bronson. Rhyan wins!");
- if (bronsonHealth > 9){
- console.log("-Bronson still has all his health left. You really do have terrible luck, Andrei!");
- }else{
- console.log("-Bronson still has " + bronsonHealth + " health left. Better luck next time, Andrei.");
- }
- }
- }else{
- console.log("-Samson hits Rhyan, damn!");
- rhyanHealth--;
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- if(rhyanHealth <= 0){
- slaying = false;
- console.log("-Samson has beaten Rhyan! Andrei wins!");
- }
- }
- }else{
- console.log("-Bronson hits Andrei, ouch!");
- andreiHealth--;
- if(andreiHealth > 0){
- console.log("-Andrei has " + andreiHealth + " tries left!");
- }
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- if(andreiHealth <= 0){
- slaying = false;
- console.log("-Bronson has kicked Andrei's ass! Rhyan wins!");
- }else if(rhyanAttackLands){
- console.log("-Rhyan hit godly Samson for " + damageThisRound + " damage!");
- samsonHealth -= damageThisRound;
- if (samsonHealth > 0){
- console.log("-Samson, blessed by God, has " + samsonHealth + " health left.");
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- }else{
- slaying = false;
- console.log("-Rhyan manages to cut off Samson's hair and shrivel the demigod into a frail man before Andrei can finish Bronson. Rhyan wins!");
- if (bronsonHealth > 9){
- console.log("-Bronson still has all his health left. You really do have terrible luck, Andrei!");
- }else{
- console.log("-Bronson still has " + bronsonHealth + " health left. Better luck next time, Andrei.");
- }
- }
- }else{
- console.log("-Samson hits Rhyan, damn!");
- rhyanHealth--;
- if(rhyanHealth > 0){
- console.log("-Rhyan has " + rhyanHealth + " tries left!");
- }
- var andreiAttackLands = Math.floor(Math.random() * 2);
- var rhyanAttackLands = Math.floor(Math.random() * 2);
- var damageThisRound = Math.floor((Math.random() * 8) + 1);
- if(rhyanHealth <= 0){
- slaying = false;
- console.log("-Samson has beaten Rhyan! Andrei wins!");
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement