0

I have a livewires.games.Text object called score which I am trying to get the value out of. I have tried converting it to a doing scores = str(self.scores) and even a for loop:

scores = str(self.score)
for item in scores:
    print(item)

All I am getting though is <livewires.games.Text object at 0x1017aca58>

I am trying to turn the score into an int() so that I can use that to base my leveling up in a game I am working on.

Has anyone ever worked with livewires before is there a way to turn the <livewires.games.Text object at 0x1017aca58> into an int()?

DarthOpto
  • 1,640
  • 7
  • 32
  • 59

1 Answers1

0

All I had to do was:

        score = self.score.value
        if score % 100 == 0:
            self.level += 1
            games.screen.add(self.level_msg)
DarthOpto
  • 1,640
  • 7
  • 32
  • 59