Refactor battle & fix name for avatar_manager
This commit is contained in:
@@ -72,10 +72,10 @@ class AvatarData(BaseDatabaseData):
|
||||
has_taken_promotion_reward_list=[1,2,3,4,5,6],
|
||||
)
|
||||
|
||||
def ToBattleProto(self,index,session):
|
||||
def ToBattleProto(self,index,player):
|
||||
get_equipment = None
|
||||
if self.lightcone_id > 0:
|
||||
get_equipment = session.player.inventory_manager.get(self.lightcone_id)
|
||||
get_equipment = player.inventory_manager.get(self.lightcone_id)
|
||||
|
||||
return BattleAvatar(
|
||||
id=self.avatar_id,
|
||||
@@ -105,7 +105,7 @@ class AvatarData(BaseDatabaseData):
|
||||
)
|
||||
],
|
||||
relic_list = [
|
||||
session.player.inventory_manager.get(relic_id).RelicBattleProto()
|
||||
player.inventory_manager.get(relic_id).RelicBattleProto()
|
||||
for type, relic_id in self.relic_ids.items()
|
||||
if relic_id > 0
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user