Ejemplo n.º 1
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length())
     stream.write_float32(self.alpha)
     stream.write_uint32(self.flags)
     stream.write_float32_array(self.color)
     stream.write_int32(self.geoset_id)
     self.write_animations(stream)
Ejemplo n.º 2
0
 def write_mdx(self, stream: BinaryStream, version):
     super().write_mdx(stream, version)
     stream.write_uint32(self.type)
     stream.write_float32_array(self.vertices[0])
     if self.type != 2:
         stream.write_float32_array(self.vertices[1])
     if self.type == 2 or self.type == 3:
         stream.write_float32(self.bounds_radius)
Ejemplo n.º 3
0
 def write_mdx(self, stream: BinaryStream):
     stream.write(self.name)
     stream.skip(80 - len(self.name))
     stream.write_uint32_array(self.interval)
     stream.write_float32(self.move_speed)
     stream.write_uint32(self.flags)
     stream.write_float32(self.rarity)
     stream.write_uint32(self.sync_point)
     self.extent.write_mdx(stream)
Ejemplo n.º 4
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length())
     super().write_mdx(stream, version)
     stream.write_uint32(self.name)
     stream.write_float32_array(self.attenuation)
     stream.write_float32_array(self.color)
     stream.write_float32(self.intensity)
     stream.write_float32_array(self.ambient_color)
     stream.write_float32(self.ambient_intensity)
     self.write_non_generic_animation_chunks(stream)
Ejemplo n.º 5
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length(version))
     stream.write_uint32(self.filter_mode)
     stream.write_uint32(self.flags)
     stream.write_int32(self.texture_id)
     stream.write_int32(self.texture_animation_id)
     stream.write_uint32(self.coord_id)
     stream.write_float32(self.alpha)
     if version > 800:
         stream.write_float32(self.emissive_gain)
         stream.write_float32_array(self.fresnel_color)
         stream.write_float32(self.fresnel_opacity)
         stream.write_float32(self.fresnel_team_color)
     self.write_animations(stream)
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length())
     super().write_mdx(stream, version)
     stream.write_float32(self.life_span)
     stream.write_float32(self.emission_rate)
     stream.write_float32(self.speed)
     stream.write_float32_array(self.color)
     stream.write_float32(self.alpha)
     stream.write_uint32(self.replaceable_id)
     stream.write(self.path)
     stream.skip(260 - len(self.path))
     stream.write(self.animation_visibility_guide)
     stream.skip(260 - len(self.animation_visibility_guide))
     self.write_non_generic_animation_chunks(stream)
Ejemplo n.º 7
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length())
     super().write_mdx(stream, version)
     stream.write_float32(self.height_above)
     stream.write_float32(self.height_below)
     stream.write_float32(self.alpha)
     stream.write_float32_array(self.color)
     stream.write_float32(self.lifespan)
     stream.write_uint32(self.texture_slot)
     stream.write_uint32(self.emission_rate)
     stream.write_uint32(self.rows)
     stream.write_uint32(self.columns)
     stream.write_int32(self.material_id)
     stream.write_float32(self.gravity)
     self.write_non_generic_animation_chunks(stream)
Ejemplo n.º 8
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length(version=version))
     stream.write(self.name)
     stream.skip(80 - len(self.name))
     stream.write_float32_array(self.position)
     stream.write_float32(self.field_of_view)
     stream.write_float32(self.far_clipping_plane)
     stream.write_float32(self.near_clipping_plane)
     stream.write_float32_array(self.target_position)
     self.write_animations(stream)
Ejemplo n.º 9
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_int32(self.get_byte_length())
     super().write_mdx(stream, version)
     stream.write_float32(self.emission_rate)
     stream.write_float32(self.gravity)
     stream.write_float32(self.longitude)
     stream.write_float32(self.latitude)
     stream.write(self.path)
     stream.skip(260 - len(self.path))
     stream.write_float32(self.life_span)
     stream.write_float32(self.speed)
     self.write_non_generic_animation_chunks(stream)
Ejemplo n.º 10
0
 def write_mdx_value(self, stream: BinaryStream, value):
     stream.write_float32(value)
Ejemplo n.º 11
0
 def write_mdx(self, stream: BinaryStream):
     stream.write_float32(self.bounds_radius)
     stream.write_float32_array(self.min)
     stream.write_float32_array(self.max)
Ejemplo n.º 12
0
 def write_mdx(self, stream: BinaryStream, version):
     stream.write_uint32(self.get_byte_length())
     super().write_mdx(stream, version)
     stream.write_float32(self.speed)
     stream.write_float32(self.variation)
     stream.write_float32(self.latitude)
     stream.write_float32(self.gravity)
     stream.write_float32(self.life_span)
     stream.write_float32(self.emission_rate)
     stream.write_float32(self.width)
     stream.write_float32(self.length)
     stream.write_uint32(self.filter_mode)
     stream.write_uint32(self.rows)
     stream.write_uint32(self.columns)
     stream.write_uint32(self.head_or_tail)
     stream.write_float32(self.tail_length)
     stream.write_float32(self.time_middle)
     stream.write_float32_array(self.segment_colors[0])
     stream.write_float32_array(self.segment_colors[1])
     stream.write_float32_array(self.segment_colors[2])
     stream.write_uint8_array(self.segment_alphas)
     stream.write_float32_array(self.segment_scaling)
     stream.write_uint32_array(self.head_intervals[0])
     stream.write_uint32_array(self.head_intervals[1])
     stream.write_uint32_array(self.tail_intervals[0])
     stream.write_uint32_array(self.tail_intervals[1])
     stream.write_int32(self.texture_id)
     stream.write_uint32(self.squirt)
     stream.write_int32(self.priority_plane)
     stream.write_uint32(self.replaceable_id)
     self.write_non_generic_animation_chunks(stream)