Jump to content


Photo

Please clarify the TP2 file for me


74 replies to this topic

#1 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 12:42 PM

Hi all,

 

Long time player, first time modder. After thousands of lines of dialogues and interparty banters, and hours of adjusting the code until it was error-free, i'm now stuck again and what's worse, confused with no tutorial seeming to provide the answer.

 

Since this is a BG mod, which I want to eventually take into maybe SoD and definitely BG2, i'd like to have an understanding of how this works to avoid future problems and not just get lucky with a copy-paste jobs (which doesn't seem to be helping anyway xD)

 

Anyway, I compile the dialogues just fine but then get an error like:

 

Error locating resource for 'CHAIN3'

Resource  [Bishl] not found in KEY file:

CHITIN.KEY

 

Since it gives me the variable name I used for her banter between other companions I am assuming it's having a problem there.

 

The file is appended into the interdia.2da file at the end like it should be. I add the variable name to that list just to try it and nothing.

 

Am I missing something?



#2 Roxanne

Roxanne
  • Modders
  • 1150 posts
  • Gender:Not Telling

Posted 22 November 2016 - 12:58 PM

Hi all,

 

Long time player, first time modder. After thousands of lines of dialogues and interparty banters, and hours of adjusting the code until it was error-free, i'm now stuck again and what's worse, confused with no tutorial seeming to provide the answer.

 

Since this is a BG mod, which I want to eventually take into maybe SoD and definitely BG2, i'd like to have an understanding of how this works to avoid future problems and not just get lucky with a copy-paste jobs (which doesn't seem to be helping anyway xD)

 

Anyway, I compile the dialogues just fine but then get an error like:

 

Error locating resource for 'CHAIN3'

Resource  [Bishl] not found in KEY file:

CHITIN.KEY

 

Since it gives me the variable name I used for her banter between other companions I am assuming it's having a problem there.

 

The file is appended into the interdia.2da file at the end like it should be. I add the variable name to that list just to try it and nothing.

 

Am I missing something?

The problem may be in the d file you compile or the tp2. It would be best if you post both of them here.

To put the banter file into chitin.key you must have somewhere in your d-files a line saying

BEGIN Bishl

 

The entry into interdia.2da file is there to associate the banter file with your NPC, so it will be used when he/she is in party, the BEGIN Bishl is the one to create the dlg file itself.


Edited by Roxanne, 22 November 2016 - 01:02 PM.

The Sandrah Saga

another piece of *buggy, cheesy, unbalanced junk*


#3 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 01:05 PM

Actually, that worked, thanks! I had mistakenly forgot to change the name after BEGIN in the d file to "Bishl".

 

Now it's giving me errors, but I know these are just because I didn't use the correct shortened banter names for companions with long names, so that's an easy fix which i'll do immediately. 

 

Another question- Is there anything special I need to do in order to get this running on BGEE, or is normal WEIDU language and compatibility with BGTUTU enough?



#4 agb1

agb1
  • Modders
  • 410 posts
  • Gender:Male

Posted 22 November 2016 - 01:14 PM

Look here and here.


BiG World Fixpack (community collection of mod fixes and compatibility patches, with user-friendly cross-platform script)

 

BiG World Setup (tool to automate best-practice installation of Infinity Engine mods on Windows, with conflict analysis)

Latest version:    https://bitbucket.or.../get/master.zip


#5 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 01:47 PM

Again, thanks! Very much appreciated.

 

Now the dialogue files are fine, the banter files and the script are fine, but now my area script isn't. This is the error:

 

ERROR:Unix.Unix_error(20,"stat", "Ishlilkamod/Script/AR2300.baf")

 

 

In my TP2 file:

 

EXTEND_TOP ~AR2300.bcs~ ~Ishlilkamod/Script/AR2300.baf~

 

The code inside the Script:

 

IF
    Global("SpawnI", "GLOBAL", 0)
THEN
    RESPONSE #100
        SetGlobal("SpawnI", "GLOBAL", 1)
        CreateCreature("#Ishl", [3330.2300], 14)
        Continue()
END



#6 Roxanne

Roxanne
  • Modders
  • 1150 posts
  • Gender:Not Telling

Posted 22 November 2016 - 01:57 PM

Again, thanks! Very much appreciated.

 

Now the dialogue files are fine, the banter files and the script are fine, but now my area script isn't. This is the error:

 

ERROR:Unix.Unix_error(20,"stat", "Ishlilkamod/Script/AR2300.baf")

 

 

In my TP2 file:

 

EXTEND_TOP ~AR2300.bcs~ ~Ishlilkamod/Script/AR2300.baf~

 

The code inside the Script:

 

IF
    Global("SpawnI", "GLOBAL", 0)
THEN
    RESPONSE #100
        SetGlobal("SpawnI", "GLOBAL", 1)
        CreateCreature("#Ishl", [3330.2300], 14)
        Continue()
END

Is that baf file really in the directory the tp2 points to?


The Sandrah Saga

another piece of *buggy, cheesy, unbalanced junk*


#7 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 02:03 PM

Yes, definitely in the right directory...

 

I am trying to install this on BGTutu at the moment, if that helps any.



