def _create_player_logic_blocks(self, player: Player, **kwargs): """Create the game-wide logic blocks for this player. Args: player: The player object. **kwargs: Does nothing. Just here to allow this method to be called via an event handler. Note that this method is automatically added as a handler to the 'player_add_success' event. """ del kwargs player.logic_blocks = set() if 'logic_blocks' in self.machine.config: self._create_logic_blocks( config=self.machine.config['logic_blocks'], player=player)
def _create_player_logic_blocks(self, player: Player, **kwargs): """Create the game-wide logic blocks for this player. Args: player: The player object. **kwargs: Does nothing. Just here to allow this method to be called via an event handler. Note that this method is automatically added as a handler to the 'player_add_success' event. """ del kwargs player.logic_blocks = set() '''player_var: logic_blocks desc: A set which contains references to all the logic blocks which exist for this player. There's nothing useful in here for you, we just include it so you know what this player variable does. ''' if 'logic_blocks' in self.machine.config: self._create_logic_blocks( config=self.machine.config['logic_blocks'], player=player)