Aller au contenu

Photo

The Black Scourge of Candle Cove -- Tchos' development diary


  • Veuillez vous connecter pour répondre
1056 réponses à ce sujet

#551
Guest_Iveforgotmypassword_*

Guest_Iveforgotmypassword_*
  • Guests
I remember not so long ago when I played NWN1 on my laptop I didn't know anything about bards singing and thought the woman companion was smoking everytime she stood around, it was only on a closer inspection that I realised it was notes !

I've just had a look at some of your other videos and it's all looking very impressive indeed.

#552
Tchos

Tchos
  • Members
  • 5 086 messages
Heh, I didn't even know NWN1 had animated musical notes. These were inspired by the animated musical notes I saw for bards in a DDO review video. I just fired up NWN1 and loaded a bard character to see what it looked like, and you're right -- it does look like she's smoking from a distance. I think mine is an improvement. :)

#553
Tchos

Tchos
  • Members
  • 5 086 messages
Today I fleshed out the quest include script. I packed a lot of code into my quest marker/journal update wrapper, to make it as flexible as the original journal updating function while requiring less typing for most tasks, and also handling the quest indicators. So then I needed to test it, and I decided to use a series of triggers for it.

So, then I also took the time to make a generic trigger On Enter script packed with loads of optional variables to give it plenty of utility, and made a trigger blueprint with those variables attached. Entering one of these triggers can update a journal entry, change quest markers on up to two NPCs, send a feedback message to a spoken string, the chat log, and/or the notice text, and run another script if you need more options.

I'm not sure how many different kinds of quests can be made with triggers, though, so it may be of less use than the similar set I made for the On Use for placeables.

Anyway, it all worked without problems, which is good.

#554
Tchos

Tchos
  • Members
  • 5 086 messages
Okay, what have I been doing? Currently, I'm working on the control scripts for the guided tour, where the guide will have to stop and wait for you to follow if you get too far behind or go off and do something else, which you're probably going to want to do. So I've been learning how to use those default waypoint functions and setting special tasks to do at each waypoint, and pausing/restarting the traveling between waypoints on certain conditions, chattering all the while.

It actually looks like it should be pretty robust, and I generally like the way they have it set up, though I think certain things could be a little less cryptic. Also, I don't know much about standards, but I really don't like the built-in scripts that use all-caps variables. For constants, I can understand it, but local variables? Tags, too. My policy is to use all-lowercase tags with underscores separating the words. It takes less space in the box, it's easier to read, and it's consistent with the resrefs and other fields. It's only a bother to keep straight when I have to work with other people's code or items that use something other than lowercase, like the fishing items, which have all-caps tags, but all-lowercase template resrefs and resource names, and I end up working with it that way rather than renaming them all and trying to to a search/replace in the scripts to get them all in line with my way.

#555
Dorateen

Dorateen
  • Members
  • 477 messages
As long as this tour guide doesn't come looking for our group, telling us to stay together and keep moving, we've got a busy schedule to keep!

Ah, the fun of all the little scripting details like tagging conventions. You probably can't wait to move on to the final push and playtesting. 

#556
Tchos

Tchos
  • Members
  • 5 086 messages
Hmm, sounds like you're referring to something I don't recognise. But she will not come looking for you. She'll just wait until you come back into range, speaking up every so often to help find her again (hopefully in a non-irritating way -- and of course if you get far enough away, the text won't show up anyway), and then continue the tour when you meet up with her.

I don't think the final push will be pleasant, but it'll be nice to have it out there.

#557
Tchos

Tchos
  • Members
  • 5 086 messages
In dealing with the barks, I've used a few different methods. One is direct from the script, via SpeakString(), and another is from a dialogue file via SpeakOneLinerConversation(). For the latter, I've been having each line check for a "current line" variable, and also incrementing it to the next number so that the next time the conversation is called, it uses the next line. But I've also looked at the gc_node() condition that can be set in the conversations, which is supposed to act as an index so that you can make a script call a particular line in the dialogue file. That seems like it would be more convenient, but I can't seem to figure out how it works, and I'm wary of using something like that when I don't understand it.

What I mean is, I can't see how it "knows" which node to bark, or rather how it keeps track of what to bark on different conversations. The trigger script gtr_bark_node calls a function called DoBarkTrigger(), which sets a local integer called "sn_NodeIndex" on the entering creature, and then calls SpeakOneLinerConversation(), but since SpeakOneLinerConversation() is a built-in function, I can't see how it's using this local integer. I've tried to find documentation on that function, but I can only find examples of it being used, not an explanation of what's going on underneath. For instance, does sn_NodeIndex get reset automatically, and if so, when?

I'm guessing I can still use it, without understanding it, if I just set the integer on the NPC at each appropriate time before calling SpeakOneLinerConversation(), as long as I have the nodes marked with gc_node. An experiment should give me that answer.

#558
Lugaid of the Red Stripes

