Upbge 0.3 text object change value

I got an error tyring to change text object HUD text value ?

if “score” in playerObject :
scoreObject.text = playerObject[“score”]

You should try:

if “score” in playerObject :
    scoreObject["Text"] = str(playerObject[“score”])
1 Like