Jump to content

My few-days NPC attempt


Garfield

Recommended Posts

@Domi: Indeed, I currently have a party on hold because two most grand NPC don't have ToB content Yyet :hm:

But I also would like to make both contents distinct: I played SoA for four year before I got myself ToB, and I got mad when I could not use a mod because of some exotic scripting action which SoA could not handle...

 

@berelinde: I don't have a digital voice recorder and my MP3 player is lousy when it comes to recording but I'll do it the old way... PnP :)

Link to comment

After much fiddling with ctrl+I and exotic variables, I have been able to test almost all NPC's and PC's banter. They only ones I could not were Jaheira's, for the first banter starts after a rest.

 

But for all the others, everything is fine. I correct a huge amount of rather dubious typos (Like on where Mazzy was saying about "having nimble fingers to sew"... problem: the neighbour key of "w" on French keyboards is..."x". Geez she did not sounded like a paladin to me back then :) )

 

So know I'll be up to test the interjections and Jaheira's banters, along with planning my quest (they are quite a few Yuan-Ti in the game, but I'll guess it will begin at the De'Arnise keep). I have the outline, but I need to flesh it out a bit more. This might come out interresting for Nalia too... She'll anyway won't banter with Hagen before you clean the keep.

Link to comment

If I may offer a suggestion, find yourself a proofreader. You're modding in English, right? Your English is outstanding, but you might still benefit from having one. You could always wait until the mod is done, then traify the whole thing and let somebody play with the TRA files.

Link to comment

Yup I never though differently :)

I'll traify the whole thing once the mod is completed, because I would like to have it in French too for obvious reasons :)

Then I could find a kind proof reader (relax, there is no romance to go through, which I know can be quite painful... :hm: )

Link to comment

Dhooo! Progress, progress.

 

The Underdark interjections seems to work (hmmm, ok, there are only two of them :p , but since I'm not doing a one-dayish NPC anymore, I'll build that up.)

 

I also coded and tested the beginning of the quest (which can be done before of after Spellhold). This is all VERY straightforward: talk a quest giver NPC, talk to a second NPC somewhere else, go to a specific area, fight, end of part 1 :p

I'll try to make the whole thing harder (for instance by giving my villain a better script and rising his level) because this is really too simple at the moment.

As predicted, the quest starts at Nalia's Keep, right after you kill Torgal. Having Nalia, Anomen or Keldorn will be a kind of a bonus for the quest, although none is essential.

 

What remains to do for the SoA part:

-Quest interlude at Brynnlaw for those who started it before Spellhold

-End of the quest in chapter 6

-Some more interjections, and one more banter by character if I find the inspiration.

-MAYBE a more complex relation with the PC, if I find a way to use timers to trigger banters (I don't want to write talks that will never happen in game :hm: )

-This polymorph snake spell :)

 

And for ToB... well, in a perfect world, I'd play through ToB before modding for it :)

