Esempio n. 1
0
 def get_string_characters(self, user=None):
     characters = '\n                '.join(
         f'***{c.name}***' + (' _(Active Character)_' if str(c.id) ==
                              user.active_character else '')
         for c in Character.filter(
             id__in=[ObjectId(id) for id in self.characters]) if c)
     return f'\n\n            _Characters:_\n                {characters}'
Esempio n. 2
0
 def get_string_characters(self):
     scenes = list(Scene.get_by_scenario(scenario=self, page_num=0))
     characters = [
         Character.filter(id__in=[ObjectId(id) for id in s.characters])
         for s in scenes
     ]
     characters = '***\n                ***'.join(c.name for c in characters
                                                  if c)
     return f'\n            _Characters:_\n                ***{characters}***'
Esempio n. 3
0
 def get_short_string_characters(self, user=None):
     characters = ', '.join(c.name for c in Character.filter(id__in=[ObjectId(id) for id in self.characters], archived=False) if c)
     return f'\n...({characters})'