Quantcast

Jump to content

» «
Photo

Auto-converting saves on gtasnp.com

15 replies to this topic
Samutz
  • Samutz

    if ($lol) { die(rofl()); }

  • Members
  • Joined: 17 Sep 2003

#1

Posted 27 June 2007 - 02:29 AM Edited by Samutz, 27 June 2007 - 03:35 AM.

I decided to take another swing at having the site automatically convert saves to work on v2 exes (the same way the converter tool does).

But being that I only have v1, I need some help testing if it actually works.

Each download page now has extra links which are the v2 links. I'd like anyone who uses the site to please download from those links and report here if they work or not (if they load in game). Even if you have v1 (since v1 loads v2 saves without conversion). And please include your version in your post.

NOTE: You do still need to swap your scripts if you're switching from one version to another.

rubregg
  • rubregg

    brainslug

  • Members
  • Joined: 03 May 2006

#2

Posted 27 June 2007 - 09:13 AM

I just did some testing. (with v1.00 cracked)

a)
uploaded 5 of my v1 saves, downloaded all 5 from your second link (i.e. converted files) and reloaded into my v1 - all worked. (as v1 doesn't seem to check the file ID)

b)
downloaded a genuine v2 save, played (with v2 scripts), saved again, uploaded without converting. downloaded from second link (converted file), could load and play that.


then I got interested in the checksum thing so I went a bit deeper. And now I'm confused... lol.gif

I took one of my v1+v2 scripts save (id 83e5f365) and manually changed the id (bytes 5-8) to v2 (f68d14fd). Then I sent that manually converted file through the converter program and got the output: "ID changed from f68d14fd to f68d14fd; checksum changed from (value) to (same value)".

So I thought fine, the checksum isn't actually in the file and changing the 4 ID bytes will end up with the correct file, checksum and all.

Then I did binary file compares, to see if files are really identical. And found this:

sometimes the 4th byte before the end gets changed too.

in my original unconverted file, it's CE
in my manually converted file, it's CE
the above PLUS converter program has CE as well.

but
if I send my original unconverted file directly to the converter program, that byte is changed to A2
if I upload my original unconverted file to gtasnp and download the second link (converted), that byte is changed to A2 as well. These 2 files are identical.

So.... is this byte the checksum then? ...and the converter won't change it if the ID isn't changed?

My manually converted files (with the unchanged CE byte) showed up as corrupted saves in the Load menu and couldn't be loaded.

Samutz
  • Samutz

    if ($lol) { die(rofl()); }

  • Members
  • Joined: 17 Sep 2003

#3

Posted 27 June 2007 - 11:42 AM Edited by Samutz, 27 June 2007 - 11:46 AM.

This is the reference post that I used to find out more about the save format.
http://www.gtaforums...0

It states that the checksum is the last 4 bytes of the file.
To convert it to decimal (like the converter tool does), you start at the last byte and then read right to left.
Eg. if the bytes are 1A 2B 3C 4D; 4D3C2B1A hex = 1295788826 dec. 1295788826 is what the converter tool would show you.

The checksum is calculated by the "sum of all bytes" method meaning that if you took all the bytes except the last 4 (the checksum itself) and and added them all up, the result would equal the checksum. So when you change the id, you change that result, but only slightly. And then if you change the id, you have to recalculate the new checksum if you expect v2 to load the save.
At first glance the converter looks like it doesn't change the checksum, but if you look at the last few digits of the numbers if it gives you, they should be different (unless the id isn't being changed).
So if you try to load a v2 file, besides checking the ID, it also checks that result against the checksum.


rubregg
  • rubregg

    brainslug

  • Members
  • Joined: 03 May 2006

#4

Posted 28 June 2007 - 07:40 AM

Thanks Samutz, very well explained, I think everything's clear now icon14.gif

...so I did a bit of morning maths...

