Page 1 of 23

BattleTech [Engine:Unity]

Posted: Fri Apr 27, 2018 11:43 pm
by SunBeam
Info
  • The table enables Mono Data Collector, hooks the Update function in BattleTech.UI.CombatDebugHUD to fetch an instance pointer
  • A key handler listens to key presses and intercepts whether or not Numpad 0 has been pressed
How to use
  1. Run the game, target the process in Cheat Engine's Process List (BattleTech.exe)
  2. Activate the [ Enable ] script
  3. Activate the Cheat Handler script
  4. Go back in-game, press Numpad 0 and have a look at the screen
You should see something like this:



Image



Effects
  • reduced damage (all damage multipliers are set to normal value * 0.1f, so a tenth of the normal damage) from enemies
  • no pilot injuries
  • maximum mech weapon accuracy (accuracy modifiers reduced to normal value - 20.0f chance of missing; very rare chances your mech misses the target)
  • increased damage (damage per shot modifier is set to normal value * 10.0f, so times ten the normal damage)
Additional Info
Enjoy!

BattleTech [Engine:Unity]

Posted: Fri Apr 27, 2018 11:52 pm
by willdunz
FIRST thanks for the table

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 12:09 am
by kanggg
Thank you, but I don't see any table. Everything's OK now. Thank you!

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 12:22 am
by SunBeam
willdunz, post: 43732, member: 1094 wrote:FIRST thanks for the table
I prefer it this way :)

Image
kanggg, post: 43736, member: 2899 wrote:Thank you, but I don't see any table.
It's up now :P

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 1:32 am
by SunBeam
Update #1


  • Some minor script fixes and missing/orphan entries (using {$strict} now)
  • Numpad 1 now toggles free camera; what this means if you will get a StarCraft feel of the game, without those frequent close-ups on attacks; right-click allows you to control camera look
  • Numpad 2 now toggles mech movement speed; what this does is to allow your bots to move fast across the map (animation is faster); affects enemy movement as well
Till we get the attachment replacement mod, I will post these short updates with their tables as individual posts. Will merge them later in main post :p



Enjoy!

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 1:46 am
by damienhell
Hi, it works great.

Can you add money mod in it please :)

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 2:03 am
by KS212
This is interesting... Is this 'god mode' feature something already in the engine and simply locked away? Makes me wonder what other fun toys are hidden under the surface, hmmmm.... :P

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 2:49 am
by TonganJedi
May I suggest putting those effects into their own activations so each one can be turned on or off (assuming that is feasible)?

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 2:52 am
by AManlyMan
Hello, thank you for the table. Just want to report that this is not working with the GOG version of the game. Causes the game to fail when cheat handler activates.

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 2:59 am
by darkdex52
Thanks for the tables. The only problem is there's no way to unload the cheat. God Mode persists through game exit/load. So if I need god mode for one mission, I guess I'm stuck with it forever.

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 3:12 am
by SunBeam
Update #2


  • Numpad 3 will increase Morale by 5 points (can be changed in the table) with each key press
  • Numpad 4 will increase Funds by 10000 (can be changed in the table) with each key press
All of the above works while here:

Image

Haven't tested if this works in-game (during in a mission). Just an FYI in case you report crashes :p (the pSimGameState pointer might not be valid/updated while in a mission).

So:

Image

Image + Numpad 3 x 5 times ? Image Image Image + Numpad 4 x 2 times ? Image Enjoy!

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 3:21 am
by SunBeam
damienhell, post: 43743, member: 16665 wrote:Hi, it works great.

Can you add money mod in it please :)
Added both Funds and Morale in version 1.2 of the table.


KS212, post: 43745, member: 426 wrote:This is interesting... Is this 'god mode' feature something already in the engine and simply locked away? Makes me wonder what other fun toys are hidden under the surface, hmmmm.... :p
Not that many under the hood that would be useful to the player. Am mainly adapting Unity logic to ASM (fetching this pointer and properly feeding the parameters through rdx, r8, r9).


AManlyMan, post: 43751, member: 14164 wrote:Hello, thank you for the table. Just want to report that this is not working with the GOG version of the game. Causes the game to fail when cheat handler activates.
If game crashes, don't close it. Instead open Memory Viewer, hit Ctrl+G and paste in BattleTech.UI:CombatDebugHUD:Update. Take a screenshot. Repeat the process, Ctrl+G and paste in BattleTech:SimGameState:Update. Take a screenshot. I wanna see if the hooks are fine.


darkdex52, post: 43752, member: 3747 wrote:Thanks for the tables. The only problem is there's no way to unload the cheat. God Mode persists through game exit/load. So if I need god mode for one mission, I guess I'm stuck with it forever.
Didn't know, nor do I care. It's how the developer feature works, ask them. Or I invite you to change the way the feature works if you care so much about God Mode preserved across whole game. Why do you cheat in the first place? T_T


God Mode is reset after a mission (or re-loading the whole game). You don't mind re-opening it if you want to play without God Mode, do you? Cool!

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 3:32 am
by vegimata
[QUOTE="darkdex52, post: 43752, member: 3747"]Thanks for the tables. The only problem is there's no way to unload the cheat. God Mode persists through game exit/load. So if I need god mode for one mission, I guess I'm stuck with it forever.[/QUOTE]

Looking at the script, it says toggle. So I think you can just press 0 again to disable it

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 3:36 am
by SunBeam
809: My impression is whatever effects God Mode caused would be reset once mission ends. If these changes persist, then they were done to the Mechs you had during that mission. If you buy (haven't yet gotten there) others, they'll be spared from these changes if you don't use God Mode :p Again, it's how the developers conceived this. I may take a look at the individual functions, perhaps I can come up with an undo feature...

I just tested a save game where I know for sure I used God Mode before the mission and all's back to normal; I'm getting my ass kicked by some turrets :p I dunno WTF 3747 is mumbling: the changes God Mode does get reset after a mission (or after closing the game).

There's no toggle for God Mode. It works just one way: enable on key press. And by enable I mean all the modifications below happen:

Code: Select all


private void SetGodMode(Team team)

{

    for (int i = 0; i ("debug", -1, "DamageReductionMultiplierAll", StatCollection.StatOperation.Float_Multiply, 0.1f, -1, true);

        item.StatCollection.ModifyStat("debug", -1, "ReceivedInstabilityMultiplier", StatCollection.StatOperation.Float_Multiply, 0.1f, -1, true);

        item.StatCollection.ModifyStat("debug", -1, "IgnorePilotInjuries", StatCollection.StatOperation.Set, true, -1, true);

        for (int j = 0; j ("debug", -1, "DamagePerShot", StatCollection.StatOperation.Float_Multiply, 10f, -1, true);

            weapon.StatCollection.ModifyStat("debug", -1, "AccuracyModifier", StatCollection.StatOperation.Float_Add, -20f, -1, true);

        }

        item.Combat.MessageCenter.PublishMessage(new FloatieMessage(item.GUID, item.GUID, "GOD MODE", FloatieMessage.MessageNature.Buff));

BR,
Sun

BattleTech [Engine:Unity]

Posted: Sat Apr 28, 2018 3:52 am
by yansenscc
thanks man

you rock