Author Topic: Making proper installation package  (Read 8927 times)

Vlad

  • Guest
Making proper installation package
« on: July 24, 2002, 01:51:03 PM »
I have a new module (partial conversion), which I am going to release soon. Now I have three options to distribute it:

1) To distribute it as it is including my own DIALOG.TLK.
2) To use IAP-SFX filled with TBG files.
3) WeiDU with TP2.

1) Since my module is a totally new (and long) game, the first option looks fine, since it doesn't require any additional knowledge and work from me, and any other mods could be installed over my own.
2) IAP-SFX looks also nice if it's checked for errors in advance before distribution. Moreover, Cat's IDU is actually much more user-friendly than command-line software.
3) Could you give me more information on installation issues, their advantages before 1) and 2), and the detailed step-by-step instructions with a working example how to make installation pakage from different type of files including .d, .cre, itm., .mos, wav., .bam and so on? I am not a UNIX-man, and I have never worked in command line environment like DOS or LINUX console, so please take this into account and do not refer me to the WeiDU README file (Section VII. Module Packaging). Thank you in advance.

P.S. BTW, what's about .oggs? How is it possible to convert .wavs to .oggs?                    



[!--EDIT|Vlad|Jul 24 2002, 09:26 PM--]

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #1 on: July 24, 2002, 02:50:37 PM »
Vlad, there are several working examples of how to install a mod with new .dlg, .itm, .bam, etc. files out there: Kelsey, Tashia, Ascension, Solaufein, Valen, Item Upgrade, etc. Investigating their .tp2 files will tell you a lot about how the format works.

So far, nobody to my knowledge has used the WeiDU/TP2 install approach to do a conversion game that obliterates the core game content so it's hard to say from experience why it might be better.  It would certainly be a good approach for patches to that game, even if you chose the .tlk/override overwrite approach for the initial installer.

.ogg files are Ogg Vorbis audio compression (www.vorbis.com, www.xiph.org for more info), and we use the oggdec.exe binary to convert them back to .wav. WinLAME (winlame.sourceforge.net) is my Ogg encoder of choice, but there are many others.
                   
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Vlad

  • Guest
Making proper installation package
« Reply #2 on: July 26, 2002, 06:32:20 AM »
Thanks. My new module has nothing to do with conversion. It's a pure original creation including scenario, dialogues, quests, music, sounds, and even partially graphics.

                   

Offline Quitch

  • Perfection
  • Planewalker
  • *****
  • Posts: 270
  • Making the world a better place for evil
Making proper installation package
« Reply #3 on: July 26, 2002, 10:01:53 AM »
IDU may seem more user friendly, but it is not an easier tool to use.  Not only that, but it can be unstable.  You risk losing a lot of work.  Fine, you think, you'll save a lot.  Well, I've had that force crashes and corrupt files I was working on.

Not only that, but when it comes to distributing your mod, you have to put out an 8MB file, which then would instantly override any other dialogue people had installed, thus forcing them to reinstall all their mods.

So you've immediately put off a large section of the audience through:

a) file size

B) compatability issues

Plus, you can't edit very much using IDU.  You usually have to delete a load of stuff just to roll back.

Use WeiDU :)                    
Past: Ascension
Present: Return to Windspear
Future: Imoen Relationship
"Perfection has no deadline"

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #4 on: July 26, 2002, 10:35:46 AM »
Quote
Not only that, but when it comes to distributing your mod, you have to put out an 8MB file, which then would instantly override any other dialogue people had installed, thus forcing them to reinstall all their mods.

You CAN use TeamBG's IETMC to export individual .DLGs and new strings, rather than doing a complete .tlk obliteration. In that event, you're "only" killing any changes people might have made to the other .DLG. This is still unacceptable, in my view, for changes that affect the BG2 gameworld.

But in this case, Vlad seems to be talking about something that completely overlays the entire game... in which case the right answer isn't quite as clear.

However, regardless of the install format, I'll still endorse WeiDU over IDU any day. For anything more than a trivial dialogue of a state or two, WeiDU is faster than IDU. Substantially faster. Like, order-of-magnitude faster.