Link to comment
-MAYBE a more complex relation with the PC, if I find a way to use timers to trigger banters (I don't want to write talks that will never happen in game )

 

Don't let triggers to stop you! It's really easy:

 

IF
InParty(Myself)
GlobalGT("Chapter","GLOBAL",5)		//some condition
Global("P#KivanMatch","GLOBAL",1) //some condition
Global("P#DeherianaDead","GLOBAL",1) //some condition
Global("P#KivanSweetTalk","GLOBAL",0) //your talk counter
THEN
RESPONSE #100
RealSetGlobalTimer("P#KiSweetTalkTime","GLOBAL",300) //your main timer
SetGlobal("P#KivanSweetTalk","GLOBAL",1) //setting your talk counter to 1, he'll talk on even, went on odd
END

IF
InParty(Myself)
CombatCounter(0) 
!See([ENEMY])
RealGlobalTimerExpired("P#KiSweetTalkTime","GLOBAL")  //your timer expired
ReputationGT(Player1,11) //some condition
Global("P#KivanMatch","GLOBAL",1) //some condition
!Global("P#KivanRomanceInactive","GLOBAL",1) //some condition
Global("P#KivanRomanceActive","GLOBAL",1) //some condition
GlobalLT("P#KivanOffence","GLOBAL",10) //some condition
OR(4)													  //the list of talks controled by the timer
Global("P#KivanSweetTalk","GLOBAL",1)
Global("P#KivanSweetTalk","GLOBAL",3)
Global("P#KivanSweetTalk","GLOBAL",5)
Global("P#KivanSweetTalk","GLOBAL",7)
THEN
RESPONSE #100
RealSetGlobalTimer("P#KiSweetTalkTime","GLOBAL",1) //set timer to automastically advance global after the talk is done
IncrementGlobal("P#KivanSweetTalk","GLOBAL",1)
IncrementGlobal("P#KivanLove","GLOBAL",1)
PlaySong(0)
PlaySound("kivan00")
StartDialogueNoSet(Player1)
END

IF 
InParty(Myself)
RealGlobalTimerExpired("P#KiSweetTalkTime","GLOBAL")
OR(5)
Global("P#KivanSweetTalk","GLOBAL",2)
Global("P#KivanSweetTalk","GLOBAL",4)
Global("P#KivanSweetTalk","GLOBAL",6)
Global("P#KivanSweetTalk","GLOBAL",8)
Global("P#KivanSweetTalk","GLOBAL",10)
THEN
RESPONSE #100
RealSetGlobalTimer("P#KiSweetTalkTime","GLOBAL",1800) //set timer for the interval between talks
IncrementGlobal("P#KivanSweetTalk","GLOBAL",1)
END

 

 

hope that helps!

Link to comment

If I understood the code correctly, the use of ORs and INCREMENTs will fire the talks in proper order, alternatively even and uneven number?

 

The first block of the script sets the first timer, the second one triggers the uneven numbered talks and starts the timer for the next (even numbered) talk, and the third one triggers the even numbered talks while starting the timer for the next (uneven numbered) talk. Am I right?

 

This would mean that there is no need to start a new timer at the end of each dialogue in the .d file?

This really looks great :) Thanks so much!

Link to comment

I don't mean to contradict Domi, because that would be stupid. I've been having some trouble advancing the talk counter that way. Gavin's a little more script-heavy than most NPCs, but I've got a longer short timer, and it still fails to advance the global sometimes, particularly across resting, if another NPC talks right away, or if the PC initiates some action right when the talk was supposed to fire.

 

I'm presenting this as an alternative that also works.

 

I'm using this to script talks:

 

IF
 InParty(Myself)
 Global("B!GavinFriendtalk","GLOBAL",0)  //no friendtalks yet
 Global("B!GavinFriendOnly","GLOBAL",1) //they're just friends
 GlobalGT("B!GavinFriend","GLOBAL",0)  //they *are* friends
 !Global("B!GavinFriend","GLOBAL",3)  //they haven't ended the friendship
THEN
 RESPONSE #100
SetGlobal("B!GavinFriendtalk","GLOBAL",1)  //open the global
RealSetGlobalTimer("B!GavinFriendTimer","GLOBAL",600) //10 min timer
END


IF
InParty(Myself)
CombatCounter(0)
!See([ENEMY])
RealGlobalTimerExpired("B!GavinFriendTimer","GLOBAL") //timer is expired
 Global("B!GavinFriendOnly","GLOBAL",1)  //Gavin and the PC are just friends
