ruffle icon indicating copy to clipboard operation
ruffle copied to clipboard

Game partially load (unplayable) - https://www.4399.com/flash/137953_4.htm

Open wsxarcher opened this issue 1 year ago • 1 comments

Describe the bug

Game loads the board when selecting single player or multiplayer but it's unplayable because most objects are not loaded

ERROR core/src/library.rs:199 Tried to instantiate non-registered character ID 136
339.js:1133 ERROR core/src/display_object/movie_clip.rs:1700 Unable to instantiate display node id 136, reason being: Character id doesn't exist
339.js:1133 ERROR core/src/library.rs:199 Tried to instantiate non-registered character ID 242
339.js:1133 ERROR core/src/display_object/movie_clip.rs:1700 Unable to instantiate display node id 242, reason being: Character id doesn't exist
339.js:1133 WARN core/src/stub.rs:132 Encountered stub: AVM2 flash.display.Loader.unloadAndStop()
339.js:1133 WARN core/src/stub.rs:132 Encountered stub: AVM2 flash.display.Loader.unload()
339.js:1133 INFO web/src/log_adapter.rs:18 __________________--
339.js:1133 INFO web/src/log_adapter.rs:18 ctrl skin load OK !!!!
339.js:1133 INFO web/src/log_adapter.rs:18 ______________________________________
339.js:1133 INFO web/src/log_adapter.rs:18 __________  wmCtrl start  ____________
339.js:1133 INFO web/src/log_adapter.rs:18 ______________________________________
339.js:1133 INFO web/src/log_adapter.rs:18 _gameInfoStr = 712|490|137953|坦克动荡2
339.js:1133 WARN core/src/library.rs:523 Unknown device font "SimSun" (bold: false, italic: false)
339.js:1133 WARN core/src/library.rs:523 Unknown device font "Arial" (bold: true, italic: false)
339.js:1133 INFO web/src/log_adapter.rs:18 doSetStyle----------->100031854
339.js:1133 INFO web/src/log_adapter.rs:18 gameWid = 712
339.js:1133 INFO web/src/log_adapter.rs:18 gameHei = 490
339.js:1133 INFO web/src/log_adapter.rs:18 ************
339.js:1133 ERROR core/src/library.rs:199 Tried to instantiate non-registered character ID 136
339.js:1133 ERROR core/src/display_object/movie_clip.rs:1700 Unable to instantiate display node id 136, reason being: Character id doesn't exist
339.js:1133 ERROR core/src/library.rs:199 Tried to instantiate non-registered character ID 136
339.js:1133 ERROR core/src/display_object/movie_clip.rs:1700 Unable to instantiate display node id 136, reason being: Character id doesn't exist
339.js:1133 ERROR core/src/library.rs:199 Tried to instantiate non-registered character ID 136
339.js:1133 ERROR core/src/display_object/movie_clip.rs:1700 Unable to instantiate display node id 136, reason being: Character id doesn't exist
339.js:1133 ERROR core/src/library.rs:214 Tried to instantiate non-registered character gameTank
339.js:1133 WARN core/src/avm1/globals/movie_clip.rs:849 Unable to attach 'gameTank'
339.js:1133 ERROR core/src/library.rs:214 Tried to instantiate non-registered character gameTank
339.js:1133 WARN core/src/avm1/globals/movie_clip.rs:849 Unable to attach 'gameTank'

Expected behavior

Load the game correctly

Content Location

https://www.4399.com/flash/137953_4.htm

Affected platform

Browser's extension

Operating system

Window 11

Browser

Edge/Chrome 120

Additional information

This game is part of a bigger effort to support 4399.com games. There might be other issues with this website, from how it handles Flash checks and many CORS issues. Unfortunately, some games cannot be easily debugged on desktop because the swf download other swf or do requests while logged in.

If Ruffle is not detected try to reload the page multiple times because of the known race condition on the Flash check. To avoid refreshing try this Tampermonkey user script 一键下载 flash 游戏 (greasyfork.org)

To solve these issues refers to previous issues such as:

  • https://github.com/ruffle-rs/ruffle/issues/13943#issuecomment-1835074616 - Race condition discussion
  • https://github.com/ruffle-rs/ruffle/issues/14578#issuecomment-1873523939 - Ruffle detection issue
  • Edge/Chrome flag to temporarily disable CORS --disable-web-security or use https://chromewebstore.google.com/detail/allow-cors-access-control/lhobafahddgcelffkeicbaginigeejlf
  • Disable antidebugging with https://greasyfork.org/en/scripts/440060-anti-anti-debugger/code or Deactivate breakpoint
  • Disable second antidebugging manually fadb9686-1ce4-406b-9694-42b97842ee35

wsxarcher avatar Jan 30 '24 00:01 wsxarcher

4399 SWF loader 137953_4.zip

SWF with ImportAssets2 TankTroublev40.zip

ruffle TankTroublev40.swf --spoof-url "https://www.4399.com/flash/137953_4.htm" --base "https://sda.4399.com/4399swf/upload_swf/ftp14/cwb/20140611/y2/" --referer "https://www.4399.com/flash/137953_4.htm"

One of the imported SWF with ExportAssets Tank.zip

wsxarcher avatar Feb 13 '24 18:02 wsxarcher