Variables rather than absolute state number references.
Multi-say.
CHAIN/CHAIN2/CHAIN3.
APPEND.
COPY_TRANS.
INTERJECT.
WEIGHT and easily re-sortable states and state triggers.
The ability to split up and re-integrate development work easily. (You can't have two people working on the same .DLG at the same time in IDU. Doesn't fly. You'll never get it back together.)

Oh, I do go on, but that's because WeiDU just works that much better.

Quote
Plus, you can't edit very much using IDU.  You usually have to delete a load of stuff just to roll back.

Yes. Your states are fixed in place when you create them. One need look no further than the trouble the Shadows Over Soubar developer has had, where he's having to rebuild several dialogues either because of IDU's destruction of state trigger lists or the fact that, once put in place, you can't move a state.
                   
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Vlad

  • Guest
Making proper installation package
« Reply #5 on: July 29, 2002, 09:33:38 AM »
JC and Quitch, thanks for your comments. I'll take them into consideration. But you're not right in a few main points here. I have a wonderful program called BG2 TLK Editor, which supplements IDU and recompensates all the disadventages of IDU, which you've already mentioned. It's just a perfect pair for working with dialogues. TLK Editor allows the same functions that WeiDU does from the command line, and much more. But it's really user friendly. TLK Editor allows to modify, clear, append, replace, substitute, find, translate any single string, and to convert the whole dialog.tlk to text format and back to binary. Moreover, it works perfectly in combination with IDU. The only problem in working with this pair of programs that not to forget close any other applications using IE while saving dialogs in IDU. All the dialogues prepared with IDU-TLK Editor may be extracted rapidly with IETMC from DIALOG.TLK for further distribution. If you experience technical problems with IDU, it means you do something wrong, which cause the further crash in .tbg files. Now, about WeiDU. I simply cannot be used to its command line functions. And I cannot understand how it works. The great tutorial of Ghrey helped me a lot, but I expect something on actual installation, making .tp2 files and further distribution. I have no time to learn WeiDU language browsing corresponding files of other WeiDU mods. Sorry, I need something fast and user-friendly (something with nice GUI). I think it's a general requirement of any user for today. I have no idea about DOS and UNIX, and I don't want to mess with it. So if you could release the detailed tutorial on WeiDU how to make a single module and distribute it from A to Z (step-by-step manual), it will be great.                    



[!--EDIT|Vlad|Jul 29 2002, 04:41 PM--]

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #6 on: July 29, 2002, 10:33:36 AM »
Quote
I have no time to learn WeiDU language browsing corresponding files of other WeiDU mods. Sorry, I need something fast and user-friendly (something with nice GUI). I think it's a general requirement of any user for today. I have no idea about DOS and UNIX, and I don't want to mess with it. So if you could release the detailed tutorial on WeiDU how to make a single module and distribute it from A to Z (step-by-step manual), it will be great.
                   Vlad, I know that English is not your first language so I'd just like to point out that the way you're phrasing this makes it difficult to be sympathetic to your problems.

I'll be the first to admit that I like asking questions about things I don't understand (about WeiDU, or anything else in life) but you have basically said "I do not have the time or inclination to learn this, but if you spell everything out for me, maybe I will use it."

And to that I repeat: there are WeiDU mods both large and small out there that you can look at. We learned how to code Kelsey by looking at Solaufein and asking lots of specific questions. You, too, can ask all sorts of questions about how .TP2 installer commands work, how advanced or basic .d functions work, or whatever.

And perhaps someday there will be a .TP2 install tutorial, an A-to-Z breakdown of how a major project is constructed in .d, and more. But to tell us that you have no time to learn... well, that's a shame, but ultimately it is your responsibility.

                   
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #7 on: July 29, 2002, 10:37:00 AM »
Quote
I have a wonderful program called BG2 TLK Editor, which supplements IDU and recompensates all the disadventages of IDU, which you've already mentioned. It's just a perfect pair for working with dialogues. TLK Editor allows the same functions that WeiDU does from the command line, and much more. But it's really user friendly. TLK Editor allows to modify, clear, append, replace, substitute, find, translate any single string, and to convert the whole dialog.tlk to text format and back to binary. ... All the dialogues prepared with IDU-TLK Editor may be extracted rapidly with IETMC from DIALOG.TLK for further distribution.
                   That's nice, but if you distribute with IETMC/TBG, you will still be overwriting any modifications that are already installed on the user's computer. This in no way replicates WeiDU's EXTEND/APPEND abilities, because in WeiDU, those take place at the point of INSTALLATION, not on the developer's computer.

I repeat: You are killing any changes people might have made to the .DLG. This is still unacceptable, in my view, for changes that affect the BG2 gameworld.

And you're still not getting capabilities like multi-say, CHAIN/2/3 and INTERJECT.                    
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Vlad

  • Guest
Making proper installation package
« Reply #8 on: July 29, 2002, 12:36:56 PM »
JC, there is no offence in my words at all. I am sorry if you think so. I really like your approach, and probably WeiDU is the best in the BG modding world today. But I cannot understand how you preserve the user's .dlg without modifying it. It's a first law of thermodynamics. You  cannot add something without changing the total weight of the product. For example, if I have already JAHEIRA.DLG modified, then you modify it once more in order to add new strings (it doesn't matter what software you use, you just add new strings to the end of the file). Then if I need to modify this file myself again, I add again a number of strings to the end of this file. So how uninstallation works in this case? You cannot erase just a few strings in the middle of the file. Or may be I am wrong? If I am right, so I cannot see any technical difference produced by using WeiDU or IDU. Whatever you do, you just change the original file. So what's the catch? Please, explain me.                    

japheth

  • Guest
Making proper installation package
« Reply #9 on: July 29, 2002, 01:08:18 PM »
Quote
JC, there is no offence in my words at all. I am sorry if you think so. I really like your approach, and probably WeiDU is the best in the BG modding world today. But I cannot understand how you preserve the user's .dlg without modifying it. It's a first law of thermodynamics. You  cannot add something without changing the total weight of the product. For example, if I have already JAHEIRA.DLG modified, then you modify it once more in order to add new strings (it doesn't matter what software you use, you just add new strings to the end of the file). Then if I need to modify this file myself again, I add again a number of strings to the end of this file. So how uninstallation works in this case? You cannot erase just a few strings in the middle of the file. Or may be I am wrong? If I am right, so I cannot see any technical difference produced by using WeiDU or IDU. Whatever you do, you just change the original file. So what's the catch? Please, explain me.
Okay, I'll try to explain this to you from a WeiDU POV.

If you make an installation package with WeiDU that modifies jaheira.dlg, you can append to and extend the dialog file without overwriting someone else's work.

Example: Vlad, let's say you decide to package everything up in WeiDU format.  You issue the appropriate commands within your .d file to say, append a new state to jaheira.dlg and to add a transition at a given state.  (We'll say state 6 for argument's sake.)

Now the end user installs your mod and jaheira.dlg becomes modified to include your new state and transition.

If that user installs another mod which modifies jaheira.dlg, WeiDU automatically keeps track of the "order" the mods are installed in, so that if they were to uninstall your mod first (which is the first mod in the install order), WeiDU will automatically go through and install any mod after your mod to ensure that the previous mods are kept alive and working.

This ensures that you don't get multiple instances of the same transition/state triggers within one dialog file.

Hopefully that kind of made sense.                    

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #10 on: July 29, 2002, 02:45:18 PM »
Quote
JC, there is no offence in my words at all.

It wasn't so much a question of offense, as just not inspiring sympathy. Frankly, Ghrey and I lost a lot of time because we looked at the predecessor to WeiDU and said "Ugh, that looks too complicated" and ignored it for several months, and we regret our mistake, and it's frustrating to see others make that same mistake.

Quote
For example, if I have already JAHEIRA.DLG modified, then you modify it once more in order to add new strings (it doesn't matter what software you use, you just add new strings to the end of the file). Then if I need to modify this file myself again, I add again a number of strings to the end of this file. So how uninstallation works in this case?

You may not be understanding something.

When a user installs a .tlk/override based mod (Ascension Classic, SoS, etc.) or a TBG/IAP-based mod, a new .DLG is COPIED OVER. It OVERWRITES whatever .DLG was there before.

When a user installs a WeiDU-based mod (that is making proper use of WeiDU's capabilities), there is no _copying_ being done. The .DLG on the user's computer is being _modified in place._

Consider this scenario.

Let's say there are two mods. A WeiDU-based mod called "Play Dominos With Jaheira" and a TBG/IAP based mod called "Play Bingo With Jaheira."

Both modders define new states so that when you click to talk to Jaheira, she'll play a game with you.

HOWEVER, when you install the TBG/IAP based mod (or if you use a .tlk/override copy method), a new JAHEIRAJ.DLG file is copied over.This overwrites anything that may have previously been done to JAHEIRAJ.DLG.

So if WeiDU Dominos was installed, and then TBG/IAP or .tlk/override based Bingo was installed LATER, Dominos would be wiped out. Obliterated.

When WeiDU Dominos is installed, however, it takes the JAHEIRAJ.DLG file installed on the user's computer and adds the states to it. That means if you put in Bingo, THEN Dominos, both games will be there.

So, let's make this clear:

When you do IAP/TBG install or .tlk/override install, you are NOT appending to the .DLG already installed on the user's computer, you're simply sending them YOUR (You, the modder) .DLG.

When you do WeiDU install, you ARE appending to the .DLG already installed on the user's computer.

As for uninstallation, .TP2 installers allow you to define a backup directory, so that the previous state of any file you change is stored, and can be RESTORED if your MOD is removed. Furthermore, WeiDU now tracks the install order of MODs, so you can actually uninstall a mod installed BEFORE a few others and things (should) still work right.                    
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Elhoe

  • Guest
Making proper installation package
« Reply #11 on: July 29, 2002, 04:55:51 PM »
Hi there,

I think I can see Vlad's point of view as I have been doing things similarly to him (I presume).

I think Vlad is saying (if not, then I'm saying) what about if a WeiDU-based mod called "Play Dominos With Jaheira" and a TBG/IAP based mod called "Play Dominos With Jaheira, (the way she plays dominos are different, but the triggers are the same) something has to give. Both cannot take place at the same time its either one or the other.

If the triggers are exactly the same then she can't play both versions of Dominos. I suppose this depends on one modder knowing what another is doing and its not something easily solvable and not the fault of the tool or author. Let me know if someone has found a solution.

From what I have read so long as the triggers are not exactly the same then there isn't a problem with WeiDU appending dialogs.



The other thing I totally agree with Vlad...

Quote
Now, about WeiDU. I simply cannot be used to its command line functions. And I cannot understand how it works. The great tutorial of Ghrey helped me a lot, but I expect something on actual installation, making .tp2 files and further distribution. I have no time to learn WeiDU language browsing corresponding files of other WeiDU mods. Sorry, I need something fast and user-friendly (something with nice GUI). I think it's a general requirement of any user for today. I have no idea about DOS and UNIX, and I don't want to mess with it.

this is exactly what I think about WeiDU as well. I am not a programming whiz I spent several hours with WeiDU trying out the more advanced functions and I just hated all this DOS business. (Hell it took me a while to find how to get into DOS as Windows ME hides it away! the Dosprompt didn't work and eventually I found Command.com did work - told you I'm no whiz)

Please, please, please Wesley or someone else make it more user friendly especially getting at the more advanced functions. I totally agree with Vlad about a GUI - not just for dialogs but for things like this (please note I was trying to convert exisitng mods at the time):

1) New text screens .2da files. How do I append to my new .2da text screen files with the new strings.
2) How to append to an existing .bcs file?
3) If I create a .bcs file and some new strings in Near Infinity how will WeiDU know which new string to display when using DisplayStringHead etc?
4) new journal entry strings?
5) Strings for map notes.

I spent hours trying to convert some of my existing mods but gave up when I hit these sort of problems. I think they are most likely possible but is buried somewhere and the current GUI by Raistlin (?) doesn't give access to these sort of functions. A WeiDU type mass converter would be useful too :D but I maybe stretching it.

If I cannot do something constructive with a tool with 5-10 mins it gets binned. Dialogs isn't essential to my mods so struggling with a tool on something not important to me is just the excuse I need   :P  I don't like typing - give me something to click!

Anyway its always good to see somebody coming up with something constructive so keep up the good work Wes, JC and co.
                   

Offline Ghreyfain

  • PPG
  • Planewalker
  • *****
  • Posts: 4705
  • Gender: Male
    • Pocket Plane Group
Making proper installation package
« Reply #12 on: July 29, 2002, 05:30:21 PM »
Quote
I think Vlad is saying (if not, then I'm saying) what about if a WeiDU-based mod called "Play Dominos With Jaheira" and a TBG/IAP based mod called "Play Dominos With Jaheira, (the way she plays dominos are different, but the triggers are the same) something has to give. Both cannot take place at the same time its either one or the other.

Okay, but before installing "Play Dominos with Jaheira", you had installed the "Jaheira spouts poetry" mod.

"Dominos" and "Poetry" mods both edit Jaheira.dlg, so a plain SoA install would look like this:

Jaheira.dlg has 5 states.
Dialog.tlk has 5 strings (small game ;) )

By installing "Poetry" mod, it changes it to this.  It can be any of the three install types.

Jaheira.dlg has 5 states, +1 state from mod.   Dialog.tlk has 6 strings.


Now let's install the IAP version of "Dominos" mod.

Jaheira.dlg has the same states as the developer's version.  5 states +1 state.  Dialog.tlk now has 7 strings (base, Poetry, and Dominos)

So now you can't play the Poetry mod, because jaheira.dlg only has the base + Domino states.


But if we installed the WeiDU version of "Dominos", it'd look like this.

Jaheira.dlg, 5 states (base), +1 (peotry), +1 (dominos), for a total of 7.
Dialog.tlk would have 5, +1, +1.

So now the player can play either the poetry or dominos mod.  This is what we mean by "APPEND", which is the command you'd use your WeiDU .d file to add to an existing .dlg.


Quote
If the triggers are exactly the same then she can't play both versions of Dominos. I suppose this depends on one modder knowing what another is doing and its not something easily solvable and not the fault of the tool or author. Let me know if someone has found a solution.

No, you wouldn't want to play two versions of the same mod, i.e. Ascension in it's original form (entire dialog.tlk) AND it's WeiDU form (appends to scripts, .dlg's, and dialog.tlk).

