Jump to content


Photo

Learning to package a module


  • Please log in to reply
1 reply to this topic

#1 Zvijer

Zvijer
  • Member
  • 27 posts

Posted 07 May 2003 - 08:03 AM

I want to add a script like this in baldur.bcs:

IF
	Global("myglobal","GLOBAL",0)
THEN
	RESPONSE #100
  DisplayString(Player1,74138)
  SetGlobal("myglobal","GLOBAL",1)
  Continue()
END


In my dialog.tlk is the reference number 74138, but a person who installs my mod won't have it. I could add it with .tp2 file, but the text won't be in the same place. What could I do to make it work?

PS. What is the difference between baldur.bcs and baldur25.bcs? Do I need to add the same blocks in both of them to make them work in both SoA and ToB areas? Or just in one, and if this is so, which one?

PPS. Where can I register file naming convention which prevents overwriting other peoples' custom files? You know, such is J#... that Ghreyfain uses?

Thanks for your help.

#2 -Sim-

-Sim-
  • Guest

Posted 07 May 2003 - 08:24 AM

In my dialog.tlk is the reference number 74138, but a person who installs my mod won't have it. I could add it with .tp2 file, but the text won't be in the same place. What could I do to make it work?


You have two alternatives.

Firstly, WeiDU can compile BAF files "on-the-fly", so you could include a BAF script with DisplayString(Player1,~Text.~), and use the following in your TP2:
EXTEND_TOP ~BALDUR.BCS~ ~mymod/extend.BAF~

Alternatively, compile your script using "99999" in place of the actual strref. Then, you can COPY it across and use REPLACE to replace 99999 with the actual text.

PS. What is the difference between baldur.bcs and baldur25.bcs? Do I need to add the same blocks in both of them to make them work in both SoA and ToB areas? Or just in one, and if this is so, which one?


BALDUR.BCS runs in SoA, BALDUR25 in ToB. So... yeah.

PPS. Where can I register file naming convention which prevents overwriting other peoples' custom files? You know, such is J#... that Ghreyfain uses?


There is a listing of prefix reservations here. However, it's slightly outdated, since the trend at the moment seems to be to ignore the centralised listing for reasons that I will not speculate on.