Lugaid of the Red Stripes
  • Members
  • 955 messages
An alternative is to use custom tokens to encode whole lines of dialogue. You could have a simple one-line conversation that spits out a particular token, and then have a script that resets the token to the appropriate line at the right time.

So, for example, let's say that an NPC is using the custom token 9999. Their conversation would just be a single line that says "<CUSTOM9999>". Then you have your blocking script that's telling the NPC to move from one waypoint to another, or to do such and such animation for so long. Whenever that script gives the NPC fresh orders, just include a line like

SetCustomToken(9999, "Be patient, we're almost there");

They could trigger the conversation right then and there, but if the player clicks on the NPC again they get the same line repeated, so there's some redundancy built-in.

#559
Tchos

Tchos
  • Members
  • 5 086 messages
That does look like it would be a perfectly good additional method, and I'm comfortable enough using custom tokens now. But it makes me think I should probably just stick with SpeakString if I'm going to be writing out the barks in the script anyway. And thinking of it now, there may not be any actual advantage to using a dialogue file in this case, other than the separate one that has actual interactive dialogue with her. I'll remember the custom token approach, though.

#560
Alupinu

Alupinu
  • Members
  • 528 messages
Wow! Thos musical notes are really cool, so are the Z’s, nice detail. It’s the little thing like that, that will make all the deferent’s.

#561
Tchos

Tchos
  • Members
  • 5 086 messages
Glad you like the effects, Alupinu. ;)

An unusually brief update, but one of the tour control scripts is working perfectly using the built-in scripted waypoint system, and the start/stop one is very close to working. I mean, it's working now, but I need to adjust the placement of the commands so that the tour guide makes the appropriate barks on stopping and resuming. The barks for the tour itself are all fine. I like the way the tour came out. I hope everyone will find it amusing as well as informative.

#562
Tchos

Tchos
  • Members
  • 5 086 messages
This week's P&P session was great! I got to try out a Pathfinder base class I hadn't played before -- the Witch.

I'm having some trouble with the tour, actually. Whenever the tour is interrupted, whether it's from the player talking to the guide, or from getting too far away from the guide, when she starts up again she immediately delivers the speech she would have delivered at the waypoint she was heading toward before she was interrupted, and then takes off toward the next one, skipping the one she was moving toward. This is using the standard scripted waypoint system. I need her to resume heading toward the intended waypoint, and not deliver the speech until she gets there.

#563
Tchos

Tchos
  • Members
  • 5 086 messages
I used a custom On Conversation script and an extra line in the guide's heartbeat script to deal with the waypoints. Now, if she's interrupted for either reason, she'll resume toward the waypoint she was heading toward before the interruption, say "Now what was I saying...?" and then repeat what she was saying before the interruption. That works well enough, and is certainly as functional as it needs to be for anyone who's not actively trying to break the tour by constantly talking to the guide for no reason. So I think that part's done now. :)

Modifié par Tchos, 30 octobre 2012 - 10:59 .


#564
Tchos

Tchos
  • Members
  • 5 086 messages
I hope everyone had a good Halloween/Samhain/Day of the Dead. Today, I did some miscellaneous work here and there. I placed several walk paths in the main city, along with some necessary spawn points and points for NPCs to go after certain events. I still need to code the special stops in town.

I tested out one of the companions, and found that she needs more XP to start with. She starts at the right level, and with all the spells I specified, and with the animal companion name, but she only had 100 XP. I think I know where to fix that, though. I also tested to make sure she gains XP properly. Also, her weapon was unidentified.

While doing this test, I also found that there were some placeables I used as decoration that I need to make static, because they were able to be picked up. I fixed those.

I checked the companion script I used in the conversation to add her, and I had in fact specified 100 XP for her, because I had followed the directions for adding a level 1 companion. I changed it to 45k. Also added some companion-specific dialogue for her and her friend.

I found the texture of one of the custom heads I used became messed up. I have to check on that, and maybe rename the texture so it won't conflict.

I fixed the unidentified weapon by changing the blueprint. It's a campaign-level item anyway, and it's not going to drop from anywhere, so it's fine. Would like to know how to identify a specific instance in someone's inventory, though. Maybe if I change the blueprint to identified, then add the item to her inventory, then change the blueprint back to identified, the one in her inventory will remain identified? That's the way it seems to work for other containers.

I found that some of my creatures are carrying shields that show up as black boxes with question marks on them. They're just light ironwood shields, so I don't know what the problem is. They show up in the toolset. Maybe it's because its tag suggests it's an SoZ item? Or maybe I have something that overrides it incorrectly.

I changed it to a different shield, but will have to test it later to see if it worked.

#565
kamal_

kamal_
  • Members
  • 5 261 messages
black boxes with question marks is a missing texture.

#566
Tchos

Tchos
  • Members
  • 5 086 messages
That's a very strange texture issue. Before, when there was a missing texture, I just saw that 4-coloured one that said "missing texture".