Quote
1) New text screens .2da files. How do I append to my new .2da text screen files with the new strings.

This is where looking at another .tp2 would be useful, but I agree that it's hard searching through everything yourself.

I can't remember where I saw it, but I have done it successfully.

COPY ~KelseyToB\Epilogues\FWKelsZZ.2da~ ~override\FWKels03.2da~
  REPLACE ~99999~ ~The text for epilogue #3 goes here.~

COPY ~KelseyToB\Epilogues\FWKelsZZ.2da~ ~override\FWKels04.2da~
  REPLACE ~99999~ ~Epilogue #4 goes here~

COPY ~KelseyToB\Epilogues\FWKelsZZ.2da~ ~override\FWKels05.2da~
  REPLACE ~99999~ ~Epilogue #5 goes here~


As you can see I'm using the same source file to make multiple files in the override.  The source file looks like this:

2DA V1.0
*J#KlsyL
                        0           1
SWITCH                  DEFAULT     DEFAULT
DEFAULT                 71020       99999
DWARF                   0           0
ELF                     0           0
HALFELF                 0           0
etc.

So you can see that I am replacing 99999 with whatever text I want, which is added to the dialog.tlk by WeiDU, and the .2da is modified accordingly.  If the new strref for my epilogue is 87654, then the .2da would have 87654 instead of 99999.

