Jump to content


Photo

Modding for Beginners


  • Please log in to reply
111 replies to this topic

#81 Keryvian

Keryvian
  • Member
  • 15 posts

Posted 18 May 2004 - 08:06 PM

The problem with the non-joinable npcs not showing up was actually answered in another thread (here)

The problem is that, even though the area 1005 script exists, it is not referenced by the 1005 area file itself. You need to patch the area file to reference the script. Add this
COPY_EXISTING ~AR1005.are~ ~override\AR1005.are~
	WRITE_ASCII 0x94 ~AR1005~
to your .tp2 and it should work.

I've tried this on my pc (with the alpha of Tsujatha), and it worked. It also uncovered a bug in one of the npc's dialog file (a variable was not getting set). I have a working version of this on my pc as well.

I hope this helps.

#82 Sillara

Sillara

    He made me love him without looking at me.

  • Member
  • 537 posts

Posted 18 May 2004 - 10:11 PM

I tried using TJAR1005 for the area, as that was what I called my area addition. I was not able to get it to work yet. Are you getting a syntax error near the text "JavinExists" when you install? What is your version of WeiDu?

Where is the bug in the NPC's dialogue, and which was it? (Please PM me this information! I am currently bug hunting, and I would really like to squash that one, too. Did it fix the stuttering?)

I will try the area stuff without the TJ prefix, and I will see what I can get.

Thanks!

Sillara

Edit: And now I have it!! Javin spawns!!! :D :D :D

I am going to hunt that bug up, as I think it is in Javin's script. Thanks, everyone!

Edited by Sillara of the Tamari, 18 May 2004 - 10:56 PM.

Check out my RPG forum!

#83 Keryvian

Keryvian
  • Member
  • 15 posts

Posted 19 May 2004 - 10:17 AM

What is your version of WeiDu?

I'm using version 155, which should be the latest version.

Where is the bug in the NPC's dialogue, and which was it?  (Please PM me this information!  I am currently bug hunting, and I would really like to squash that one, too.  Did it fix the stuttering?)

I've PM'd the details of the NPC dialog bug I found to you on the Chosen of Mystra board.

It wasn't the cause of the stuttering bug, but I think I know what is causing that. I'll PM you the details of that bug on this board (just to keep things confusing).

Good luck!

#84 Sillara

Sillara

    He made me love him without looking at me.

  • Member
  • 537 posts

Posted 19 May 2004 - 05:09 PM

Thank you, Keryvian!!! You are my master-bug-squasher! :D

I have another bug-squashing favor to ask you, which I will PM you.

Hurrah!!!

Sillara, the delighted
Check out my RPG forum!

#85 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 21 May 2004 - 06:28 PM

Ok, got a couple of problems I just can't figure out:

First, here are the scripts that set up the romance talks.

IF
Global("ForrestMatch","GLOBAL",0)
Global("CheckForrestMatch","GLOBAL",0)
Gender(Player1,MALE)
!Global("AnotherMaleRomanceActive","GLOBAL",2)
!Global("ForrestRomanceActive","GLOBAL",3)
OR(2)
Alignment(Player1,MASK_GENEUTRAL)
Alignment(Player1,MASK_GOOD)
OR(6)
Race(Player1,HUMAN)
Race(Player1,HALF_ELF)
Race(Player1,ELF)
Race(Player1,HALFLING)
Race(Player1,GNOME)
Race(Player1,HALFORC)

THEN
RESPONSE #100
SetGlobal("ForrestRomanceActive","GLOBAL",1)
SetGlobal("CheckForrestMatch","GLOBAL",1)
SetGlobal("ForrestMatch","GLOBAL",1)
RealSetGlobalTimer("ForrestRomanceTimer","Global",300)
SetGlobal("ForrestLovetalk","GLOBAL",1)
END


IF
 Global("ForrestMatch","GLOBAL",1)
 Global("ForrestRomanceActive","GLOBAL",1)
 OR(2)
  Global("ForrestLovetalk","GLOBAL",1)
  Global("ForrestLovetalk","GLOBAL",3)
 GlobalTimerExpired("ForrestRomanceTimer","GLOBAL")
 !AreaType(DUNGEON)  // None of the Bioware NPCs will banter in dungeons, and I suggest that modders keep this tradition.
 !StateCheck(Player1,STATE_SLEEPING)  // How's the PC going to talk if he can't do anything?
 InParty(Myself)  // Jaheira will actually fire lovetalks if she's not in the party.  You don't want your NPC to do that, do you?
 See(Player1)
