Ex.
Code: Select all
if charclass == "charclassplaceholder":
menu:
"Attack":
$ player_damage = renpy.random.randint(damagelow, damagehigh)
$ enemy_hp -= player_damage
r "You attack [enemy]! *[player_damage]*"
"([enemy] has [enemy_hp] HP.)"
"Rest":
$ player_hp = min(player_hp+15, player_max_hp)
r "That's a little better"
"Run":
$ fleechance = renpy.random.randint(1, 10)
if fleechance >= 5:
"You successfully ran away."
jump checkup
if fleechance <= 4:
"You failed to run."
"Spell Placeholder" if player_mana > 5:
$ player_damage = renpy.random.randint(magicdamagelow, magicdamagehigh)
$ player_mana -= 5
r "Wow such magics. *[player_damage]*"
"([enemy] has [enemy_hp] HP.)"
else:
menu:
"Attack":
$ player_damage = renpy.random.randint(damagelow, damagehigh)
$ enemy_hp -= player_damage
r "You attack [enemy]! *[player_damage]*"
"([enemy] has [enemy_hp] HP.)"
"Rest":
$ player_hp = min(player_hp+5, player_max_hp)
$ player_mana = min(player_mana+5, player_max_mana)
r "That's a little better"
"Run":
$ fleechance = renpy.random.randint(1, 10)
if fleechance >= 5:
"You successfully ran away."
jump checkup
if fleechance <= 4:
"You failed to run."