Quote
2) How to append to an existing .bcs file?

You would write a little .bcs of your custom additions, AddVicky.bcs for instance, and in the .tp2 you'd have the command:

EXTEND_BOTTOM (or TOP) ~viconi25.bcs~ ~Kelsey\Scripts\AddVicky.bcs~

This would look through the .bif's and override for viconi25.bcs, and add your custom stuff to the bottom (or top).

Quote
3) If I create a .bcs file and some new strings in Near Infinity how will WeiDU know which new string to display when using DisplayStringHead etc?

In the .bcs itself you'd have the command...
DisplayStringHead(Myself,999999)

And in the .tp2 you'd do...
COPY ~Kelsey\Scripts\script.bcs~ ~override\Script.bcs~
  REPLACE ~999999~ ~This is the text I want for DisplayStringHead()~

Quote
4) new journal entry strings?

Not sure about this, as I haven't done it.  I believe japheth has, however, so maybe he'll answer if he gets time.

Quote
5) Strings for map notes.

Again, haven't done this, and I think .are editing is one of the few places where WeiDU is very hard to edit with.  One method springs to mind, however.  Not too sure how well it'd work.

COPY ~Kelsey\Areas\MyArea.are~ ~override\MyArea.are~
  REPLACE ~123456~ ~This is a map note.~  (Where 123456 is the string you entered for the map note)

