def alignmentText(align): text = alignControl.name(align) # Get text object obj = objectControl.getFromScene(ALIGNMENT_TEXT_OBJECT_NAME, 'info') # Set that object's text obj['Text'] = text
def statsText(unit): # <unitName> # <alignment> # hp: <hp>/<health> # sp: <sp>/<spirit> # MV_ICON x<mv> ACT_ICON x<act text = unit['name'] + '\n' text += alignControl.name(unit['align']) + '\n\n' text += 'hp: ' + str(unit['hp']) + '/' + str(unit['health']) + '\n' text += 'sp: ' + str(unit['sp']) + '/' + str(unit['spirit']) + '\n' text += ' x' + str(unit['mv']) + ' x' + str(unit['act']) obj = objectControl.getFromScene(TEXT_OBJECT_NAME, 'basicInfo') obj['Text'] = text