Skip to content

Conversation

Stubbjax
Copy link

Fixes #283 from the patch repository
Fixes #917 from the patch repository
Fixes #1687 from the patch repository

This change allows deaths caused via OCL objects to yield experience to their creators.

This covers OCLs such as:

  • Firestorms / fire fields / fire walls
  • Radiation and poison fields
  • Fuel-air bombs
FIRESTORM_XP.mp4
FIREWALL_XP.mp4
RADIATION_XP.mp4
FAB_XP.mp4

@Stubbjax Stubbjax self-assigned this Sep 25, 2025
@Stubbjax Stubbjax added Bug Something is not working right, typically is user facing Controversial Is controversial Major Severity: Minor < Major < Critical < Blocker Gen Relates to Generals ZH Relates to Zero Hour NoRetail This fix or change is not applicable with Retail game compatibility labels Sep 25, 2025

#if !RETAIL_COMPATIBLE_CRC
ObjectID sinkID = sourceObj->getExperienceTracker()->getExperienceSink();
firstObject->getExperienceTracker()->setExperienceSink(sinkID != INVALID_ID ? sinkID : sourceObj->getID());
Copy link

@xezon xezon Oct 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we make this INI configurable? Edit: I think it needs to be, because it changes balance quite a bit. For example Dragon Tanks will become much faster promoted.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can. But is that not something that can be also tweaked by INI data?

Object ChinaTankDragon
-   ExperienceRequired = 0 100 150 300
+   ExperienceRequired = 0 150 250 400
End

I'd suggest earned experience is always desirable, whereas any associated balance implications are not so clear. Thus, it makes greater sense to adjust the balance in accordance with consistently earned experience, rather than making said experience optional for effectively arbitrary cases.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, these values can be tweaked. But will this be sufficient to avoid Pro Players jumping fences?

Can you collect all original game object names that would need ExperienceRequired potentially tweaked because of this change?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this would currently have the greatest impact on the following units:

  • Alpha Aurora (fuel-air bomb)
  • Dragon Tank (fire wall)
  • Inferno Cannon (fire field / firestorm)
  • Helix (firestorm)
  • Mig (fire field / firestorm)

And a minor impact on the following units:

  • Nuke Battlemaster (radiation field)
  • Nuke Overlord (radiation field)
  • Nuke Cannon (radiation field)
  • Scud Launcher (toxin field)
  • Toxin Tractor (toxin field)
  • Scorpion (toxin shells)
  • Marauder (toxin shells)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should be all the object names.

SupW_AmericaJetAurora

ChinaTankDragon
Infa_ChinaTankDragon
Nuke_ChinaTankDragon
Tank_ChinaTankDragon

ChinaVehicleInfernoCannon
Infa_ChinaVehicleInfernoCannon
Nuke_ChinaVehicleInfernoCannon

ChinaVehicleHelix
Infa_ChinaVehicleHelix
Tank_ChinaVehicleHelix

ChinaJetMIG
Infa_ChinaJetMIG
Tank_ChinaJetMIG

Nuke_ChinaTankBattleMaster
Nuke_ChinaTankOverlord

ChinaVehicleNukeLauncher
Infa_ChinaVehicleNukeLauncher
Nuke_ChinaVehicleNukeLauncher

GLAVehicleScudLauncher
Chem_GLAVehicleScudLauncher
Slth_GLAVehicleScudLauncher

GLAVehicleToxinTruck
Chem_GLAVehicleToxinTruck
Demo_GLAVehicleToxinTruck
Slth_GLAVehicleToxinTruck

GLATankScorpion
Chem_GLATankScorpion
Slth_GLATankScorpion

GLATankMarauder
Chem_GLATankMarauder
Slth_GLATankMarauder

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alpha Aurora getting this buff is pure comedy :D


#if !RETAIL_COMPATIBLE_CRC
ObjectID sinkID = sourceObj->getExperienceTracker()->getExperienceSink();
firstObject->getExperienceTracker()->setExperienceSink(sinkID != INVALID_ID ? sinkID : sourceObj->getID());
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why can this have 2 types of sink sources?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A projectile has its sink source set to the launcher in order to award experience to the launcher, so there is an experience sink defined - which the OCL will then use. However, if the OCL is produced by the launcher itself and not from a projectile, then there is no experience sink defined, and so it is directly assigned to the launcher.

@xezon xezon changed the title bugfix: Yield experience for deaths caused via OCL objects bugfix(object): Reward unit experience for kills caused via OCL objects Oct 16, 2025
@xezon xezon changed the title bugfix(object): Reward unit experience for kills caused via OCL objects bugfix(object): Reward unit experience for kills caused by OCL objects Oct 16, 2025
@xezon xezon merged commit 76a2f4a into TheSuperHackers:main Oct 16, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Buff Makes a thing more powerful Bug Something is not working right, typically is user facing Controversial Is controversial Gen Relates to Generals Major Severity: Minor < Major < Critical < Blocker NoRetail This fix or change is not applicable with Retail game compatibility ZH Relates to Zero Hour

Projects

None yet

2 participants