If it's an entirely original area, then IAP/TBG is probably the best solution.  I think it does .are's properly.  If you're modifying an existing area then things get tricky if you don't want to overwrite other people's work.

Quote
I spent hours trying to convert some of my existing mods but gave up when I hit these sort of problems. I think they are most likely possible but is buried somewhere and the current GUI by Raistlin (?) doesn't give access to these sort of functions. A WeiDU type mass converter would be useful too :D but I maybe stretching it.

Do you mean like de-compiling a lot of .dlg's to .d format?  I think you can do that by putting all .dlg's in a given folder, and typing something in.  Personally, I rarely use the command line, just .tp2's.

There's a base .tp2 in the WeiDU package called mymod.tp2.  All you need is this, pretty much:

BACKUP ~mymod/backup~   // the folder things will be backed up to
AUTHOR ~weimer@cs.berkeley.edu~    // when an error message happens, WeiDU says "Send error reports to this e-mail address"

BEGIN ~Component 1 of your mod~

(Insert installation commands here)

BEGIN ~Optional Component 2~

(more commands)

To find out which commands you actually need, read the readme.txt for WeiDU (in the .tp2 section), and if you have any questions, ask 'em.                    



[!--EDIT|Ghreyfain|Jul 29 2002, 05:34 PM--]
Earn Money Sleeping.

japheth

  • Guest
Making proper installation package
« Reply #13 on: July 29, 2002, 05:43:49 PM »
Yes, I have successfully been able to add and delete journal entries using WeiDU.  It's relatively simple.  Just make sure that all the dialogs that you'll be adding and deleting journal entries in are contained within the same .d file.

Example:
BEGIN JIM

IF ~NumTimesTalkedTo(0)~ THEN BEGIN JIM1
SAY ~Hey, can you help me find my rabbit?~
IF ~~ THEN REPLY ~Sure Jim.~ DO ~AddJournalEntry(99999,QUEST)
SetGlobal("JimRabbitQuest","GLOBAL",1)~ EXIT
END

IF ~Global("JimRabbitQuest","GLOBAL",1)~ THEN BEGIN JIM2
SAY ~Have you found my rabbit?~
IF ~Global("RabbitFound","GLOBAL",1)~ THEN REPLY ~Yep, it's right here.~ DO ~EraseJournalEntry(99999)
SetGlobal("JimRabbitQuest","GLOBAL",2)~ EXIT
IF ~~ THEN REPLY ~Nope, sorry Jimbo.~ EXIT
END

IF ~Global("JimRabbitQuest","GLOBAL",2)~ THEN BEGIN JIM3
SAY ~Thanks again for saving my rabbit.~
IF ~~ THEN REPLY ~No problem Jim.~ EXIT
END

And then within your .tp2 file (the .tp2 file is the file you set up for installing your mod on the end users machine) you issue this statement.

COMPILE ~jim.d~
REPLACE ~99999~ ~You've been sent on a mission of the upmost importance.  You need to find Jim's rabbit before the carrot stocks become completely depleted.~

So this will add the string specified to the dialog.tlk and then replace all instances of 99999 within jim.d with the updated string reference.

You can just follow this formula throughout your whole dialog but just decrease the numbers for different journal entries. (99998, 99997, etc.)                    