whenever I convert from my ID 83 E5 F3 65 (v1.00 with no-cd exe) to the v2 ID (F6 8D 14 FD), that will always result in the same change of the checksum: hex 83+E5+F3+65-F6-8D-14-FD = 2C

This means the checksum will get smaller by hex 2C = 00 00 00 2C.

My example file had a checksum of xx xx xx CE
subtracting 00 00 00 2C
gives xx xx xx A2

...and that's why the 4th byte from the end had to be changed from CE to A2. Which es exactly what the converter program did.

Sweet, when it all fits together in the end.... smile.gif

Samutz
  • Samutz

    if ($lol) { die(rofl()); }

  • Members
  • Joined: 17 Sep 2003

#5

Posted 03 July 2007 - 03:27 PM

Ok so, it's been a week and no one besides rubregg has said anything (btw thanks for the feedback rubregg biggrin.gif )
So I've gone ahead and replaced all the original download links with v2 links. And we'll see how it goes from there.
You can still download the original un-modified save files by clicking the "Switch to Non-Converted" link at the bottom of the download page.

HerrieM
  • HerrieM

    Don't Panic

  • Members
  • Joined: 27 Apr 2006

#6

Posted 04 July 2007 - 08:12 AM Edited by HerrieM, 04 July 2007 - 08:22 AM.

I'm a bit lost as to what is done by now?

So when you upload, you get a link. On that link the files should be v2????

First of all in this request the downloaded file was v1. Second of all (if i have understood it) i don't think it is a good idea to make all the links automaticly v2. I have v1 and use v1 whereever i can, but i think it would create a lot of confusion for unexperienced requesters (and there are a lot of them)

In the request i gave the url to i also see that the originaley uploaded file is a v1 Original and after i uploaded it is a v1 modified. Although i donīt have anything moddified on my GTA SA

ps. you're system also affects Vice City saves. When you had the beta up a uploaded vice city save would also have two sets of files. Now it also has that possibility to go to unconverted, although those links don't give a savegame. Possibly also happens with GA III saves, but i haven't tested that.

As for the rest, I appreciate your efforts of making the uploader better and better and better. I certainly like the info about what version it is.

rubregg
  • rubregg

    brainslug

  • Members
  • Joined: 03 May 2006

#7

Posted 04 July 2007 - 02:17 PM

QUOTE (Samutz @ Jul 3 2007, 17:27)
btw thanks for the feedback rubregg biggrin.gif

Glad to help, Samutz biggrin.gif

I've recently put a reminder up in the latest round of the chain game (not to convert savegames and test gtasnp's auto-conversion) and so far no one has complained about non-working saves.

I haven't tried vice city or gta3 saves yet, so I don't know if they are affected too. For SA however, I think that the current version of gtasnp is the one to go for. HerrieM, as far as I understood it it shouldn't matter if all files get converted, because v1 doesn't care about the ID. So both, converted and unconverted files should work in v1 (provided the right scripts are used). The way it is now, it's probably least confusing for new players.

Samutz
  • Samutz

    if ($lol) { die(rofl()); }

  • Members
  • Joined: 17 Sep 2003

#8

Posted 04 July 2007 - 03:59 PM

QUOTE (rubregg)
HerrieM, as far as I understood it it shouldn't matter if all files get converted, because v1 doesn't care about the ID. So both, converted and unconverted files should work in v1 (provided the right scripts are used). The way it is now, it's probably least confusing for new players.

