class_docstr: Helper class for loading and extracting data using s2protocol library.
class_docstr_tok: ["Helper","class","for","loading","and","extracting","data","using","s2protocol","library","."]
docstr: Yield message events from the replay in s2protocol format.
docstr_tok: ["Yield","message","events","from","the","replay","in","s2protocol","format","."]
code: def message_events(self, filter_fn=None):
      """Yield message events from the replay in s2protocol format."""
      for event in _convert_all_to_str(
          self._protocol.decode_replay_message_events(
              self._extracted[b"replay.message.events"]
          )
      ):
          if not filter_fn or filter_fn(event):
              yield event
  
file_path: pysc2/pysc2/lib/replay/sc2_replay.py
imports: import io
  import json
  import types
  import mpyq
  from s2protocol import versions
  import tree
label_desc: Use image node_id 6 for calling the SC2Replay obj's underlying member method code with example usage: obj.message_events(filter_fn) without return types