[!--EDIT|japheth|Jul 29 2002, 08:45 PM--]

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #14 on: July 29, 2002, 07:19:49 PM »
Quote
I think Vlad is saying (if not, then I'm saying) what about if a WeiDU-based mod called "Play Dominos With Jaheira" and a TBG/IAP based mod called "Play Dominos With Jaheira, (the way she plays dominos are different, but the triggers are the same) something has to give. Both cannot take place at the same time its either one or the other.

If the triggers are exactly the same then she can't play both versions of Dominos. I suppose this depends on one modder knowing what another is doing and its not something easily solvable and not the fault of the tool or author. Let me know if someone has found a solution.

Well, sure. But this is not a problem that should really be keeping anybody up at night, is it? I mean, to follow this example out, aside from using the same trigger names (which, if we all use variable prefixes, isn't going to happen anyway), we could do something like PartyHasItem("mydomino") as part of the trigger for my domino mod to work, and PartyHasItem("yourdomino") for yours. But Ghrey's point still stands: your IAP domino mod is going to overwrite my WeiDU domino mod.

Quote
I am not a programming whiz

Neither are we. Okay, yes, Weimer is. I mean his users.

Ghrey's only previous coding experience was .bcs.

My previous programming experience involves being poor at C64 BASIC and Apple II BASIC, being awful at C64 assembly, being poor at DOS Pascal, and having dropped a college C course. If anybody's impressed by this, they're nuts. :)

Now, I AM familiar with how command lines work, being an old Amiga user, and that is something which makes one strong anyway. .d/.tp2 are fundamentally scripting/programming languages, so you're going to spend most of your time in a text editor, not on the command line, anyway.
                   
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #15 on: July 29, 2002, 07:22:13 PM »
Quote
Yes, I have successfully been able to add and delete journal entries using WeiDU.  It's relatively simple.
                   Just a quick note: If for whatever reason you don't care about _erasing_ a journal entry, you can simply use the JOURNAL command in a reply trigger:

IF ~~ THEN REPLY ~Okay, I'll do your freaking quest.~
JOURNAL ~I agreed to do his freaking quest. Hope I get paid.~
EXIT

The cheap and dirty way.                    
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

Elhoe

  • Guest
Making proper installation package
« Reply #16 on: July 30, 2002, 04:40:48 PM »
Quote

Quote

I think Vlad is saying (if not, then I'm saying) what about if a WeiDU-based mod called "Play Dominos With Jaheira" and a TBG/IAP based mod called "Play Dominos With Jaheira, (the way she plays dominos are different, but the triggers are the same) something has to give. Both cannot take place at the same time its either one or the other.

If the triggers are exactly the same then she can't play both versions of Dominos. I suppose this depends on one modder knowing what another is doing and its not something easily solvable and not the fault of the tool or author. Let me know if someone has found a solution.



Well, sure. But this is not a problem that should really be keeping anybody up at night, is it? I mean, to follow this example out, aside from using the same trigger names (which, if we all use variable prefixes, isn't going to happen anyway), we could do something like PartyHasItem("mydomino") as part of the trigger for my domino mod to work, and PartyHasItem("yourdomino") for yours. But Ghrey's point still stands: your IAP domino mod is going to overwrite my WeiDU domino mod.


Okay bad example. A better example would be two different mods. A part of these mods is a bit where it modifies Cromwell's item upgrades. The items he requires isn't changed but the items he produces are changed i.e. he requires the Equalizer pieces but in one mod he produces the Equalizer (say a +3 sword) and in the other mod it is yet another version (say a +4 sword). Surely whichever of the two mods is put in last will overwrite the other, even if they are both WeiDU mods?

Then say you have to fight a boss that requires a +4 weapon to hurt it... you're buggered if the mod you've just installed last is the mod with the +3 be it a WeiDU mod or TBG/IAP mod. Surely neither WeiDU nor TBG/IAP can tell the difference in that the +4 weapon needs to be kept in. Will WeiDU overwrite?

Is this beyond the realms of possibility? Maybe it is, maybe it isn't, all depends on the number and type of add-in mods I suppose... It isn't the end of the world just one other thing people have to be wary of.



Okay with the other things - thanks guys for your help. I was actually try to say that I shouldn't have to write .tp2 files apart from when it is absolutely necessary (as far as I can see only appending should require you to write in .tp2).

Everything else is automated. When doing a large mod I'm not going to re-write everything I've just done in Near Infinity again into .tp2 format I'd rather have WeiDU do it for me. If it can convert existing dialogs then all I saying is will it automatically convert  2da text screens, journal entries, map notes and DisplayStrings without me telling it i.e. I shouldn't have to learn how to do this in .tp2, its done for me.

I'm sure it would be useful to make WeiDU even better (perhaps it can go on Wesley's "To Do" list, if it isn't already? :rolleyes:  )

I'd rather do stuff in Near Infinity and then get WeiDU converting it. Not having to write everything in .tp2 format in the first place. When it comes to creating large mods this can make a big difference.

One other improvement for WeiDU, are there any plans for a GUI to show the structure of dialogs. Looking at text files in notepad isn't the most easiest way of following what you've just (or somebody else)  written. Doing dialogs should be fun, not tedious typing in IF statements (which should be hidden BTW)

Doing things in WeiDU needs to quick and easy. When I spend time doing items, areas, creatures I don't want to spend a large proportion of time on typing in text files. I think this is why some of the large mod builders shy away and also because things like TDD, SOS and EE were started in pre-WeiDU days. I don't think it is done out of spite or lazyness just that if I am not doing a new NPC mod, i'd rather spend my time creating new areas than work out the intricacies of a dialog tool.

Remember these are my thoughts, I'm trying to make WeiDU easier and better, not tread all over it. Please don't take this the wrong way and I hope what I've just written makes sense  :D                    

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #17 on: July 30, 2002, 05:45:10 PM »
Quote
Okay bad example. A better example would be two different mods. A part of these mods is a bit where it modifies Cromwell's item upgrades. The items he requires isn't changed but the items he produces are changed i.e. he requires the Equalizer pieces but in one mod he produces the Equalizer (say a +3 sword) and in the other mod it is yet another version (say a +4 sword). Surely whichever of the two mods is put in last will overwrite the other, even if they are both WeiDU mods?

No, the more likely outcome is that both modders would use some form of EXTEND_BOTTOM (adding a reply trigger) so you'd have

"Hey, Cromwell, take these Equalizer pieces and give me a +3 sword."
"Hey, Cromwell, take these Equalizer pieces and give me a +4 sword."

Quote
I was actually try to say that I shouldn't have to write .tp2 files apart from when it is absolutely necessary (as far as I can see only appending should require you to write in .tp2).

.tp2 IS an installer script. It copies any arbitrary files that don't require patching (such as audio file and .bmps), it copies any IE files that MAY require patching, and performs the patches.

I suppose your point about a "mass converter" is that you'd like to be able to identify .itms, .spls, .cres, etc. and have something automatically generate .tp2 copy/patch text for it. I'm not really sure you're understanding how .tp2 works, though. It's not like working in IEEP/IETMC where you go through, design the item, add a string into your own personal .tlk file, break that string back out, blah blah. You just design your .itm and then tell the .tp2 what string to patch UPON INSTALL.

Ditto with the 2DA mods. DON'T make the 2DA mods in NI, just write the patch code in .tp2 directly. You're saying you don't want to duplicate effort, and we agree... so just do it once.

Quote
I'd rather do stuff in Near Infinity and then get WeiDU converting it. Not having to write everything in .tp2 format in the first place. When it comes to creating large mods this can make a big difference.

This is a design approach issue. The IAP or .tlk/override approach involves "Let me overhaul MY PERSONAL INSTALL of the game to be some other thing, and then let me bundle those changes up and send them to others."

The .d/.tp2 approach is "Let me DEFINE A SET OF CHANGES to ANY BG2 install, and distribute those installable changes to others."

Quote
Doing dialogs should be fun, not tedious typing in IF statements (which
should be hidden BTW)

Uh. What?

You may be a candidate for Krondor's in-development "dGen" program, which  if/when complete would be a sort of "visual studio" editor for .d files.

Quote
Doing things in WeiDU needs to quick and easy. When I spend time doing items, areas, creatures I don't want to spend a large proportion of time on typing in text files.

Again, I think you're misunderstanding the design approach.

Let's take a specific example, dialogue. You seem to be under the impression that working in a GUI-based dialogue tool is faster than all that "time on typing in text files." Yet the .d format is a tremendous TIME-SAVER for virtually any non-trivial dialogue task you can name.

Example:

Quote
CHAIN3 BIMOEN25 ilt16_chain @725
== BJ#KLS25 @726
== BVALYG25 IF ~IsValidForPartyDialog("Valygar")~ THEN @727
== BIMOEN25 @728
== BANOME25 IF ~IsValidForPartyDialog("Anomen")~ THEN @729
== BJ#KLS25 @730
== BEDWIN25 IF ~IsValidForPartyDialog("Edwin")~ THEN @731
== BIMOEN25 @732
== BHAERD25 IF ~IsValidForPartyDialog("HaerDalis")~ THEN @733
== BJ#KLS25 @734
== BSAREV25 IF ~IsValidForPartyDialog("Sarevok")~ THEN @735
== BIMOEN25 @736
== BKORGA25 IF ~IsValidForPartyDialog("Korgan")~ THEN @737
== BJ#KLS25 @738
== BJAN25 IF ~IsValidForPartyDialog("Jan")~ THEN @739
== BIMOEN25 @740
== BAERIE25 IF ~IsValidForPartyDialog("Aerie")~ THEN @741
== BJ#KLS25 @742
== BVICON25 IF ~IsValidForPartyDialog("Viconia")~ THEN @743
END BIMOEN25 ilt16_endchain

There is not a doubt in my mind that this sequence (which is Kelsey and Imoen flirting back and forth, with optional objections and snide comments from a number of other NPCs) would take, at bare minimum, 5 times as long to implement in any other available BG2 dialogue engine.                    
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

elhoe

  • Guest
Making proper installation package
« Reply #18 on: July 31, 2002, 06:29:42 AM »
thanks. Although I'm taking a break from modding I'll bear it in mind   :D                    

Vlad

  • Guest
Making proper installation package
« Reply #19 on: July 31, 2002, 08:06:22 AM »
Okay. After three days and three nights of studying WeiDU and its functions, I see how it works. Thank you a lot for your help and discussions. Now is the most dramatic part of using WeiDU - writing .tp2 file. If I have about 100-200 files to APPEND (.d, .bcs and so on), how would I list all of them in .tp2 manually? It will probably take a few days of typing.  ;) And, yes, as Elhoe has already proposed, the best way of using WeiDU for small modules is to do everything on your computer automatically using TLK Editor-IDU, Mass Convertor and NI, and then automatically convert all .dlg to .d and to APPEND .bcs and .2da. But now comes another problem. Frequently I replace animations in my modules with custom animations, how is it possible to change the corresponding .ids files with commands of WeiDU? And what's about .are modifications, if they include new actors, triggers described by new strings? I didn't find out how new .are files do appear in .tp2? Eventually, I've found in Tashia's .tp2 a long list of custom strings to install. Why its has been done instead of adding them to the corresponding dialogues? And what's going after making .tp2? How does renaimng WeiDU.exe connect to .tp2?                    



[!--EDIT|Vlad|Aug 7 2002, 10:42 AM--]

Offline jcompton

  • Niche Exploiter
  • Administrator
  • Planewalker
  • *****
  • Posts: 7246
Making proper installation package
« Reply #20 on: July 31, 2002, 08:43:56 AM »
Quote
If I have about 100-200 files to APPEND (.d, .bcs and so on), how would I list all of them in .tp2 manually? It will probably take a few days of typing.

You get good with cut and paste.

Quote

And, yes, as Elhoe has already proposed, the best way of using WeiDU for small modules is to do everything on your computer automatically using TLK Editor-IDU, Mass Convertor and NI, and then automatically convert all .dlg to .d


Gah! Absolutely not!

You do not get the benefits of using WeiDU for dialogue through this method. Any changes you made to an existing state with, say, EXTEND_BOTTOM would be lost in the shuffle, you'd have to break it out completely manually and ruin the point. Then you'd have to erase everything out of the .d that exists in standard SOA and make everything that remained an APPEND line... and once again, you're basically doing the work twice, and you're thinking that it's too much work, and there's a reason for that.

As I tried to explain to Elhoe, you guys are both thinking about using WeiDU for old-style (.tlk/override or IAP) distribution, and that is a waste of its abilities and a waste of your time.

Quote
Frequently I replace animations in my modules with custom animations, how is it possible to change the corresponding .ids files with commands of WeiDU?
You can perform REPLACE_TEXTUALLY on an IDS file, same as on a 2DA.

Here's how it works for a 2DA: In this case, we're replacing Kelsey's entry in PDIALOG because we didn't really remember we'd be doing a Kelsey-TOB, so we need to fix that:

COPY_EXISTING ~pdialog.2da~ ~override/pdialog.2da~
REPLACE_TEXTUALLY ~J#Kelsey     J#KlsyP            J#KlsyJ           J#KlsyD        IDIOTP             IDIOTP                ***                   ***~
                  ~J#Kelsey     J#KlsyP            J#KlsyJ           J#KlsyD        J#Kls25P           J#Kls25J              J#Kls25D              J#Klsy25~


(COPY_EXISTING is how you get WeiDU to do .tp2 patching on a file that you know is already in the game.)

So you'd COPY_EXISTING ~blah.ids~ ~override/blah.ids~
REPLACE_TEXTUALLY ~line that's in the core IDS~ ~line you want it to be~

Quote
And what's about .are modifications, if they include new actors, triggers described by new strings? I didn't find out how new .are files do appear in .tp2?

1. Look at Weimer's Ritual.

2. Ask Cuv on the RtW board.

Quote
Eventually, I've found in Tashia's .tp2 a long list of custom strings to install. Why its has been done instead of adding them to the corresponding dialogues?

You're probably thinking of the way he patches strings into his CRE, and then into the .bcs that corrects Tashia's CRE strings if they ever get corrupted. By using REPLACE in a .tp2, you can get the actual strref into a .bcs, which is very very useful.

Quote
And what's going after making .tp2? How does renaimng WeiDU.exe connect to .tp2?

You can run a .tp2 in one of two different ways:

You can do

weidu mymod.tp2 --out override --tlkout dialog.tlk
(plus any other options you may need to invoke)

OR, you can rename WeiDU to setup-xxxx.exe. When you do that, WeiDU will automatically look for a .tp2 called either "xxxx.tp2" or "setup-xxxx.tp2", run it, and will automatically assume --out override and --tlkout dialog.tlk.

                   
Cespenar says, "Kelsey and friends be at the Pocket Plane? Ohhh yesssss!" http://www.pocketplane.net

japheth

  • Guest
Making proper installation package
« Reply #21 on: July 31, 2002, 08:55:04 AM »
I'll just clarify what jc said about the .are questions.

If you need to add new actors, triggers, strings, etc into a .are file, the easiest way to do it is this:

First add them using IETME to the existing area you want to edit but remember to keep an old copy of the .are file as well.

Next, load up the new .are file in NI and note the offset that your new triggers/actors etc are at.

Then I would load up the new .are file in a hex editor and take a look at the bytes that you are going to have to write.

Finally in the .tp2 file, you issue this statement.

COPY_EXISTING ~example.are~ ~override/example.are~
INSERT_BYTES 0x48h 16
WRITE_BYTE 0x48h 0x8a
etc, etc.

So what you are basically doing is adding in the number of bytes you need to make your changes at the appropriate offset (you'll know how many by looking at the .are file in the hex editor and you'll know what offset by looking at the .are file in NI) and then writing the appropriate byte-wise information (you'll also know this from the hex editor.)

If all that sounds complicated, don't worry, it is.                    

Vlad

  • Guest
Making proper installation package
« Reply #22 on: July 31, 2002, 09:30:14 AM »
No it doesn't sound complicated. Thank you. I think I have no more questions for a while. We are going to modify the whole scenario of SoA-ToB. There will be a new original plot, new quests and so on. So you can imagine that number of modified files, which recently have already been done. For now my override includes about 450 new and modified files. JC, you told before that the way of installation depends on the form of a module. You are absolutely right. I really like your Kelsey and Weis' Sola, moreover Domi has already written an extensive banter between our NPCs and them, but unfortunately the party in our module won't have place nor for Kelsey, neither for Sola, nor for any other BioWare NPCs. The best party for doing all quests will be: Protagonist, Yoshimo, Kachiko, Sime, Coran (or Kivan), Jaheira (or Imoen later). Xan will be an option in the next chapter. Otherwise, the main quests, and even a whole plot without these NPCs won't be available. In this case, I came to conclusion to distribute our game as it is (like the first version of Ascension, and my Travelers in Time).
All the best to you.  :D                    

 

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Name: Email:
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image
Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?: