Skip to content

Fix electro-bastard ray missing when using OpenGL#1131

Open
Link4Electronics wants to merge 8 commits into
dethrace-labs:mainfrom
Link4Electronics:electroraygl
Open

Fix electro-bastard ray missing when using OpenGL#1131
Link4Electronics wants to merge 8 commits into
dethrace-labs:mainfrom
Link4Electronics:electroraygl

Conversation

@Link4Electronics

@Link4Electronics Link4Electronics commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

It wasn't being rendered on OpenGL 3dfx_mode, only on softrend, this should fix it
Added StartupWMClass too, which should help people with gnome or kde plasma to show the Icon on the taskbar

@github-actions

Copy link
Copy Markdown

reccmp report


Saved diff report generated May 25 2026, 11:44:11 (32 days, 0:16:52 ago)

Increased (3):
0x45c921 - RespawnPedestrians (80.92% -> 83.97%)
0x45ca0b - GetPedPosition (97.59% -> 100.00%)
0x460b66 - ReceivedPedestrian (99.46% -> 100.00%)

Decreased (7):
0x4566ee - MungePedestrianSequence (98.60% -> 90.46%)
0x4568d7 - MungePedestrianFrames (100.00% -> 98.51%)
0x457548 - MungePedestrianPath (85.90% -> 85.61%)
0x4598e2 - DoPedestrian (98.87% -> 98.30%)
0x459db7 - MungePedestrianAction (86.80% -> 85.28%)
0x45a078 - CalcPedestrianDangerLevel (87.07% -> 86.17%)
0x45bcc5 - MoveToEdgeOfCar (54.71% -> 54.41%)

Compiler entropy (1):
0x459476 - MungePedestrians (100.00% -> 100.00%*)


Total effective accuracy 95.95% across 2385 functions (95.62% actual accuracy)
13 functions are aligned (0.55%)

@github-actions

Copy link
Copy Markdown

reccmp report


Saved diff report generated May 25 2026, 11:44:11 (32 days, 0:39:50 ago)

Increased (3):
0x45c921 - RespawnPedestrians (80.92% -> 83.97%)
0x45ca0b - GetPedPosition (97.59% -> 100.00%)
0x460b66 - ReceivedPedestrian (99.46% -> 100.00%)

Decreased (7):
0x4566ee - MungePedestrianSequence (98.60% -> 90.46%)
0x4568d7 - MungePedestrianFrames (100.00% -> 98.51%)
0x457548 - MungePedestrianPath (85.90% -> 85.61%)
0x4598e2 - DoPedestrian (98.87% -> 98.30%)
0x459db7 - MungePedestrianAction (86.80% -> 85.28%)
0x45a078 - CalcPedestrianDangerLevel (87.07% -> 86.17%)
0x45bcc5 - MoveToEdgeOfCar (54.71% -> 54.41%)

Compiler entropy (1):
0x459476 - MungePedestrians (100.00% -> 100.00%*)


Total effective accuracy 95.95% across 2385 functions (95.62% actual accuracy)
13 functions are aligned (0.55%)

@github-actions

github-actions Bot commented Jul 1, 2026

Copy link
Copy Markdown

reccmp report


Saved diff report generated June 30 2026, 16:36:22 (21:11:04 ago)

Increased (2):
0x45a3bd - CheckPedestrianDeathScenario (97.58% -> 97.64%)
0x45bcc5 - MoveToEdgeOfCar (94.18% -> 95.59%)

Decreased (2):
0x4568d7 - MungePedestrianFrames (98.51% -> 98.01%)
0x459db7 - MungePedestrianAction (100.00%* -> 97.55%)

Compiler entropy (2):
0x455953 - GetPedestrianActor (100.00%* -> 100.00%)
0x455f31 - MungeModelSize (100.00%* -> 100.00%)


Total effective accuracy 96.45% across 2387 functions (96.09% actual accuracy)
13 functions are aligned (0.54%)

@madebr

madebr commented Jul 1, 2026

Copy link
Copy Markdown
Collaborator

This pr shows the same artifacts as mentioned here

Screenshot From 2026-07-01 15-51-02

@Link4Electronics

Link4Electronics commented Jul 1, 2026

Copy link
Copy Markdown
Contributor Author

oh, didn't know about this issue that you guys were already investigating it, and wow squall-leonhart dev of vba-m, last person that would imagine caring about carmageddon xd

willl try to adapt his patch to this PR later then

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown

reccmp report


Saved diff report generated June 30 2026, 16:36:22 (1 day, 7:37:11 ago)

Increased (2):
0x45a3bd - CheckPedestrianDeathScenario (97.58% -> 97.64%)
0x45bcc5 - MoveToEdgeOfCar (94.18% -> 95.59%)