THEN
 RESPONSE #100
  IncrementGlobal("ForrestLovetalk","GLOBAL",1)
  //Interact(Player1)
  StartDialog("K#Forre",Player1)
END


IF
    OR(2)
	Global("ForrestLovetalk","GLOBAL",2)
	Global("ForrestLovetalk","GLOBAL",4)
THEN
    RESPONSE #100
        IncrementGlobal("ForrestLovetalk","GLOBAL",1)
        RealSetGlobalTimer("ForrestRomanceTimer","GLOBAL",30)
END

Problem #1 The timing is off in that LT1 triggers almost immediately after he joins.

Problem #2 Lovetalk2 is not triggering at all. (time is set artificially low for testing.)

Any help here would be appreciated.

#86 Rastor

Rastor

    Yes, I really am a dragon. Yes, I am a jerk. Live with it.

  • Member
  • 2001 posts

Posted 21 May 2004 - 07:32 PM

IF
Global("ForrestMatch","GLOBAL",1)
Global("ForrestRomanceActive","GLOBAL",1)
OR(2)
Global("ForrestLovetalk","GLOBAL",1)
Global("ForrestLovetalk","GLOBAL",3)
GlobalTimerExpired("ForrestRomanceTimer","GLOBAL")
!AreaType(DUNGEON)  // None of the Bioware NPCs will banter in dungeons, and I suggest that modders keep this tradition.
!StateCheck(Player1,STATE_SLEEPING)  // How's the PC going to talk if he can't do anything?
InParty(Myself)  // Jaheira will actually fire lovetalks if she's not in the party.  You don't want your NPC to do that, do you?
See(Player1)
THEN
RESPONSE #100
IncrementGlobal("ForrestLovetalk","GLOBAL",1)
//Interact(Player1)
StartDialog("K#Forre",Player1)
END


What is that supposed to accomplish? What's in your K#Forre dialog? Lovetalks need to be in your B file, set in interdia.2da. If K#Forre is the dialogue set in the creature file, then it won't work if he's actually in the party.

I suggest you use the Interact(Player1) instead of StartDialog().

Your first lovetalk is firing immediately because that script has the LoveTalks set to fire on the odd numbers, not the even ones. Even with the timer here, your first state sets ForrestLoveTalk = 1, which fires the LoveTalk.

Either change your first scripting block so that it does not include "SetGlobal("ForrestLovetalk","GLOBAL",1)", or change your second block of code from: " Global("ForrestLovetalk","GLOBAL",1)
Global("ForrestLovetalk","GLOBAL",3)
" to " Global("ForrestLovetalk","GLOBAL",2)
Global("ForrestLovetalk","GLOBAL",4)"
Home of Kitanya, Improved Asylum, more...

Posted Image

#87 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 21 May 2004 - 10:08 PM

What is that supposed to accomplish? What's in your K#Forre dialog? Lovetalks need to be in your B file, set in interdia.2da. If K#Forre is the dialogue set in the creature file, then it won't work if he's actually in the party.


I'm copying this a bit from Tashia. The process I'm going for (and are there stack trace utilities? How can I find the value of a variable using CULA console while the script is running?)

My understanding of what should be happening is this:
Block 1: Forrest meets player, checks for match. Sets LT to 1 and sets a timer.
Block 2: if the timer expires and LT is odd, increment LT, LT now equals 2 so interact should trigger the proper script.
Block 3: if LT = 2, increment the timer (LT now = 3) and reset the timer.

What am I conceptually missing? Is there a way that I can report something to console as these things rollover?

I suspect that the biggest part of the problem is with the interdia.2da which is a big underdocumented black box. (And frankly, so far, none of the tutorials has completely working sample code.)

Here is what I have at the bottom of the tp2

APPEND ~interdia.2da~
~FORREST     BK#FORRE     BK#FORRE~

So, I move all of the LTs to the bottom of the script after a
BEGIN ~BK#FORRE~ statement, and I get nothing. A savegame after about a minute reveals that ForrestLovetalk has rolled over from 1 to 2 without triggering the dialog.

#88 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 21 May 2004 - 11:08 PM

This is pretty much the form used in Kelsey-TOB and Tashia, what am I missing. I'm also seeing Forrest turn towards Player1 and pause at the right moment. So I'm wondering if the Interact is fireing but my script is in the wrong place.

