Adding new index to String.tbl f*cks everything.

Post here about all aspects of D2 mod making whether it's information, problems or whatever. Please specify whether your post is relating to Classic D2 or the Expansion.

Moderator: Nizari

Post Reply
User avatar
sean0262
Posts: 2
Joined: Tue Nov 27, 2018 10:21 am
Denmark

Adding new index to String.tbl f*cks everything.

Post by sean0262 » Mon Dec 03, 2018 9:52 am

Whenever I try to add a new index to string.tbl, it messes every other index order up. The menu index's(menu texts) get moved.

What should I do?

Sincerely, Sean.

User avatar
Ogodei
Senior Moderator
Champion of the Light
Posts: 440
Joined: Thu Mar 10, 2016 8:31 am
Italy

Hand-picked

Re: Adding new index to String.tbl f*cks everything.

Post by Ogodei » Mon Dec 03, 2018 10:06 am

I am moving this thread to General mod making.

Probably you are " inserting " rather han "adding". When you ' insert ', you create a brand new index in between two existing ones. This makes the game's code retrieve the wrong numeric index(es) and the result is a lot of messed up texts
Try adding your new index at the bottom of the .tbl file

User avatar
devurandom
Forum Regular
Angel
Posts: 656
Joined: Sat Mar 07, 2015 9:07 pm
United States of America

Re: Adding new index to String.tbl f*cks everything.

Post by devurandom » Mon Dec 03, 2018 11:01 am

String indices are hard coded. You can change an existing string to new one if that's the desired effect, or add new ones at the end of the file.
Assembly Reference | 1.13d Code Edits | UVLoD | BaseMod Plugin

The most dangerous man to any government is the man who is able to think things out... without regard to the prevailing superstitions and taboos. Almost inevitably he comes to the conclusion that the government he lives under is dishonest, insane, & intolerable." ~ H.L. Mencken

User avatar
Necrolis
Site Admin
Throne
Posts: 8941
Joined: Sat Mar 25, 2006 1:22 pm
Location: The Land of the Dead
Contact:
South Africa

Hand-picked

Re: Adding new index to String.tbl f*cks everything.

Post by Necrolis » Mon Dec 03, 2018 12:04 pm

It is generally recommended that you add strings to the end of patchstring.tbl; this is the file least likely to give issues, and will overwrite any older (non hardcoded) strings.
Image
Netiquette, Do you USE it?!?! | Nefarius' Fixed TXT Files | Terms Of Service
Blackened | Day of Death
"What was yours is mine. Your land, your people, and now your life." - Lim-Dul, the Necromancer
Judgement is Final, Death is Eternal

User avatar
sean0262
Posts: 2
Joined: Tue Nov 27, 2018 10:21 am
Denmark

Re: Adding new index to String.tbl f*cks everything.

Post by sean0262 » Mon Dec 03, 2018 2:01 pm

Thanks everyone, I'll try adding the new index to the bottom of patchstring.tbl, hopefully that works.


Is it "okay" to add weapons.txt index's to patchstring.tbl?


:)

Post Reply

Return to “General Mod Making”