avm1: Use `resolve_target_display_object` in `Color`
Fixes the boss damage blinking in Alien Hominid. Target was a path string.
This commit is contained in:
parent
69f19f03c4
commit
7532e89aff
|
@ -78,10 +78,8 @@ fn target<'gc>(
|
||||||
context: &mut UpdateContext<'_, 'gc, '_>,
|
context: &mut UpdateContext<'_, 'gc, '_>,
|
||||||
this: Object<'gc>,
|
this: Object<'gc>,
|
||||||
) -> Result<Option<DisplayObject<'gc>>, Error> {
|
) -> Result<Option<DisplayObject<'gc>>, Error> {
|
||||||
this.get("target", avm, context)?
|
let target = this.get("target", avm, context)?.resolve(avm, context)?;
|
||||||
.resolve(avm, context)?
|
avm.resolve_target_display_object(context, target)
|
||||||
.as_object()
|
|
||||||
.map(|o| o.as_display_object())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_rgb<'gc>(
|
fn get_rgb<'gc>(
|
||||||
|
|
Loading…
Reference in New Issue