here are my 2da appends
APPEND ~pdialog.2da~
~FORREST K#ForresP K#ForresJ K#ForresD~

UNLESS ~K#Forres~
UNLESS ~25POST~
APPEND ~pdialog.2da~
~FORREST K#ForreP K#ForreJ K#ForreD K#For25P K#For25J K#For25D K#For25~
UNLESS ~K#Forres~
IF ~25POST~

APPEND ~interdia.2da~
~FORREST     BK#FORRE     BK#FORRE~

Is this correct, if this is correct how should I start my romance script (and why is it that way?)

#89 Grim Squeaker

Grim Squeaker

    Fallen

  • Member
  • 1018 posts

Posted 21 May 2004 - 11:16 PM

Yeah thats not quite right. What is your Death Variable? If it's K#Forres then it should look like this:

APPEND ~pdialog.2da~
~K#Forres K#ForresP K#ForresJ K#ForresD~
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~pdialog.2da~
~K#Forres K#ForreP K#ForreJ K#ForreD K#For25P K#For25J K#For25D~
UNLESS ~K#Forres~
IF ~25POST~

APPEND ~interdia.2da~
~K#Forres BK#FORRE
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~interdia.2da
~K#Forres BK#FORRE BK#FORRE~
UNLESS ~K#Forres~
IF ~25POST~


I've put the ones that shoud be your Death Variable in bold. The one in italics is what should be your ToB Banter file. You probably want it to be different to your SoA one.
"You alone can make my song take flight..."

#90 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 21 May 2004 - 11:20 PM

Yeah thats not quite right. What is your Death Variable? If it's K#Forres then it should look like this:

APPEND ~pdialog.2da~
~K#Forres K#ForresP K#ForresJ K#ForresD~
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~pdialog.2da~
~K#Forres K#ForreP K#ForreJ K#ForreD K#For25P K#For25J K#For25D K#For25~
UNLESS ~K#Forres~
IF ~25POST~

APPEND ~interdia.2da~
~K#Forres BK#FORRE
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~interdia.2da
~K#Forres BK#FORRE BK#FORRE~
UNLESS ~K#Forres~
IF ~25POST~


I've put the ones that shoud be your Death Variable in bold. The one in italics is what should be your ToB Banter file. You probably want it to be different to your SoA one.

The death variable (at least according to Near Infinity cracking open the .cre) is just "FORREST" Should the death variable match the same form as the dialog file names?

#91 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 21 May 2004 - 11:31 PM

Still no joy. Still getting the body motions but no dialogue.

What section should the dialogue be in. K#ForreJ? or BK#Forre?

I'm at my wits end here. It's not that I'm all that stupid when it comes to computers. A large chunk of what I do is statistical comptuting and text processing. It is, basically, that I've spent way too much time developing this character to be running up against a run-time error that provides me with no feedback and no trace as to what the heck is going wrong. I don't even know how to start troubleshooting this because it seems like I'm just running a bit slower than a group of random monkeys at typewriters throwing information into BG2.

Edited by kirkjobsluder, 22 May 2004 - 12:18 AM.


#92 Grim Squeaker

Grim Squeaker

    Fallen

  • Member
  • 1018 posts

Posted 22 May 2004 - 12:35 AM

The naming convention for the Death Variable doesn't matter. Just make sure you are consistant with the Death Variable and its always a good idea to attach your modding prefix to it so you don't get clashing with other mods. 'K#Forrest' would be fine. So, whatever you choose, just replace the entries in bold with it.
"You alone can make my song take flight..."

#93 Grim Squeaker

Grim Squeaker

    Fallen

  • Member
  • 1018 posts

Posted 22 May 2004 - 12:37 AM

Interact() will fire ones from the B file. Dialogue() will fire ones from the J file.
"You alone can make my song take flight..."

#94 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 22 May 2004 - 01:03 AM

Interact() will fire ones from the B file.  Dialogue() will fire ones from the J file.

OK, here is the bottom of my new .tp2 file:
APPEND ~pdialog.2da~
~K#Forres K#ForresP K#ForresJ K#ForresD~
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~pdialog.2da~
~K#Forres K#ForreP K#ForreJ K#ForreD K#For25P K#For25J K#For25D K#For25~
UNLESS ~K#Forres~
IF ~25POST~

APPEND ~interdia.2da~
~K#Forres     BK#FORRE~
UNLESS ~K#Forres~
UNLESS ~25POST~

