예제 #1
0
 def toDict(self):
     repre = Entity.toDict(self)
     repre.update({
         'username': self.username,
     })
     # no need to send the password as it would not be transmitted
     return repre
예제 #2
0
 def toDict(self):
     repre = Entity.toDict(self)
     repre.update({
         'name': self.name,
         'hp': self.hp,
         'type_1': self.type_1,
         'type_2': self.type_2,
         'attack': self.attack,
         'defense': self.defense,
         'special_attack': self.special_attack,
         'special_defense': self.special_defense,
         'total': self.total,
         'speed': self.speed
     })
     return repre