ruffle-rs / ruffle

A Flash Player emulator written in Rust
https://ruffle.rs
Other
15.58k stars 811 forks source link

Car Eats Car 2 Deluxe: Cannot perform Construct on a detached ArrayBuffer #18273

Open MartySVK opened 1 day ago

MartySVK commented 1 day ago

Describe the bug

~This game stopped working with Nightly 2024-10-13. Probably caused by this PR - https://github.com/ruffle-rs/ruffle/pull/18241~

It is not possible to run the first level when you click on "1 Level" button.

ruffle_web-wasm_extensions.js:3840 Uncaught TypeError: Cannot perform Construct on a detached ArrayBuffer
    at new Uint8Array (<anonymous>)
    at n.wbg.__wbg_newwithbyteoffsetandlength_8a2cb9ca96b27ec9 (ruffle_web-wasm_extensions.js:3840:21)
    at ruffle_web.wasm.__wbg_newwithbyteoffsetandlength_8a2cb9ca96b27ec9 externref shim (ruffle_web.wasm-0322f5f6:0x94b834)
    at ruffle_web.wasm.js_sys::Uint8Array::view::he2f5f72779003e73 (ruffle_web.wasm-0322f5f6:0x939fab)
    at ruffle_web.wasm.glow::web::texture_data_view::heeda3e5e0d379625 (ruffle_web.wasm-0322f5f6:0x85424d)
    at ruffle_web.wasm.<T as wgpu::context::DynContext>::queue_submit::he73d79367f6ed3b0 (ruffle_web.wasm-0322f5f6:0x4d2f65)
    at ruffle_web.wasm.wgpu::Queue::submit::hd42fde0fee2580c1 (ruffle_web.wasm-0322f5f6:0x7d4a3e)
    at ruffle_web.wasm.<ruffle_render_wgpu::backend::WgpuRenderBackend<T> as ruffle_render::backend::RenderBackend>::resolve_sync_handle::h8f2b2216d80c5f29 (ruffle_web.wasm-0322f5f6:0x7d18a5)
    at ruffle_web.wasm.ruffle_core::bitmap::bitmap_data::wrapper::BitmapDataWrapper::sync::h0a21ea304160b6d4 (ruffle_web.wasm-0322f5f6:0x790949)
    at ruffle_web.wasm.ruffle_core::bitmap::operations::color_bounds_rect::h65224e9030a7c40d (ruffle_web.wasm-0322f5f6:0x6f4f5e)
web/src/lib.rs:1140 Unable to lock Ruffle core

Expected behavior

run first level

Content Location

PLAY - https://www.gameflare.com/online-game/car-eats-car-2-deluxe/ SWF - https://data.gameflare.com/games/4369/d2pvIGEwLCA5Vx.swf

Affected platform

Web

Operating system

Windows 11

Browser

Chrome

Additional information

No response

kjarosh commented 1 day ago

It's not easy to reproduce, most of the time it works for me, but I managed to get this error one time out of ten tries on 2024-10-14 using Firefox. I did not manage to reproduce it on 2024-10-13 nor 2024-10-12.

@MartySVK I assume the "desktop app" part is a mistake, as this happens on web?

MartySVK commented 1 day ago

Yes, I tested it on the web. I tested a little bit more...looks like it is a random. Not connected with Nightly 2024-10-13