# Path: xnb_parse/type_reader.py
# class TypeReaderPlugin(Plugin):
#     """
#     type reader plugins
#     """
# 
# Path: xnb_parse/type_readers/mercury/emitters.py
# class EmitterCollectionReader(BaseTypeReader, TypeReaderPlugin):
#     target_type = 'ProjectMercury.Emitters.EmitterCollection'
#     reader_name = 'Microsoft.Xna.Framework.Content.ReflectiveReader`1[ProjectMercury.Emitters.EmitterCollection]'
# 
#     def read(self):
#         elements = self.stream.read_int32()
#         return EmitterCollection(XNAList([self.stream.read_object(EmitterReader) for _ in range(elements)]))
# 
# Path: xnb_parse/type_readers/xna_primitive.py
# class StringReader(BaseTypeReader, TypeReaderPlugin):
#     target_type = 'System.String'
#     reader_name = 'Microsoft.Xna.Framework.Content.StringReader'
# 
#     def read(self):
#         return self.stream.read_string()
# 
# Path: xnb_parse/xna_types/mercury/particle.py
# class ParticleEffect(EmitterCollection):
#     def __init__(self, emitters, name, author, description):
#         EmitterCollection.__init__(self, emitters)
#         self.name = name
#         self.author = author
#         self.description = description
# 
#     def __repr__(self):
#         return 'ParticleEffect(name={!r}, emitters={}, author={!r}, description={!r})'.format(
#             self.name, self.emitters, self.author, self.description)


from xnb_parse.type_reader import TypeReaderPlugin
from xnb_parse.type_readers.mercury.emitters import EmitterCollectionReader
from xnb_parse.type_readers.xna_primitive import StringReader
from xnb_parse.xna_types.mercury.particle import ParticleEffect
"""
mercury particle engine main type readers
"""

from __future__ import print_function



class ParticleEffectReader(EmitterCollectionReader, TypeReaderPlugin):
    target_type = 'ProjectMercury.ParticleEffect'
    reader_name = 'Microsoft.Xna.Framework.Content.ReflectiveReader`1[ProjectMercury.ParticleEffect]'

    def read(self):
        emitters = EmitterCollectionReader.read(self).emitters

# Path: xnb_parse/type_reader.py
# class TypeReaderPlugin(Plugin):
#     """
#     type reader plugins
#     """
# 
# Path: xnb_parse/type_readers/mercury/emitters.py
# class EmitterCollectionReader(BaseTypeReader, TypeReaderPlugin):
#     target_type = 'ProjectMercury.Emitters.EmitterCollection'
#     reader_name = 'Microsoft.Xna.Framework.Content.ReflectiveReader`1[ProjectMercury.Emitters.EmitterCollection]'
# 
#     def read(self):
#         elements = self.stream.read_int32()
#         return EmitterCollection(XNAList([self.stream.read_object(EmitterReader) for _ in range(elements)]))
# 
# Path: xnb_parse/type_readers/xna_primitive.py
# class StringReader(BaseTypeReader, TypeReaderPlugin):
#     target_type = 'System.String'
#     reader_name = 'Microsoft.Xna.Framework.Content.StringReader'
# 
#     def read(self):
#         return self.stream.read_string()
# 
# Path: xnb_parse/xna_types/mercury/particle.py
# class ParticleEffect(EmitterCollection):
#     def __init__(self, emitters, name, author, description):
#         EmitterCollection.__init__(self, emitters)
#         self.name = name
#         self.author = author
#         self.description = description
# 
#     def __repr__(self):
#         return 'ParticleEffect(name={!r}, emitters={}, author={!r}, description={!r})'.format(
#             self.name, self.emitters, self.author, self.description)


# Path: xnb_parse/type_readers/mercury/particle.py
from xnb_parse.type_reader import TypeReaderPlugin
from xnb_parse.type_readers.mercury.emitters import EmitterCollectionReader
from xnb_parse.type_readers.xna_primitive import StringReader
from xnb_parse.xna_types.mercury.particle import ParticleEffect

"""
mercury particle engine main type readers
"""

from __future__ import print_function



class ParticleEffectReader(EmitterCollectionReader, TypeReaderPlugin):
    target_type = 'ProjectMercury.ParticleEffect'
    reader_name = 'Microsoft.Xna.Framework.Content.ReflectiveReader`1[ProjectMercury.ParticleEffect]'

    def read(self):
        emitters = EmitterCollectionReader.read(self).emitters

        name = self.stream.read_object(StringReader)