Opened 2 years ago

Closed 5 days ago

Last modified 5 days ago

#13557 closed defect (fixed)

AGS: PS3: Fatal "Unhandled 64-bit pointer result from plugin method call" with some games

Reported by: gradius3 Owned by: lephilousophe
Priority: high Component: Engine: AGS
Version: Keywords: AGS defect
Cc: Game:

Description

No single AGS game is working on PS3 v2.5.1. An error messages appears after starting a game and and that's it. No matter if it is a small or a big game. I tested multiple games which are reported to be working fine. First thought that it might be a memory issue because the error message states something about this, but then tried it out on my Wii and the small game "Maniac Mansion Deluxe" for instance is working fine there.

It has only <20MB, so I think the PS3 should handle this one. So I guess the AGS support is broken on the PS3 port!?

Change History (21)

comment:1 by criezy, 2 years ago

Possibly related to bugs #12802 and #13417.
There is a good chance this this is an endianness issue and affect all big endian platforms.

comment:2 by dwatteau, 2 years ago

Maniac Mansion Deluxe works on my big-endian PowerBook G4.

On PS3, starting it triggers the "Uhandled [sic] 64-bit pointer result from plugin method call" error message, though.

comment:3 by aquadran, 2 years ago

it might be also alignment issue

comment:4 by dwatteau, 22 months ago

Could you test this again once 2.7.0 is released (you can grab a test build in the meantime), and report back what you're seeing with each AGS game you test, please?

The "Uhandled 64-bit pointer result from plugin method call" error still happens on Maniac Mansion Deluxe, and some games may be very slow there, but the games should work a bit better on PS3 now.

comment:5 by dwatteau, 21 months ago

Component: Port: PS3Engine: AGS
Summary: PS3: AGS games not workingAGS: PS3: Fatal "Unhandled 64-bit pointer result from plugin method call" with some games

comment:6 by dwatteau, 21 months ago

I've done some tests again with ScummVM 2.7.0 and my (limited) AGS library on PS3, and all games appear to start fine there, now, except for:

  1. Maniac Mansion Deluxe is still triggering this "Uhandled 64-bit pointer result from plugin method call" fatal error (only on PS3, it's OK on ppc32). See https://github.com/scummvm/scummvm/blob/c1fd025a64470020851cd6c42f1359c1d893b7dc/engines/ags/engine/script/cc_instance.cpp#L1054
  2. Rendering in general is very slow there, but AFAICS this engine rendering limitation is already known.

in reply to:  6 comment:7 by tag2015, 16 months ago

Replying to dwatteau:

  1. Maniac Mansion Deluxe is still triggering this "Uhandled 64-bit pointer result from plugin method call" fatal error (only on PS3, it's OK on ppc32). See https://github.com/scummvm/scummvm/blob/c1fd025a64470020851cd6c42f1359c1d893b7dc/engines/ags/engine/script/cc_instance.cpp#L1054

I wonder if this could be related to the flashlight plugin, could you try another game that uses that plugin such as 9 hours to dawn? Thanks

comment:8 by somaen, 12 months ago

Would you be able to check what tag2015 asked above?

comment:9 by dwatteau, 11 months ago

So I did some tests with 9 hours to Dawn, and it doesn't trigger the issue on PS3.

Upgrading to ScummVM 2.8.0 didn't fix the error with Maniac Mansion Deluxe.

comment:10 by somaen, 2 weeks ago

Priority: normalhigh

Would be nice to look into this for 2.9.0

comment:11 by tag2015, 2 weeks ago

@dwatteau could you please re-test MMD on PS3 with the latest master? Thanks

in reply to:  11 comment:12 by dwatteau, 11 days ago

Replying to tag2015:

@dwatteau could you please re-test MMD on PS3 with the latest master? Thanks

Yes it still happens on PS3 with an up-to-date November 10th snapshot.

comment:13 by Le Philousophe <lephilousophe@…>, 6 days ago

In c5bc568d:

AGS: Fix call_function signature

call_function returns from PluginMethod::operator() which returns a
NumberPtr.
Its two calls also expect a NumberPtr but the function returned an int.
This should fix bug #13557.

comment:14 by lephilousophe, 6 days ago

Owner: set to lephilousophe
Resolution: fixed
Status: newpending

comment:15 by dwatteau, 6 days ago

Thank you very much, I'm doing a PS3 build through Docker, and I will report back the results.

comment:16 by dwatteau, 6 days ago

Unfortunately, the "Unhandled 64-bit pointer result from plugin method call" error is still there with Maniac Mansion Deluxe, when updating to my own build with commit c5bc568d4106be97c5f7904a0e73b665ff15cb3e.

comment:17 by dwatteau, 5 days ago

Maniac Mansion Deluxe now starts on PS3, thanks to lephilousophe's https://github.com/scummvm/scummvm/pull/6241 PR.

(However, the rendering is still very slow, and if I quit the game -- with the return to launcher setting on -- the console just appears to hang. But that's probably another set of issues for AGS on PS3).

So I think this ticket can be closed, once the PR above is merged into the main and 2.9.0 branches.

Thanks!

comment:18 by Le Philousophe <lephilousophe@…>, 5 days ago

In 7cc927d7:

AGS: Make NumberPtr a class instead of a union

It's illegal to reference an inactive member of a union and the types
are not layout compatible (and even not of the same size).
Instead, store every value in a integer of pointer size and cast
pointers to and from it.
This should really fix bug #13557.

comment:19 by Le Philousophe <lephilousophe@…>, 5 days ago

In 4addaacb:

AGS: Make NumberPtr a class instead of a union

It's illegal to reference an inactive member of a union and the types
are not layout compatible (and even not of the same size).
Instead, store every value in a integer of pointer size and cast
pointers to and from it.
This should really fix bug #13557.

comment:20 by lephilousophe, 5 days ago

Status: pendingclosed

comment:21 by Le Philousophe <lephilousophe@…>, 5 days ago

In f10c94d0:

AGS: Fix call_function signature

call_function returns from PluginMethod::operator() which returns a
NumberPtr.
Its two calls also expect a NumberPtr but the function returned an int.
This should fix bug #13557.

Note: See TracTickets for help on using tickets.