Changing which shield it used didn't help, so I just removed the shield and increased its natural armour stat to compensate.

#567
PJ156

PJ156
  • Members
  • 2 988 messages

Tchos wrote...

Would like to know how to identify a specific instance in someone's inventory, though. .


I use a script to identify all items in the inventory at the time they join. That seems to work fine for me.

PJ

#568
Tchos

Tchos
  • Members
  • 5 086 messages
You mean in that character's inventory just before they join, or the party members' inventory after they join? The latter would be problematic if the player found a companion in a dungeon, and was carrying around some unidentified items waiting to go back to town, and the companion's joining made them all identified. I could look into the former, though.

#569
Tchos

Tchos
  • Members
  • 5 086 messages
Today I worked on an argument you'll probably have on your way to the shipboard confrontation. I have to take into account that you might want to return to the mainland for supplies rather than go directly to the confrontation, though I also provide some limited services as an alternative.

Also added another vendor, and his conversation.

Also added some actions and movement to another conversation (the Merchants' League Officer), which I had planned all along, but wasn't able to do earlier because of walkmesh troubles at the time. The people he's talking to will need to move, too, but I need to write a modified version of the function that moves a creature to a waypoint to include the commandability portions from the ForceExit function, because it seems much more foolproof.

#570
Dann-J

Dann-J
  • Members
  • 3 161 messages

kamal_ wrote...

black boxes with question marks is a missing texture.


They actually represent missing or corrupt MDBs. Models with missing textures will still show up (albeit with a gaudy 'missing texture' makeover).

#571
PJ156

PJ156
  • Members
  • 2 988 messages

Tchos wrote...

You mean in that character's inventory just before they join, or the party members' inventory after they join? The latter would be problematic if the player found a companion in a dungeon, and was carrying around some unidentified items waiting to go back to town, and the companion's joining made them all identified. I could look into the former, though.


Yes I do it with a script that looks at the characters inventory when they join and identifies everything. I found setting them as identified is a little flaky so did it by script.

PJ

#572
Tchos

Tchos
  • Members
  • 5 086 messages
Dann: That probably means there's something in my override folder interfering with it, since it appears normally in the toolset, and I have separate overrides for building and playing (for major tests, I temporarily rename the playing override).

PJ: Could you point me toward one of your modules where I would find that script?  I'd like to take a look at it.

Today was more conversation, movement, and spawning work, including for the main quest.  I added a couple of new branches and conditionals based on area and quest stage, but I still need to add the final bit that takes into account if the player chooses to come back to the mainland for any reason before tackling the boss.

Basically, if the player takes the time to resupply and rest on the mainland, this gives the boss time to prepare and summon more help, which makes that fight harder, and potentially even allows the boss to escape if the player takes too long.

This part of modding is actually one of my favourite parts.  There are a lot of parts that I enjoy, and others that I don't.  This is the part where I actually see results from all the groundwork I laid down beforehand.

I think I still need one more pass through the big, difficult-to-load city area so I can place a few spawn points I forgot, tag some doors with unique tags and put in their opening script so that I can potentially expand this module at a later time (by setting their usability flag to "true" and adding a second module), and add the necessary descriptions on the shop signs.  The town exit is already handled by a campaign conversation, so that can be expanded easily.

#573
PJ156

PJ156
  • Members
  • 2 988 messages
void main()
{
object oPC = GetPCSpeaker();
object oTarget;
oTarget = GetObjectByTag("ember");
CreateItemOnObject("nw_it_gold001", oTarget);
 {
 object oItem = GetFirstItemInInventory(oTarget);
 while (oItem != OBJECT_INVALID)
  {
  int nIsIDentified = GetIdentified(oItem);
  if(nIsIDentified == FALSE)
   {
   SetIdentified(oItem, TRUE);
   }
  oItem = GetNextItemInInventory(oTarget);
  }
 }
}


The script is above. Its a lilac soul generated script called from a convo. It has not let me down yet though you need one for each npc. Someone better at scripting could make is generic I guess.

This one is from Last Days of the Raven though it is dotted around all the mods generally it will be called 0000_identify_**

Hope this helps,

PJ

#574
Tchos

Tchos
  • Members
  • 5 086 messages
Thank you. From the look of it, you could just change...

oTarget = GetObjectByTag("ember");

to

oTarget = OBJECT_SELF;

...and that would make it generic, because the conversation belongs to the NPC.

#575
Tchos

Tchos
  • Members
  • 5 086 messages
Added the smith, and resisted the urge to name him Morrissey, or Bigmouth, or something like that. The smithy is largely from a prefab, with some alterations and improvements. I also added some scripted waypoints for more activity to take place within, which is a delightful touch I saw used to great effect in the Dark Water modules.   I haven't seen it in action, yet, but it should work.

I included two people in the shop, similar to the way it was in the Denerim smithy in Dragon Age: Origins. One is the vendor, and the other is the craftsman.