Exactly.
There are only 2 things changed in the files when they are converted. The first is the version ID (set to v2's). The second is the checksum at the end of the file, which has to be changed if the ID is changed. Nothing else is changed that could prevent v1 from loading a save.

The III/VC thing is fixed. I simply forgot to add the "if is GTASA" checks to it.

HerrieM
  • HerrieM

    Don't Panic

  • Members
  • Joined: 27 Apr 2006

#9

Posted 04 July 2007 - 04:55 PM

As i now start to understand i was thinking wrong.
I know pdescobar ws working on a program that could change v1 saves into v2 saves and the other way around. I help him test it a little bit just before he went M.I.A. but you were talking about the SA ID changer... My mistake, sorry. rolleyes.gif

rubregg
  • rubregg

    brainslug

  • Members
  • Joined: 03 May 2006

#10

Posted 09 July 2007 - 06:22 AM

@Samutz
Sorry mate, but I think I spotted a bug. The unconverted files don't seem to be there. I tried 3 or 4 different links (files that do still exist) and whenever I tried downloading from the unconverted page I got the message "The requested file doesn't exist."

Samutz
  • Samutz

    if ($lol) { die(rofl()); }

  • Members
  • Joined: 17 Sep 2003

#11

Posted 09 July 2007 - 06:33 AM

Fixed. The download links on the converted page had the wrong url. blush.gif

Thanks for letting me know.

RichD
  • RichD

    Loose Cannon

  • Members
  • Joined: 14 Nov 2003

#12

Posted 15 July 2007 - 09:55 AM

Errr... pardon my ignorance, but what's all this v1/v2 stuff? I've been out of the loop for quite a while, is it a new patch version of the game or something??

rubregg
  • rubregg

    brainslug

  • Members
  • Joined: 03 May 2006

#13

Posted 15 July 2007 - 11:50 AM

QUOTE (RichD @ Jul 15 2007, 11:55)
Errr... pardon my ignorance, but what's all this v1/v2 stuff? I've been out of the loop for quite a while, is it a new patch version of the game or something??

v1 was the version first sold. Turned out there were some removed sex games still in the code that could be 'unlocked' via modding ('Hot Coffee Mod'). Since violence is fine but sex isn't, some scandal arose out of that and ever since then v1 was withdrawn by R* and v2 released. Same game, but sex scenes removed and afaik no longer moddable.

RichD
  • RichD

    Loose Cannon

  • Members
  • Joined: 14 Nov 2003

#14

Posted 15 July 2007 - 07:07 PM

QUOTE (rubregg @ Jul 15 2007, 11:50)
v1 was the version first sold. Turned out there were some removed sex games still in the code that could be 'unlocked' via modding ('Hot Coffee Mod'). Since violence is fine but sex isn't, some scandal arose out of that and ever since then v1 was withdrawn by R* and v2 released. Same game, but sex scenes removed and afaik no longer moddable.

Ahhhhh ok. I was aware of the Hot Coffee mod (I'd have to be on Mars not to) but it didn't occur to me that that would be what v2 meant. So, does my having v1 affect the SnP if I wanted to have someone do a mission for me?

GTAGangsta58
  • GTAGangsta58

    Street Cat

  • Members
  • Joined: 11 Apr 2007

#15

Posted 15 July 2007 - 07:10 PM

QUOTE (RichD @ Jul 15 2007, 14:07)
QUOTE (rubregg @ Jul 15 2007, 11:50)
v1 was the version first sold. Turned out there were some removed sex games still in the code that could be 'unlocked' via modding ('Hot Coffee Mod'). Since violence is fine but sex isn't, some scandal arose out of that and ever since then v1 was withdrawn by R* and v2 released. Same game, but sex scenes removed and afaik no longer moddable.

Ahhhhh ok. I was aware of the Hot Coffee mod (I'd have to be on Mars not to) but it didn't occur to me that that would be what v2 meant. So, does my having v1 affect the SnP if I wanted to have someone do a mission for me?

sort of, it just is so that v1 players can only do the SnP for u, if u had v2, then anybody could do the SnP for u, understand?

RichD
  • RichD

    Loose Cannon

  • Members
  • Joined: 14 Nov 2003

#16

Posted 16 July 2007 - 06:32 PM

QUOTE (GTAGangsta58 @ Jul 15 2007, 19:10)
sort of, it just is so that v1 players can only do the SnP for u, if u had v2, then anybody could do the SnP for u, understand?

Yep. Thanks for clearing it up. smile.gif




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users