Jump to content


Conflict with two tra files

3 replies to this topic

#1 StrongArmand

  • Members
  • 64 posts
  • Gender:Male

Posted 19 February 2012 - 07:05 AM

I've a problem for several month and I want to tell you in the hope of you could bring some help. I've include in my mod a kit mod wtih the author help and I've some difficulties with setup.tra.

Here in my tp2 :

LANGUAGE ~Francais~
~Devin/Translations/French/Setup.tra~ // my setup tra with all my entries
~Devin/Translations/French/Flammes.tra~ // the setup tra of the kit

The problem is that if ever i've a string called for example @112 and that flammes tra has the same ref, i've some problem/confilct in game. I'm looking for an alternative for isolate this piece of code (kit) in order to my two tra files don't trigger themselves.

Is it possible according to you ?

Edited by StrongArmand, 19 February 2012 - 07:06 AM.

#2 Miloch



  • Modders
  • 4749 posts
  • Gender:Male
  • Location:At Large

Posted 19 February 2012 - 12:58 PM

Try putting the setup.tra last in the list - I think that takes priority. Or you can just omit the flammes.tra but call it as needed when you COPY or COMPILE a file, just add USING ~...flammes.tra~ after each statement where you need it.
Infinity Engine Contributions
Aurora * BG1 NPC * BG1 Fixpack * Haiass * Infinity Animations * Level 1 NPCs * P5Tweaks
PnP Free Action * Thrown Hammers * Unique Containers * BG:EE * BGII:EE * IWD:EE
Player & Modder Resources
BAM Batcher * Creature Lister * Creature Checker * Creature Fixer * Tutu/BGT Area Map & List * Tutu Mod List
"The trouble with having an open mind, of course, is that people will insist on coming along and trying to put things in it." -Terry Pratchett

#3 Isaya

  • Members
  • 150 posts
  • Gender:Male
  • Location:Plaisir, France

Posted 19 February 2012 - 02:29 PM

WeiDU uses the tra files specified in the LANGUAGE section as defaut tra files to look for text references. If you have a dialog or script that reference @112 and that reference is not present in the tra file associated to the dialog or script (either implicitely, because the file has the same name, or explicitely with USING ...), WeiDU will also look for @112 in the two tra files stated in the LANGUAGE part.

WeiDU uses the tra files in LANGUAGE in reverse order. Some mods (Rogue Rebalancing, for instance) use that form:
LANGUAGE ~Francais~
This allows adding new things in the mod (English/Setup.tra) without preventing installation in French if a text is not translated yet. The english text will be used, but the mod will be installed.

If you're going to reference several tra files in LANGUAGE (for the same language), you should ensure that they use a different range of @nnn to avoid any kind of conflict.

If your dialogs are all starting at @0 or @1, it is also good practise to make all your tp2 text reference start at @10000, for instance (provided you don't have any dialog reaching that value), in order to be sure that a missing @nnn somewhere is discovered, instead of replacing a missing dialog text by a string intended for the tp2 (objet description or whatever).

#4 StrongArmand

  • Members
  • 64 posts
  • Gender:Male

Posted 23 February 2012 - 04:15 AM

Thanks for your replies. Yes indeed isaya I'm looking for several setup.tra in the same language. I think that the simplest way would be to rename my own setup.tra by a value more complicated (@104580 for example). It should be efficient.

Reply to this topic


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users