Supermodel icon indicating copy to clipboard operation
Supermodel copied to clipboard

[Linux][lostwsga] Aiming problem

Open WebSiteFurbo opened this issue 1 year ago • 9 comments

Hello to everybody,

I noticed that:

  • when moving the mouse along the X-axis, Player 1's crosshair moves on the horizontal plan;
  • when moving the mouse along the Y-axis, Player 2's crosshair moves on the horizontal plan;

I think it is a bug because the following configuration in the ini file works very well with Ocean Hunter but not for The Lost World, so I do not want to modify it:

; Analog guns (Ocean Hunter, LA Machineguns) InputAnalogGunLeft = "KEY_LEFT" ; digital, move gun left InputAnalogGunRight = "KEY_RIGHT" ; digital, move gun right InputAnalogGunUp = "KEY_UP" ; digital, move gun up InputAnalogGunDown = "KEY_DOWN" ; digital, move gun down InputAnalogGunX = "MOUSE_XAXIS,JOY1_XAXIS" ; analog, full X axis InputAnalogGunY = "MOUSE_YAXIS,JOY1_YAXIS" ; analog, full Y axis InputAnalogTriggerLeft = "KEY_A,JOY1_BUTTON1,MOUSE_LEFT_BUTTON" InputAnalogTriggerRight = "KEY_S,JOY1_BUTTON2,MOUSE_RIGHT_BUTTON"

I noticed that during the boot an error message appears as well:

Capture d’écran du 2024-05-31 21-26-32

I tried to find this "Sensor Gun!!" warning on the official manual but I did not find it. 00000482.pdf

Any help is greatly appreciated.

WebSiteFurbo avatar May 31 '24 20:05 WebSiteFurbo

Which build are you using and where did you get it from? I’m pretty certain Lost World works fine. You may need to calibrate things in the service menu and then double check your INI file settings.

Can you paste both your INI file as well as Supermodel.log after running lostwsga?

trzy avatar May 31 '24 22:05 trzy

Hi trzy,

I am using Supermodel 0.3a-WIP, I got it from your Github page running:

git clone https://github.com/trzy/Supermodel.git

My GPU info: 4.6 (Core Profile) Mesa 24.0.5-1ubuntu1 (core profile). The emulator is installed on Ubuntu 24.04 LTS, with gcc 13.2.0 and libglu1-mesa-dev installed. Here are the files you asked. I tried to calibrate the gun in Service Mode but it was moving only on the horizontal plan.

Supermodel.log

Supermodel_INI.txt

I converted the .ini file into a .txt one otherwise Github would not have accepted it.

WebSiteFurbo avatar Jun 02 '24 12:06 WebSiteFurbo

I think there's a few issues coming together here that makes this problem keep coming around.

If you look at the OPs log file, you'll see lostwsga is requested and loaded, but on the next line down lostwsgp is called in.

[Info] Supermodel Version 0.3a-WIP [Info] Started as: [Info] argv[0] = ./supermodel [Info] argv[1] = lostwsga.zip [Info] Opened lostwsga.zip. [Info] lostwsgp: [Info] banked_crom: stride=8, chunk size=2, byte layout=10325476

A merged ROM set issue? In Supermodels defence, the -help output does stipulate ROM set must be a valid ZIP file containing a single game.

The next problem is Supermodel is looking for out dated hard coded game names in Model3.cpp. lostwsgo became lostwsgp ages ago.

https://github.com/trzy/Supermodel/blob/master/Src/Model3/Model3.cpp#L613

if (m_game.name == "lostwsga" || m_game.name == "lostwsgo") { // to do, not a string compare adc[0] = (UINT8)Inputs->analogGunX[0]->value; // order is different for some reason in lost world adc[1] = 255 - (UINT8)Inputs->analogGunY[0]->value; // why are values inverted? is this the wrong place to fix this adc[2] = (UINT8)Inputs->analogGunX[1]->value adc[3] = 255 - (UINT8)Inputs->analogGunY[1]->value; }

Btw, There is also hard coded name check in Main.cpp https://github.com/trzy/Supermodel/blob/master/Src/OSD/SDL/Main.cpp#L966

gameHasLightguns |= game.name == "lostwsga";

Plus, when you add in the fact that users can amend their Games.xml to change the gun type, users mileage really will vary when playing lost world games.

ghost avatar Aug 20 '24 23:08 ghost

This is a really good point! We should not be looking for names but rather checking for the inputs that the game has, in the Game struct.

trzy avatar Aug 24 '24 21:08 trzy

Hello Trzy and ToBul, thanks for the explanations. Sorry Trzy, by writing this:

We should not be looking for names but rather checking for the inputs that the game has, in the Game struct

You mean that I should look into Games.xml? Sorry I am still a beginner from this point of view ;) By the way, changing the rom solved the problem. Why my first rom was faulty and why the new one is working?

Regards.

WebSiteFurbo avatar Aug 31 '24 16:08 WebSiteFurbo

You're ROMs wouldn't of been faulty, just merged. Supermodel doesn't always handle merged ROMs correctly. Supermodel then fails to identify the ROM it loads due to outdated code.

From reading other posts, I think Supermodel also struggles with ROMs scud and scudau. This means users aren't always getting the version of the game they think they are getting.

Bart has said he would like to improve the game loading logic at some point. I wish him luck as the game loader file is over 1000 lines long, and I don't understand a word of it. 😄

ghost avatar Aug 31 '24 18:08 ghost

I wish him luck as well. Anyway he is doing an amazing job on the emulator :)

WebSiteFurbo avatar Sep 06 '24 21:09 WebSiteFurbo

It’ll be easy — I’ll take the list of files and send it to ChatGPT with a prompt and Games.xml and it’ll tell us what game it is. While I’m at it, maybe also add a voice interface to Supermodel so you can just tell it what options you want and how to map your inputs 😉Sent from my iPhoneOn Sep 6, 2024, at 2:11 PM, WebSiteFurbo @.***> wrote: I wish him luck as well. Anyway he is doing an amazing job on the emulator :)

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

trzy avatar Sep 07 '24 02:09 trzy

I noticed that:

  • when moving the mouse along the X-axis, Player 1's crosshair moves on the horizontal plan;
  • when moving the mouse along the Y-axis, Player 2's crosshair moves on the horizontal plan;

I think it is a bug because the following configuration in the ini file works very well with Ocean Hunter but not for The Lost World, so I do not want to modify it:

@WebSiteFurbo Yooooo, just remove the controller JOY1XAXIS & JOY1YAXIS inputs from the ini file, or unplug/disconnect your controller. You are getting clashing inputs with the controller which causes mouse moment to be stuck on one axis. Simples!

Not linux related btw

WarpedPolygon avatar Oct 23 '24 14:10 WarpedPolygon