Tchos Posted October 20, 2012 Author Share Posted October 20, 2012 (edited) After that long update from yesterday, all I did today was another special effect. http://www.youtube.com/watch?v=2IwYOanuFIo Edited October 20, 2012 by Tchos Link to comment Share on other sites More sharing options...
Tchos Posted October 21, 2012 Author Share Posted October 21, 2012 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. Link to comment Share on other sites More sharing options...
Tchos Posted October 23, 2012 Author Share Posted October 23, 2012 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. Link to comment Share on other sites More sharing options...
Tchos Posted October 24, 2012 Author Share Posted October 24, 2012 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. Link to comment Share on other sites More sharing options...
Tchos Posted October 27, 2012 Author Share Posted October 27, 2012 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. For the record, I ended up going with SpeakString() in the script itself rather than using a conversation file. Link to comment Share on other sites More sharing options...
Tchos Posted October 30, 2012 Author Share Posted October 30, 2012 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. Link to comment Share on other sites More sharing options...
Tchos Posted October 30, 2012 Author Share Posted October 30, 2012 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. :) Link to comment Share on other sites More sharing options...
Tchos Posted November 2, 2012 Author Share Posted November 2, 2012 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. Link to comment Share on other sites More sharing options...
Tchos Posted November 3, 2012 Author Share Posted November 3, 2012 Changing which shield it used didn't help, so I just removed the shield and increased its natural armour stat to compensate. Link to comment Share on other sites More sharing options...
Tchos Posted November 5, 2012 Author Share Posted November 5, 2012 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. Link to comment Share on other sites More sharing options...
Recommended Posts