Announcement

Collapse
No announcement yet.

How hard is to change a game's code?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How hard is to change a game's code?

    I basically want to change a number.
    DISCLAIMER: the author of the above written texts does not warrant or assume any legal liability or responsibility for any offence and insult; disrespect, arrogance and related forms of demeaning behaviour; discrimination based on race, gender, age, income class, body mass, living area, political voting-record, football fan-ship and musical preference; insensitivity towards material, emotional or spiritual distress; and attempted emotional or financial black-mailing, skirt-chasing or death-threats perceived by the reader of the said written texts.

  • #2
    This is kind of like asking, "how hard is it to run for public office?" It depends on if you're running for President or Dog Catcher.

    Comment


    • #3
      use cheat engine

      find the value

      change it

      there are tutorials. it's easy
      To us, it is the BEAST.

      Comment


      • #4
        in order to find a particular value, you need to play around with it a little...

        say you want to fix the value for ammo at 100

        search for the starting value

        expend some ammo

        search for the new value

        repeat

        once you find the hex address, you can change it to whatever you want... even lock it
        To us, it is the BEAST.

        Comment


        • #5
          Well the game's duration is capped (as if you could only play a civ game for 500 turns) and I want to increase the cap.
          DISCLAIMER: the author of the above written texts does not warrant or assume any legal liability or responsibility for any offence and insult; disrespect, arrogance and related forms of demeaning behaviour; discrimination based on race, gender, age, income class, body mass, living area, political voting-record, football fan-ship and musical preference; insensitivity towards material, emotional or spiritual distress; and attempted emotional or financial black-mailing, skirt-chasing or death-threats perceived by the reader of the said written texts.

          Comment


          • #6
            I used a hex editor so I could play civ2 without the disk. It took a while because I missed the part of the instructions that said to patch first. So if it's been done before and there are instructions (and you take the time to read instructions), it's likely pretty easy.
            Pool Manager - Lombardi Handicappers League - An NFL Pick 'Em Pool

            https://youtu.be/HLNhPMQnWu4

            Comment


            • #7
              Originally posted by Colon™ View Post
              Well the game's duration is capped (as if you could only play a civ game for 500 turns) and I want to increase the cap.
              Which specific version of "civ"?

              It's likely in the savegame somewhere.
              To us, it is the BEAST.

              Comment


              • #8
                I only mentioned civ as an analogy. The game is a very basic stone age DOS-based program that's intended to be PBEM and has a SP mode that's capped in duration.
                DISCLAIMER: the author of the above written texts does not warrant or assume any legal liability or responsibility for any offence and insult; disrespect, arrogance and related forms of demeaning behaviour; discrimination based on race, gender, age, income class, body mass, living area, political voting-record, football fan-ship and musical preference; insensitivity towards material, emotional or spiritual distress; and attempted emotional or financial black-mailing, skirt-chasing or death-threats perceived by the reader of the said written texts.

                Comment


                • #9
                  Originally posted by Colon™ View Post
                  I basically want to change a number.
                  It completely depends. Some numbers are hardcoded into the game code and others are exposed as variables that can be modified more easily. There can also be significant knock on effects of something like 'change the number of turns' that depend completely on the rest of the code.

                  Comment


                  • #10
                    What can I learn to find out and achieve my goal?
                    DISCLAIMER: the author of the above written texts does not warrant or assume any legal liability or responsibility for any offence and insult; disrespect, arrogance and related forms of demeaning behaviour; discrimination based on race, gender, age, income class, body mass, living area, political voting-record, football fan-ship and musical preference; insensitivity towards material, emotional or spiritual distress; and attempted emotional or financial black-mailing, skirt-chasing or death-threats perceived by the reader of the said written texts.

                    Comment


                    • #11
                      Look at the game files. If its an old DOS game there may be files there you can open either with a hex editor like Sava said, or even with a text editor. If its packed, then there are tools you can use, but unless you're a programmer its probably asking too much.

                      Comment


                      • #12
                        Actually the best thing would probably be to explain exactly what you want to do here.
                        It's almost as if all his overconfident, absolutist assertions were spoonfed to him by a trusted website or subreddit. Sheeple
                        RIP Tony Bogey & Baron O

                        Comment


                        • #13
                          Originally posted by Colon™ View Post
                          I only mentioned civ as an analogy. The game is a very basic stone age DOS-based program that's intended to be PBEM and has a SP mode that's capped in duration.
                          How are you running this program? In a windows environment?

                          For a hex editor like cheat engine to be effective, you need to be able to manipulate the value in some way. You could try searching for the initial value (500?), then load a new game where the value is different. Search again. Repeat. Each time you do this, you eliminate possibilities. Eventually, you should be able to identify the address and change the value.

                          You could try searching through the save file itself if you are able to open it in some sort of text editor. That might even be easier. Create a few different games with different values. Search for those values. You should be able to find a location within those save files that contains each respective value.
                          To us, it is the BEAST.

                          Comment


                          • #14
                            You need to know which number to change. Generally if you use a cheat engine / hex editor to change a value in the game like the money you have you enter the amount of money you currently have ad run the editor, it will find all the addresses in the program with that number. Then you do something to change the number, enter the new value and run the editor again. You do this until there is only one address left, then you enter in the editor the desired value. Changing the total number of turns permitted would be tricky, unless the game allows you to select the number of turns you want to play. You might be able to change the number of turns you select to play using the aforementioned procedure, but if there is a maximum number of turns allowed hard-coded into the game it will be difficult to find that one address.
                            "I say shoot'em all and let God sort it out in the end!

                            Comment


                            • #15
                              Running it in dosbox. Didn't realise cheat engine was the name of a hex editor.

                              What exactly do you want me to explain more exactly rah?
                              DISCLAIMER: the author of the above written texts does not warrant or assume any legal liability or responsibility for any offence and insult; disrespect, arrogance and related forms of demeaning behaviour; discrimination based on race, gender, age, income class, body mass, living area, political voting-record, football fan-ship and musical preference; insensitivity towards material, emotional or spiritual distress; and attempted emotional or financial black-mailing, skirt-chasing or death-threats perceived by the reader of the said written texts.

                              Comment

                              Working...
                              X