Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Instructor
Original Poster
#1 Old 9th Oct 2021 at 2:47 AM
Default STBLizer Issues
Every time I type a text file of unhashed stbls and use STBLizer to create a .stbl file from it then the hashed number on the new stbl file is different from the actual one and so the strings and text are all messed up. What am I doing wrong and how do I fix it to get the right results?
Advertisement
Lab Assistant
#2 Old 9th Oct 2021 at 7:56 PM
Quote: Originally posted by t888
Every time I type a text file of unhashed stbls and use STBLizer to create a .stbl file from it then the hashed number on the new stbl file is different from the actual one and so the strings and text are all messed up. What am I doing wrong and how do I fix it to get the right results?

Don't use spaces and use lower case
Instructor
Original Poster
#3 Old 9th Oct 2021 at 8:25 PM
Quote: Originally posted by whiteman-Dara
Don't use spaces and use lower case

Didn't have any spaces and even when I changed uppercase to lower case I got the same as with uppercase, this:

0xDF1A0ABC5A84DEFA: gameplay/excel/careers/careerlist:catdaddy

the number should be 0x5962D19613E25B92.

Every time I use STBLizer instead of doing it manually I get messed up hashes like this It's kind of a PITA to do all manually.
Lab Assistant
#4 Old 10th Oct 2021 at 8:36 PM
Quote: Originally posted by t888
Didn't have any spaces and even when I changed uppercase to lower case I got the same as with uppercase, this:

0xDF1A0ABC5A84DEFA: gameplay/excel/careers/careerlist:catdaddy

the number should be 0x5962D19613E25B92.

Every time I use STBLizer instead of doing it manually I get messed up hashes like this It's kind of a PITA to do all manually.

where did you get this hash 0xDF1A0ABC5A84DEFA?
Everything is right gameplay/excel/careers/careerlist:catdaddy this hash 0x5962D19613E25B92!
3 years could not find which address, in this hash 0xa8907ba60bb65a57 what only I did not write but the hash did not correspond to this.
Instructor
Original Poster
#5 Old 10th Oct 2021 at 11:46 PM
Quote: Originally posted by whiteman-Dara
where did you get this hash 0xDF1A0ABC5A84DEFA?
Everything is right gameplay/excel/careers/careerlist:catdaddy this hash 0x5962D19613E25B92!
3 years could not find which address, in this hash 0xa8907ba60bb65a57 what only I did not write but the hash did not correspond to this.



0xDF1A0ABC5A84DEFA is the hash STBLizer gives me, which is incorrect.

0x5962D19613E25B92 is the number I get from manually hashing it and typing it in, as I always have to do to get the right hash as STBLizer always gives me incorrect ones for some reason I can't figure out.
Virtual gardener
staff: administrator
#6 Old 11th Oct 2021 at 10:54 AM
Heya @t888 !

First, off, STBLs are usually a PITA! So we've all been there

So a few things to know about hashing (which have been mentioned before here by Whiteman-dara )
  1. hashing is seemingly very upper/lowercase sensitive in most programs! So if in your code you have: Gameplay/Excel/Careers/Careerlist:Catdaddy, make sure to parse it in as such! Else if everything is lower case, you'll get a different hash!
  2. It doesn't do well with spaces, indeed use - or _ instead when you want to use it!
  3. Make sure that in your code your key is exactly the same as the STBL key you wanna hash! For example:

    Code:
    Localization.LocalizeString("Lyralei/Localized/setJournalOwner:InteractionName", new object[0])
    
    STBL key will be: Lyralei/Localized/setJournalOwner:InteractionName
    

  4. Buff, traits, careers, and any XML > parsed and made ready in the game 'mods' always need a "gameplay/excel/" + any other path EA gave it Which in your case seems correct!

Also! I personally find STBLizer a bit clunky to work with, so I usually use EasySTBLManager. The released version has some bugs but the one in the comment section seems to be working better for me

https://modthesims.info/download.ph...5#startcomments