APPEND ~interdia.2da~
~K#Forres BK#FORRE BK#FORRE~
UNLESS ~K#Forres~
IF ~25POST~

And here is the tail end of my interdia.2da file:
TASHIA BTASHIA BTASHI25
K#Forres BK#FORRE

Could the missing column be causing a problem?

Here is the start of my dialogue file:

BEGIN ~BK#FORRE~
//start romance stuff

//Start first lovetalk.
IF ~Global("ForrestLovetalk","LOCALS",2)~ 
	THEN BEGIN RomanceTalk1
 	 SAY @100
	IF ~~ THEN REPLY @101 GOTO RT1Continue2
	IF ~~ THEN REPLY @102 GOTO RT1End1
	IF ~~ THEN REPLY @108 GOTO RT1End2
END


#95 Grim Squeaker

Grim Squeaker

    Fallen

  • Member
  • 1018 posts

Posted 22 May 2004 - 01:20 AM

First of all have changed his Death Variable in his CRE to K#Forres?

Secondly, do you have ToB installed? Because if you don't then that could explain the lack of a third column in your 2DA
"You alone can make my song take flight..."

#96 kirkjobsluder

kirkjobsluder
  • Member
  • 222 posts

Posted 22 May 2004 - 01:24 AM

First of all have changed his Death Variable in his CRE to K#Forres?

Secondly, do you have ToB installed?  Because if you don't then that could explain the lack of a third column in your 2DA

Yes, the death variable has been changed, and I do have ToB installed.

Could my installation be horked? I have had to install, and remove Ascention and as a result, had to reinstall Sola. Should I try this load of mindless frustration with a clean install of SoA (with of course the old backed up?)

Edited by kirkjobsluder, 22 May 2004 - 01:32 AM.


#97 Rastor

Rastor

    Yes, I really am a dragon. Yes, I am a jerk. Live with it.

  • Member
  • 2001 posts

Posted 22 May 2004 - 08:18 AM

First of all have changed his Death Variable in his CRE to K#Forres?

Secondly, do you have ToB installed?  Because if you don't then that could explain the lack of a third column in your 2DA

Yes, the death variable has been changed, and I do have ToB installed.

Could my installation be horked? I have had to install, and remove Ascention and as a result, had to reinstall Sola. Should I try this load of mindless frustration with a clean install of SoA (with of course the old backed up?)

Nearly everyone prefers to work with a patched install of ToB with no mods, as it makes troubleshooting problems much easier.

If you've got ToB installed, then you should have three columns in interdia.2da.
Home of Kitanya, Improved Asylum, more...

Posted Image

#98 -chris h-

-chris h-
  • Guest

Posted 15 August 2004 - 07:03 AM

it has always been my dream for some one with the extream powers of modding to teach me how to undress kasumi on dead or alive extream beach volly ball please teach me how to mod

#99 SConrad

SConrad

    I swear to drunk I'm not God

  • Administrator
  • 11148 posts

Posted 15 August 2004 - 07:07 AM

it has always been my dream for some one with the extream powers of modding to teach me how to undress kasumi on dead or alive extream beach volly ball please teach me how to mod

To be honest, I don't really think "dead or alive extream beach volly ball" (sic) is a IE-game. So your post is a little misplaced.

Posted Image Khadion NPC mod - Team leader, head designer
Posted Image Hubelpot NPC mod - Team leader, coder
Posted Image NPC Damage - Coder
Posted Image PC Soundsets - Coder, voice actor
Posted Image Brythe NPC mod - Designer
Posted Image DragonLance TC - Glory of Istar - Designer
Posted Image The NPC Interaction Expansion Project - Writer for Cernd, Sarevok
Posted Image The Jerry Zinger Show - Producer

Iron Modder 5 - Winner


#100 Schatten

Schatten

    tomo the homo

  • Member
  • 1208 posts

Posted 15 August 2004 - 09:36 AM

it has always been my dream for some one with the extream powers of modding to teach me how to undress kasumi on dead or alive extream beach volly ball please teach me how to mod

its easy. get the porn "babes with boobs on beach volume 3".
gentoo sex is updatedb; locate; talk; date; cd; strip; look; touch; finger; unzip; uptime; gawk; head; emerge --oneshot condom; mount; fsck; gasp; more; yes; yes; yes; more; umount; emerge -C condom; make clean; sleep.