Skip to content

Commit

Permalink
core: Don't panic on DefineFont4
Browse files Browse the repository at this point in the history
  • Loading branch information
Herschel committed Dec 2, 2020
1 parent 71f5339 commit a0d56aa
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion core/src/display_object/movie_clip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,10 @@ impl<'gc> MovieClip<'gc> {
.0
.write(context.gc_context)
.define_font_3(context, reader),
TagCode::DefineFont4 => unimplemented!(),
TagCode::DefineFont4 => self
.0
.write(context.gc_context)
.define_font_4(context, reader),
TagCode::DefineMorphShape => self.0.write(context.gc_context).define_morph_shape(
context,
reader,
Expand Down Expand Up @@ -2598,6 +2601,16 @@ impl<'gc, 'a> MovieClipData<'gc> {
Ok(())
}

#[inline]
fn define_font_4(
&mut self,
_context: &mut UpdateContext<'_, 'gc, '_>,
_reader: &mut SwfStream<&'a [u8]>,
) -> DecodeResult {
log::warn!("DefineFont4 tag (TLF text) is not implemented");
Ok(())
}

#[inline]
fn define_sound(
&mut self,
Expand Down

0 comments on commit a0d56aa

Please sign in to comment.