!Global("B!GavinQuietFriend","GLOBAL",1)  //PC hasn't told Gavin to shut up
Global("B!GavinFriendMatch","GLOBAL",1)  //the next 3 lines mean they are friends
GlobalGT("B!GavinFriend","GLOBAL",0)
!Global("B!GavinFriend","GLOBAL",3)
!AreaType(DUNGEON)							   //no friendly chatting in dungeons
OR(6)													   //there are 6 timed talks
Global("B!GavinFriendtalk","GLOBAL",1)
Global("B!GavinFriendtalk","GLOBAL",3)
Global("B!GavinFriendtalk","GLOBAL",5)
Global("B!GavinFriendtalk","GLOBAL",7)
Global("B!GavinFriendtalk","GLOBAL",9)
Global("B!GavinFriendtalk","GLOBAL",11)
THEN
RESPONSE #100
PlaySong(0)
PlaySound("BGAV_S1")
RealSetGlobalTimer("B!GavinFriendTimer","GLOBAL",5400) //reset timer 90 min
IncrementGlobal("B!GavinFriendtalk","GLOBAL",1)   //advance global to start talk
StartDialogNoSet(Player1)					 //start talk
END

 

Then I close the global in the first line of the talk.

 

CHAIN
IF WEIGHT #-2
~Global("B!GavinFriendtalk","GLOBAL",2)~ THEN ~B!GAVINJ~ BGavinFriendtalk1
~Since we're going to be travelling companions for a while, I would like to get to know you better.~
DO ~SetGlobal("B!GavinFriendtalk","GLOBAL",3)~  //advances global
END
++ ~All right. Why don't you introduce yourself properly.~ EXTERN ~B!GAVINJ~ BGavinFriendtalk1.1
++ ~I already know you as well as I want to know you, Gavin. Cut the smalltalk, and get back in line.~ DO ~SetGlobal("B!GavinFriend","GLOBAL",3)~ EXTERN ~B!GAVINJ~ BGavinFriendtalk1.2

Link to comment

Actually I do that too in IWD2NPC, because at some point the talks stopped advancing via script. But I didn't know that the problem happened in BG1/BG2 as well.

 

Belerinde, to prevent 2 talks happening on rest, try checking for our "universal" at rest timer. It's what prevents all BG1NPC 'at rest' talks from happening at once. :)

Link to comment
Actually I do that too in IWD2NPC, because at some point the talks stopped advancing via script. But I didn't know that the problem happened in BG1/BG2 as well.

 

Oh yeah. Big time, especially with an NPC that's running a lot of script.

 

Belerinde, to prevent 2 talks happening on rest, try checking for our "universal" at rest timer. It's what prevents all BG1NPC 'at rest' talks from happening at once. :)

 

Where do I find this beastie? I've been looking, but it's buried somewhere.

Link to comment

Thanks to both of you. I will code it when I'm done with the quest.

 

A little word of warning though. The One-Day NPC is *a myth*! How could you stop develloping a NPC after only one day?

I wanted to do it, and here I am with precisely:

11 scripts

12 creatures

9 dlg files including the NPC's one (1265 lines of code, and I haven't started expanding it, this is still the one day version of the dialogues)

Only 2 portraits, pfiou :)

 

I suppose I got caught in modding... :hm:

 

Done so far:

Quest for chapter 2. I hate it. It seem way to easy to me and the scenario somewhat... lacky. My base idea was OK, but I did not turn out exactly as great as I thought it would. I guess I will had mini-quest that will trigger if Hagen is in the party but with no relation to his past history. That should do the trick.

 

A creature at Brynnlaw that will appear if you started the quest in chap 2. He'll give you some more information about the villain.

 

To do:

Quest for chapter 6: encounter with Hagen's nemesis, then encounter with the villain.

Friendship path using Domi's and Berelinde's advice.

More interjections and banters.

This polymorph spell thing.

 

And to give myself some more work, I was thinking about a ToB NPC somehow related to Hagen... But that's only a vague plan (not so vague actually, but still a plan).

 

Have to try and be methodical...

Link to comment

I can't believe I haven't posted there for two month; I'm so lame...:D

No update but the mod will be going. I have been lazying a bit too much, not I got caught in uni-work, but I should be free from essays and readings after the end of the month, and go back to my modding activities.

 

I hope I'll remember where I am in the devellopment of it :)

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...