If I were to take an old Windows 95 .EXE written in C++, and I wanted to convert 8bit Integers to 16bit Integers, would it be difficult?

Viewed 496

If I had an old PC game that has certain variables that cannot exceed 255 without crashing, would it be possible to convert ALL 8bit integers into 16bit integers by modifying the Windows 95 executable?

The game I'm talking about is Total Annihilation from 1997. And although the game itself was way ahead of it's time and had the capabilities to be modded into epic experiences, (Hell, the game was so ahead of it's time, the data files use JSON-like syntax... The game also supports 4K and looks amazing still.) there is unfortunately a limit to the total number of weapons in the game. All weapons have IDs, and the max ID of a weapon is 255 as can be seen below:

[NUCLEAR_MISSILE]
    {
    ID=122;
    name=Nuclear Missile;
    rendertype=1;
    lineofsight=1;
    vlaunch=1;

    model=ballmiss;

    range=32000;
    reloadtime=180;

    noautorange=1;
    weapontimer=5;
    flighttime=400;

    weaponvelocity=350;
    weaponacceleration=50;
    turnrate=32768;
    areaofeffect=512;
    edgeeffectiveness=0.25;

    energypershot=180000;
    metalpershot=2000;

    stockpile=1;
    targetable=1;
    commandfire=1;
    cruise=1;

    soundstart=misicbm1;
    soundhit=xplomed4;

    firestarter=100;
    smokedelay=.1;
    selfprop=1;
    smoketrail=1;
    propeller=1;

    twophase=1;
    guidance=1;
    tolerance=4000;

    shakemagnitude=24;
    shakeduration=1.5;

    explosiongaf=commboom;
    explosionart=commboom;

    waterexplosiongaf=fx;
    waterexplosionart=h2oboom2;

    lavaexplosiongaf=fx;
    lavaexplosionart=lavasplashlg;

    startsmoke=1;

    [DAMAGE]
        {
        default=5500;
        ARMCOM=2900;
        CORCOM=2900;
        }
    }

Would this be worth it at all to attempt? I'm not very familiar with Assembly language, but I've heard that with C++ you sometimes have to write your own assembly language in certain instances back in the day.

All I want to do is just bump up all 8bit Ints to 16bit by editing the .EXE, how difficult would this be to pull off?

1 Answers
Related