Decreased (2):
0x4568d7 - MungePedestrianFrames (98.51% -> 98.01%)
0x459db7 - MungePedestrianAction (100.00%* -> 97.55%)

Compiler entropy (2):
0x455953 - GetPedestrianActor (100.00%* -> 100.00%)
0x455f31 - MungeModelSize (100.00%* -> 100.00%)


Total effective accuracy 96.45% across 2387 functions (96.09% actual accuracy)
13 functions are aligned (0.54%)

@Link4Electronics

Link4Electronics commented Jul 2, 2026

Copy link
Copy Markdown
Contributor Author

It looks much better now, thanks to @Squall-Leonhart
image

@Squall-Leonhart

Copy link
Copy Markdown

still very wrong though, comparably.

@Link4Electronics

Link4Electronics commented Jul 2, 2026

Copy link
Copy Markdown
Contributor Author

what about now? still didn't commit the changes, but halved the thickness factor from 0.003f to 0.001f and the minimum clamp from 0.01f to 0.003f
image

hm, comparing to this image
596218090-bf44100f-c9be-4ae4-87f4-2fc75166823d

I guess still need to be more thin

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown

reccmp report


Saved diff report generated June 30 2026, 16:36:22 (1 day, 9:59:52 ago)

Increased (2):
0x45a3bd - CheckPedestrianDeathScenario (97.58% -> 97.64%)
0x45bcc5 - MoveToEdgeOfCar (94.18% -> 95.59%)

Decreased (2):
0x4568d7 - MungePedestrianFrames (98.51% -> 98.01%)
0x459db7 - MungePedestrianAction (100.00%* -> 97.55%)

Compiler entropy (2):
0x455953 - GetPedestrianActor (100.00%* -> 100.00%)
0x455f31 - MungeModelSize (100.00%* -> 100.00%)


Total effective accuracy 96.45% across 2387 functions (96.09% actual accuracy)
13 functions are aligned (0.54%)

@Squall-Leonhart

Squall-Leonhart commented Jul 2, 2026

Copy link
Copy Markdown

The bolts are supposed to have a consistent line thickness, try thickness = -(pStart->v[2] + pEnd->v[2]) * 0.5f * 0.002f; instead

-    thickness = -pEnd->v[2] * 0.001f;
-    if (thickness < 0.003f) {
-        thickness = 0.003f;
-    }
+    thickness = -(pStart->v[2] + pEnd->v[2]) * 0.001f;

If far bolts disappear entirely, bump to 0.0015f.

@Link4Electronics

Link4Electronics commented Jul 2, 2026

Copy link
Copy Markdown
Contributor Author
  • thickness = -(pStart->v[2] + pEnd->v[2]) * 0.001f;

That's the result
image

with 0.0015f, to me looks better
image

But they still don't have a consistent thickness, this started to get harder than initially thought 😅

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown

reccmp report


Saved diff report generated June 30 2026, 16:36:22 (2 days, 3:28:23 ago)

Increased (2):
0x45a3bd - CheckPedestrianDeathScenario (97.58% -> 97.64%)
0x45bcc5 - MoveToEdgeOfCar (94.18% -> 95.59%)

Decreased (2):
0x4568d7 - MungePedestrianFrames (98.51% -> 98.01%)
0x459db7 - MungePedestrianAction (100.00%* -> 97.55%)

Compiler entropy (2):
0x455953 - GetPedestrianActor (100.00%* -> 100.00%)
0x455f31 - MungeModelSize (100.00%* -> 100.00%)


Total effective accuracy 96.45% across 2387 functions (96.09% actual accuracy)
13 functions are aligned (0.54%)

@Link4Electronics

Copy link
Copy Markdown
Contributor Author

looks more consistent the beams now
image

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown

reccmp report


Saved diff report generated June 30 2026, 16:36:22 (2 days, 3:42:06 ago)

Increased (2):
0x45a3bd - CheckPedestrianDeathScenario (97.58% -> 97.64%)
0x45bcc5 - MoveToEdgeOfCar (94.18% -> 95.59%)

Decreased (2):
0x4568d7 - MungePedestrianFrames (98.51% -> 98.01%)
0x459db7 - MungePedestrianAction (100.00%* -> 97.55%)

Compiler entropy (2):
0x455953 - GetPedestrianActor (100.00%* -> 100.00%)
0x455f31 - MungeModelSize (100.00%* -> 100.00%)


Total effective accuracy 96.45% across 2387 functions (96.09% actual accuracy)
13 functions are aligned (0.54%)

@MastaG

MastaG commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Last one looks fine to me.
Better than no rays at all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants