if strengh1 <=0:
death1=True
else:
death1 = False
if strengh2 <=0:
death2=True
else:
death2=False
def output(character):
if death character == False:
print
print('Character', character ,' strengh is now %s' % strengh1)
print('Character ', character ,' skill is now %s' % skill1)
else:
print
print('Character ', character ,' is dead')
output(1)
output(2)
Hi guys I am currently doing a bit of a project. here is part of my very last lines of code. There are two characters and i want to be able to use a function. I am almost fully self taught and i havnt been coding very long at all so there might be basic errors or i might be doing something that just cant work, but how can i change the name of the "death" variable in the function using what is in the function call? So for example output(10 needs to change death to death1? is this possible. Also i need to be able to print this in one solid output as Character (then the function parameter) is now dead