ruffle icon indicating copy to clipboard operation
ruffle copied to clipboard

express delivery - can't enter the level

Open zjk261 opened this issue 1 year ago • 1 comments

Describe the bug

black screen

https://github.com/ruffle-rs/ruffle/assets/98996990/cfbd77ca-99b8-445f-b2fb-9b6d78f052d9

Expected behavior

https://github.com/ruffle-rs/ruffle/assets/98996990/a7c4cf97-a139-47fe-865c-c8fc7baeb0a2

Content Location

express-delivery.zip

Affected platform

Desktop app

Operating system

Windows 10

Browser

No response

Additional information

No response

zjk261 avatar May 16 '24 00:05 zjk261

ruffle_core::avm2::events: Error dispatching event EventObject(EventObject { type: "enterFrame", class: flash.events::Event, ptr: 0x22fe957fd70 }) to handler FunctionObject(FunctionObject { ptr: 0x22ff75a4430, name: Ok("net.flashpunk::Engine/onEnterFrame()") }) : TypeError: Error #1104: Attribute was already specified for element.
	at XML/XML::init()
	at XML()
	at com.cactigames.screens::PlayArea/loadLevel()
	at com.cactigames.screens::PlayArea/begin()
	at net.flashpunk::Engine/checkWorld()
	at net.flashpunk::Engine/update()
	at net.flashpunk::Engine/onEnterFrame()

It's reading an XML, then toString()ing it and reading it back once more. We lose namespace info in our toString(), causing it to clash with inkscape:version= and version= on the same element.

Dinnerbone avatar May 19 '24 20:05 Dinnerbone

@evilpie it regressed since nightly 2024-06-04 can you reopen it

zjk261 avatar Jun 06 '24 09:06 zjk261

So the issue is that namespace("") doesn't return anything. The reason for this is that we don't include the default namespace as part of the in_scope_namespaces. I am not sure yet when/where we would add the default namespace. (This also seems to clash a bit with inScopeNamespaces, which will add the public namespace explicitly) @Dinnerbone

evilpie avatar Jun 06 '24 17:06 evilpie

Oh I think this is actually related to handling xmlns="http://foo" without a prefix.

evilpie avatar Jun 06 '24 17:06 evilpie