(Also When I test it in EasyStblManager it seems to also see the key as 0x5962D19613E25B92 ! So i'm not sure what STBLizer is doing to parse it differently...)
Instructor
Original Poster
#7 Old 11th Oct 2021 at 5:24 PM
Quote: Originally posted by Lyralei
Heya @t888 !

First, off, STBLs are usually a PITA! So we've all been there

So a few things to know about hashing (which have been mentioned before here by Whiteman-dara )
  1. hashing is seemingly very upper/lowercase sensitive in most programs! So if in your code you have: Gameplay/Excel/Careers/Careerlist:Catdaddy, make sure to parse it in as such! Else if everything is lower case, you'll get a different hash!
  2. It doesn't do well with spaces, indeed use - or _ instead when you want to use it!
  3. Make sure that in your code your key is exactly the same as the STBL key you wanna hash! For example:

    Code:
    Localization.LocalizeString("Lyralei/Localized/setJournalOwner:InteractionName", new object[0])
    
    STBL key will be: Lyralei/Localized/setJournalOwner:InteractionName
    

  4. Buff, traits, careers, and any XML > parsed and made ready in the game 'mods' always need a "gameplay/excel/" + any other path EA gave it Which in your case seems correct!

Also! I personally find STBLizer a bit clunky to work with, so I usually use EasySTBLManager. The released version has some bugs but the one in the comment section seems to be working better for me

https://modthesims.info/download.ph...5#startcomments

(Also When I test it in EasyStblManager it seems to also see the key as 0x5962D19613E25B92 ! So i'm not sure what STBLizer is doing to parse it differently...)


Yeah, I don't get why STBLizer parses it differently either, makes no sense to me :/
Senior Moderator
staff: senior moderator
#8 Old 12th Oct 2021 at 11:20 AM
Are you using STBLizer as in this one https://modthesims.info/t/360093 ?
I like to use Buzzler's STBLize https://modthesims.info/d/565291/stblize.html which I haven't had any issues with regarding messed up hashes, so if you like the method of converting text files to STBLs hopefully this will work for you
Instructor
Original Poster
#9 Old 14th Oct 2021 at 1:55 AM
Quote: Originally posted by zoe22
Are you using STBLizer as in this one https://modthesims.info/t/360093 ?
I like to use Buzzler's STBLize https://modthesims.info/d/565291/stblize.html which I haven't had any issues with regarding messed up hashes, so if you like the method of converting text files to STBLs hopefully this will work for you

Actually the second one was the one I meant. I wish it would work for me but for some reason I just can't get it too. Hey can you try the line in a post above and see if you get the right hash or a wrong one as well?
Senior Moderator
staff: senior moderator
#10 Old 14th Oct 2021 at 1:20 PM
Sure, I made a text file with:
Code:
<?xml version="1.0"?>
<TEXT>

<KEY>gameplay/excel/careers/careerlist:catdaddy</KEY>
<STR>Test</STR>

</TEXT>


and the result I got was 0x5962D19613E25B92: Test

So all seems good there. I wonder if the issue is with the formatting of the text file?
Instructor
Original Poster
#11 Old 14th Oct 2021 at 8:46 PM
Quote: Originally posted by zoe22
Sure, I made a text file with:
Code:
<?xml version="1.0"?>
<TEXT>

<KEY>gameplay/excel/careers/careerlist:catdaddy</KEY>
<STR>Test</STR>

</TEXT>


and the result I got was 0x5962D19613E25B92: Test

So all seems good there. I wonder if the issue is with the formatting of the text file?

I expect its more of an issue when I'm trying to do the unhashed file

<?xml version="1.0"?>
<TEXT>

<KEY>0x5962D19613E25B92</KEY>
<STR>Gameplay/Excel/Careers/CareerList:CatDaddy</STR>

</TEXT>
Senior Moderator
staff: senior moderator
#12 Old 16th Oct 2021 at 3:40 PM
Ahah! Well that's your issue there. <KEY> is for the string that gets hashed into the key. SO here, 0x5962D19613E25B92 is being hashed into 0xDF1A0ABC5A84DEFA.
From what I understand, the unhashed file is for reference, so if someone looking at the package and the STBLs and they want to know what string should generate the key of a particular entry, they can look at the unhashed keys file to find the key, and the corresponding STR which would give the string that's hashed to get the key.
It's not actually necessary for the package/stbls/mod to function.

The purpose of the STBLize tool is to make an STBL without having to deal with calculating any hashes yourself. You work with just the string that appears in game, and the key which is the string the generates the hash, and the tool takes care of making the STBL with the correct hashes.

If you're lazy like me, you don't bother with the unhashed key file, and just keep the text file which has the string keys in the <KEY> tags :p
Though if you do want to make one, it's probably just as time consuming to make it manually in S3PE as it is in a text file > stbl as you'll have to copy in the hashes yourself either way, so you may as well directly do it there. Or put the same thing in the KEY tag as the STR tag, as it's SIms3/Gameplay/... that gets hashed into the hash you want, not the hash itself...have I made it confusing enough?
The benefit of the tool is that you don't need to spend time calculating the hashes and copying them in anywhere.
Instructor
Original Poster
#13 Old 16th Oct 2021 at 4:37 PM
Quote: Originally posted by zoe22
Ahah! Well that's your issue there. <KEY> is for the string that gets hashed into the key. SO here, 0x5962D19613E25B92 is being hashed into 0xDF1A0ABC5A84DEFA.
From what I understand, the unhashed file is for reference, so if someone looking at the package and the STBLs and they want to know what string should generate the key of a particular entry, they can look at the unhashed keys file to find the key, and the corresponding STR which would give the string that's hashed to get the key.
It's not actually necessary for the package/stbls/mod to function.

The purpose of the STBLize tool is to make an STBL without having to deal with calculating any hashes yourself. You work with just the string that appears in game, and the key which is the string the generates the hash, and the tool takes care of making the STBL with the correct hashes.

If you're lazy like me, you don't bother with the unhashed key file, and just keep the text file which has the string keys in the <KEY> tags :p
Though if you do want to make one, it's probably just as time consuming to make it manually in S3PE as it is in a text file > stbl as you'll have to copy in the hashes yourself either way, so you may as well directly do it there. Or put the same thing in the KEY tag as the STR tag, as it's SIms3/Gameplay/... that gets hashed into the hash you want, not the hash itself...have I made it confusing enough?
The benefit of the tool is that you don't need to spend time calculating the hashes and copying them in anywhere.



Ah! I see! That makes sense. I was just following a tutorial but hmm, next time I have to give it a try the way you're suggesting and see how that goes!
Lab Assistant
#14 Old 17th Oct 2021 at 10:14 AM
Quote: Originally posted by t888
Ah! I see! That makes sense. I was just following a tutorial but hmm, next time I have to give it a try the way you're suggesting and see how that goes!

your mistake in incorrect string format:
<?xml version="1.0"?>
<TEXT>

<KEY>5962D19613E25B92</KEY>
<STR>Cat Daddy</STR>

</TEXT>
I think this format will be correct.
Instructor
Original Poster
#15 Old 18th Oct 2021 at 6:26 AM
Quote: Originally posted by whiteman-Dara
your mistake in incorrect string format:
<?xml version="1.0"?>
<TEXT>

<KEY>5962D19613E25B92</KEY>
<STR>Cat Daddy</STR>

</TEXT>
I think this format will be correct.


Wait, so in the key I don't even need the 0x? And in the strings I don't need the Gameplay/Excel/Careers/CareerList? Don't I need that last part in the unhashed version though? I mean it might not be necessary but I still like to do it in case I publish it, perhaps someone who knows other languages better than I can make a translation.

</TEXT>
Senior Moderator
staff: senior moderator
#16 Old 18th Oct 2021 at 2:26 PM
What you put in <KEY> matters a lot, as what's in it will be hashed to create the STBL's entry's key.
For the in-game strings, you will just put "Cat Daddy", but you're right that for the unhashed keys file you put Gameplay/Excel/Careers/CareerList:catDaddy, because the point of the file is to know the phrase Gameplay/Excel/Careers/CareerList:catDaddy.

So actually when I said:
Quote:
Or put the same thing in the KEY tag as the STR tag

Please ignore that because it's wrong
If you do that, then you'll get a key in the unHashedKeys STBL that's the same as a key in the actual career strings STBL, and they will conflict.

What you did originally was actually correct:
<?xml version="1.0"?>
<TEXT>
<KEY>0x5962D19613E25B92</KEY>
<STR>Gameplay/Excel/Careers/CareerList:CatDaddy</STR>
</TEXT>

This will create an STBL entry 0xDF1A0ABC5A84DEFA : Gameplay/Excel/Careers/CareerList:CatDaddy and that's exactly what you want for making the UnHashedkeys file.

Now the other thing I want to mention - I'm not sure how much more of the careers tutorial you've gone through, but for when it comes to making the STBL for the actual in-game strings, the tutorial I believe has it done manually, where the entries are added one by one with s3pe. The reason the creator MissyHissy did this is because she had issues with non English characters not showing up correctly when converting the text file to the STBL with the tool. However, we actually found out this was due to the text file using the wrong encoding not an issue with the tools, so it should be fine to make the game strings STBL using the same method, making a text file then generating an STBL from it.

So if you do it this way, you will have a text file like:

<?xml version="1.0"?>
<TEXT>
<KEY>Gameplay/Excel/Careers/CareerList:CatDaddy</KEY>
<STR>CatDaddy</STR>
</TEXT>

And this will generate an STBL with an entry: 0x5962D19613E25B92 : Cat Daddy
So you can see that "Cat Daddy" will appear in game, and the hash is generated from the string "Gameplay/Excel/Careers/CareerList:CatDaddy"
The point (at least I think it's the point :p) of the UnhashedKeys file, is so if you or someone saw the STBL entry "0x5962D19613E25B92 : Cat Daddy" and needed to know what was the string that creates the hash 0x5962D19613E25B92, you would find out by hashing 0x5962D19613E25B92 to get 0xDF1A0ABC5A84DEFA , and looking though the UnhashedKeys file to find the key 0xDF1A0ABC5A84DEFA, and you'll see the corresponding string is Gameplay/Excel/Careers/CareerList:CatDaddy which is what you wanted to find.

I hope this makes sense :p
Instructor
Original Poster
#17 Old 20th Oct 2021 at 3:14 AM
Quote: Originally posted by zoe22
What you put in <KEY> matters a lot, as what's in it will be hashed to create the STBL's entry's key.
For the in-game strings, you will just put "Cat Daddy", but you're right that for the unhashed keys file you put Gameplay/Excel/Careers/CareerList:catDaddy, because the point of the file is to know the phrase Gameplay/Excel/Careers/CareerList:catDaddy.

So actually when I said:

Please ignore that because it's wrong
If you do that, then you'll get a key in the unHashedKeys STBL that's the same as a key in the actual career strings STBL, and they will conflict.

What you did originally was actually correct:
<?xml version="1.0"?>
<TEXT>
<KEY>0x5962D19613E25B92</KEY>
<STR>Gameplay/Excel/Careers/CareerList:CatDaddy</STR>
</TEXT>

This will create an STBL entry 0xDF1A0ABC5A84DEFA : Gameplay/Excel/Careers/CareerList:CatDaddy and that's exactly what you want for making the UnHashedkeys file.

Now the other thing I want to mention - I'm not sure how much more of the careers tutorial you've gone through, but for when it comes to making the STBL for the actual in-game strings, the tutorial I believe has it done manually, where the entries are added one by one with s3pe. The reason the creator MissyHissy did this is because she had issues with non English characters not showing up correctly when converting the text file to the STBL with the tool. However, we actually found out this was due to the text file using the wrong encoding not an issue with the tools, so it should be fine to make the game strings STBL using the same method, making a text file then generating an STBL from it.

So if you do it this way, you will have a text file like:

<?xml version="1.0"?>
<TEXT>
<KEY>Gameplay/Excel/Careers/CareerList:CatDaddy</KEY>
<STR>CatDaddy</STR>
</TEXT>

And this will generate an STBL with an entry: 0x5962D19613E25B92 : Cat Daddy
So you can see that "Cat Daddy" will appear in game, and the hash is generated from the string "Gameplay/Excel/Careers/CareerList:CatDaddy"
The point (at least I think it's the point :p) of the UnhashedKeys file, is so if you or someone saw the STBL entry "0x5962D19613E25B92 : Cat Daddy" and needed to know what was the string that creates the hash 0x5962D19613E25B92, you would find out by hashing 0x5962D19613E25B92 to get 0xDF1A0ABC5A84DEFA , and looking though the UnhashedKeys file to find the key 0xDF1A0ABC5A84DEFA, and you'll see the corresponding string is Gameplay/Excel/Careers/CareerList:CatDaddy which is what you wanted to find.

I hope this makes sense :p

Yeah, that makes sense. Matter of a fact, I'd say thats probably been the best explanation for the whole STBL process I've seen. Thank you a lot!
Back to top