#8 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 02:07 PM

Wait, fixed. Maybe there was something located in the area I placed her in, because changing that slightly fixed it.

 

Anyway, all is successfully installed. Now to playtest and bugfix.

 

You guys seriously saved me hours of frustration! :)



#9 agb1

agb1
  • Modders
  • 410 posts
  • Gender:Male

Posted 22 November 2016 - 02:32 PM

Noticed you used # as a prefix for your creature file.  Suggest you reserve a modder prefix for yourself on the registration thread (check here first to see if your prefix is available).

 

This is good practice to avoid naming collisions with other modders.

 

Edit:  Also, in general, ERROR:Unix.Unix_error(20,"stat", "filename") means file-not-found.


Edited by agb1, 22 November 2016 - 02:33 PM.

BiG World Fixpack (community collection of mod fixes and compatibility patches, with user-friendly cross-platform script)

 

BiG World Setup (tool to automate best-practice installation of Infinity Engine mods on Windows, with conflict analysis)

Latest version:    https://bitbucket.or.../get/master.zip


#10 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 22 November 2016 - 03:13 PM

...aand i'm back, lol.

 

Says it successfully installs, but my character is nowhere to be found. I revised all the file names to FW because it was Tutu.  the name inside the createcreature function needs to be the same as the cre file, correct? and does it use mouse coordinates or tile position? i'm assuming mouse coordinates...



#11 Roxanne

Roxanne
  • Modders
  • 1150 posts
  • Gender:Not Telling

Posted 22 November 2016 - 03:24 PM

...aand i'm back, lol.

 

Says it successfully installs, but my character is nowhere to be found. I revised all the file names to FW because it was Tutu.  the name inside the createcreature function needs to be the same as the cre file, correct? and does it use mouse coordinates or tile position? i'm assuming mouse coordinates...

Is your Global("SpawnI", "GLOBAL", 0) really 0 or something from a previous save?
 

 

the name inside the createcreature function needs to be the same as the cre file, correct

 

Yes

i'm assuming mouse coordinates...

 

The ones you get when you use x in the game on your cursor.

 

Is your creature an invisible creature after all?

No joke - if you made the cre as a copy of an existing one, did you remove original scripts or such (some creatures have code in their class script or race script to make them leave under certain conditions, or random walk....etc)?

 

Otherwise it might be tutu special, and sorry but I cannot help you with tuta particularities.


Edited by Roxanne, 22 November 2016 - 10:25 PM.

The Sandrah Saga

another piece of *buggy, cheesy, unbalanced junk*


#12 agb1

agb1
  • Modders
  • 410 posts
  • Gender:Male

Posted 22 November 2016 - 03:31 PM

If you are using Tutu and patching AR2300.BCS, the area file AR2300.ARE might not actually be set to use the AR2300.BCS script.

 

See here:  there is a script "bgee_area_script_assign.tph" that patches all of the Tutu area files so they use the BCS script file that matches the area file name.  You could try taking that file and INCLUDE it in your mod:

 

ACTION_IF GAME_IS ~tutu tutu_totsc~ BEGIN 
    INCLUDE ~%MOD_FOLDER%/libs/bgee_area_script_assign.tph~ // assuming you put the tph file in a libs subfolder in your mod directory
END

 

Consider taking the rest of the cpmvars libs there and INCLUDE them all too; each one checks the game type, so only one will actually take effect.  They set a bunch of variables that you can use to refer to areas by descriptive name instead of by platform-specific filename, like %FriendlyArmInn% instead of AR2300.


BiG World Fixpack (community collection of mod fixes and compatibility patches, with user-friendly cross-platform script)

 

BiG World Setup (tool to automate best-practice installation of Infinity Engine mods on Windows, with conflict analysis)

Latest version:    https://bitbucket.or.../get/master.zip


#13 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 23 November 2016 - 02:03 PM

Well it would be FW, not AR correct? That is what shows up when I hit CTRL-X on the console and is also what is claimed on the interwebs to be the BGTutu area names, and the names on that script are AR.

 

I tried changing it to Peldvale to see if any changes occurred there, and so far, can't get her to appear.



#14 agb1

agb1
  • Modders
  • 410 posts
  • Gender:Male

Posted 23 November 2016 - 02:49 PM

Open the area file (FW####.ARE) using Near Infinity and look at the area script name. If it is FW####.BCS, then your code that does an EXTEND_TOP on AR2300.BCS is not being used there.

BiG World Fixpack (community collection of mod fixes and compatibility patches, with user-friendly cross-platform script)

 

BiG World Setup (tool to automate best-practice installation of Infinity Engine mods on Windows, with conflict analysis)

Latest version:    https://bitbucket.or.../get/master.zip


#15 WarChiefZeke

WarChiefZeke
  • Members
  • 43 posts

Posted 23 November 2016 - 03:08 PM

Solved! I see area FW2300 doesn't use FW2300 as a script name, but _AR2300.

 

I didn't realize you could do that in NearInfinity (my only expierience with it is the required CRE file changes). Good to know.

 

You guys have been very helpful, now the spawn is working correctly and so far everything is going as planned. :)





Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users