ruffle-rs / ruffle

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

The King's League - Can't Hire New Heros #14678

Open desertking opened 10 months ago

desertking commented 10 months ago

Describe the bug

If I want to recruit someone from the village and click the button I get this error:

ERROR core/src/avm2/events.rs:428 Error dispatching event EventObject(EventObject { type: "click", class: flash.events::MouseEvent, ptr: 0x20b18fa8 }) to handler FunctionObject(FunctionObject { ptr: 0x2274c680, name: Ok("-48::-LL/_-T6()") }) : TypeError: Error #1010: A term is undefined and has no properties. (accessing field: stats)

Expected behavior

Unit to be bought...

Content Location

https://f.silvergames.com/the-king-s-league-odyssey.swf

Affected platform

Online demo

Operating system

All

Browser

All

Additional information

No response

Aaron1011 commented 10 months ago

I can't reproduce this on the latest master

desertking commented 10 months ago

What is the latest? 11th still same problem...

desertking commented 10 months ago

A screenshot of the button that does nothing. Clicking should add another soldier.

image

sombraguerrero commented 10 months ago

I confirm that I definitely cannot replicate this. Played several rounds having recruited more knights from the village.

desertking commented 10 months ago

I can defenitley confirm that his still happens for me :) Using chrome latest build 29 January. Still same error:

R core/src/avm2/events.rs:428 Error dispatching event EventObject(EventObject { type: "click", class: flash.events::MouseEvent, ptr: 0x204ecfb8 }) to handler FunctionObject(FunctionObject { ptr: 0x21f68c48, name: Ok("-48::-LL/_-T6()") }) : TypeError: Error #1010: A term is undefined and has no properties. (accessing field: stats)

sombraguerrero commented 10 months ago

Okay, so this is specifically happening on web, presumably because the underlying API calls are failing. So, I would say use the desktop app for this one if you can, but otherwise, those API calls would have to get carved out.

sombraguerrero commented 10 months ago

or, the Flash projector of course.

desertking commented 10 months ago

Isn't there an elegant option to stop/ignore the API Calls as they likely will never work again. I guess the only option ruffle-wise is to pretend to be localhost as it seems to make an exception for that? I'm only interested in web solutions.

sombraguerrero commented 10 months ago

We can't site spoof on web the way we can on desktop, so if you're dead-set on web, the next easiest solution would be to use nosamu's Basilisk build. https://archive.org/details/basilisk-portable-with-flash