ucv / emag-hero

1 stars 0 forks source link

eMAG's Hero #1

Closed ucv closed 6 years ago

ucv commented 6 years ago

The story

Once upon a time there was a great hero, called Orderus, with some strengs and weaknesses, as all heroes have. After battling all kinds of monsters for more than a hundred years, Orderus now has the following stats:

Also, he possesses 2 skills:

Gameplay

As Orderus walks the ever-green forest of Emagia, he encounters some wild beasts, with the following properties:

You'll have to simulate a battle between Orderus and a wild beast, either at command line or using a web browser. On every battle, Orderus and the beast must be initialized with random properties, within their ranges. The first attack is done by the player with the higher speed. If both players have the same speed, then the attack is carried on by the player with the highest luck. After an attack, the players switch roles: the attacker now defends and the defender now attacks. The damage done by the attacker is calculated with the following formula:

Damage = Attacker strength -Defender defence

The damage is subtracted from the defender's health. An attacker can miss their hit and do no damage if the defender gets lucky that turn. Orderus' skill occurs randomly, based on their chances, so take them into account on each turn.

Game over

The game ends when one of the players remain without health or the number of turns reaches 20. The application must output the results each turn: what happens , which skills were used ( if any ), the damage done, defender's health left. If we have a winner before the maximum number of rounds is reached, he must be declared.

Rules

Emagia is a land where magic dose happen. Still, for this magic to work, you'll have to follow these rules:

ucv commented 6 years ago

Yes we are in beta