Thursday, 27 March 2008
Anyway, now that I have finished writing the XML tutorial, I am able to turn my attention back to the campaign proper and continue developing the system for the new era - and today I have been taking a closer look at the crafting system, especially with respect to monster drops that can be distilled to create the essences.
In my examination of the current system, I have found that "distillable" drops do not appear to be as well automated as I first thought they would be. I thought they were all controlled via a "crafting system" that checked against a 2da file when the monster was killed, which in turn made a distillable item be dropped. This, however, is not the case. It seems the current official way to allocate distillable monster objects is to place them directly on the creature's inventory ready for when they die. This appears very inefficient to me and so I spent some time today adding an extra OnDeath script to the monsters so that a distillable object would be created with the body of the monster if certain criteria are met ... including ensuring that at least one member of the player's PCs has an alchemy skill of note. (Four points or greater.)
The new system works fine, although I still need to tweak it a bit to ensure it works as I like, including varying the chance of drop according to the PC's skill and only making certain items available at certain times. Overall though, the system appears far better structured and automated than the official version currently in place, and will, hopefully, be more versatile by the time I have finished it. The only thing a builder has to do to ensure the system works is to ensure the creature that can make a drop has a variable set on it at build time, which is easier to do than placing an item within their inventory anyway.
Tuesday, 25 March 2008
UPDATE: Download Here.
Monday, 24 March 2008
The Life Essence System
Once that is done, I intend do some more work on the Life Essence system. As readers who have been following the blog will know, Life Essence is something new to the new era of Althéa and a product of The Changing and the disappearance of Colour Magik. It is the source of power by which everything about life is altered and grows.
I have already considered one of its functions that I wish to develop, and now just have to see if it is practical, not only from a gaming perspective but also a scripting one. In this case, it is the Life Essence's ability to transform the mundane into the magikal! The normal Item Creation Feats will remain as normal, but the Life Essence system offers a way for the player to circumvent the system if they are prepared to pay the price! Some players may take up the opportunity to do this, whereas others may consider Life Essence too valuable for other projects to consider "wasting" it on such things. As I progress, you will learn more ....
Friday, 21 March 2008
I finally boxed up and put away an old analogue 20" monitor that sat in the corner of the room as well. So that means I now have two boxed 20" monitors (analogues) that I no longer use and are up for grabs (£25 each) if anybody can make use of them. I would give them away, but my HD recorder has just broken and I am hoping to make the money I need to get it fixed. They are both Hitachi (CM802 and CM827), fully functional and still in their original boxes.
While I was in the tidy up mood, I also swapped over the speakers I normally use to Netmeet with one of my players. The previous ones were starting to distort and make it difficult to hear him at times. These newer ones appear to have a much better tone and I have not noticed any distortion.
Next, I swapped over a couple of drives: I removed a DVD writer from my old PIII and swapped it for the CDROM that was a second drive in my main computer. The problem was that NWN2 needs a DVD drive to run, and as I normally like to use my DVD to backup data, it meant I was always having to swap discs to accommodate both operations. It meant I started to slack on my backing up, which is not good, and so I made the swap. As I don't use the older PIII for anything much nowadays, it won't need a DVD anyway ... I hope.
Finally, I swapped over a mouse on one of the client computers that I found was having difficulties with the right mouse button not opening the menus properly while in the game. The replacement mouse appears to work fine.
My wife decided to do some tidying of her spare room as well. Needless to say, it meant we were doing a lot of shuffling around, moving stuff from room to room and what we did not throw away, went into that extra-dimensional closet of all storing: the loft!
I am glad that is done for a while again - and with the room clean, it does inspire me to finish off the XML tutorial I have been working on. I can report that all the code is now finished and working. All it needs for me to do now is simply finish the writing and upload it. Then, finally, I may be in a position where I can return to my campaign, knowing I have cleared all the cobwebs from both my room and imaginative thinking.
Thursday, 20 March 2008
As you may or may not know, I have been eagerly awaiting the start of this module for my group of players for years, ever since I first came up with the idea in October 2004! Since that time, however, I have lost two members of my group, but, in turn, have gratefully received a new member: Geoff (known to the Bioware forums as Quillmaster) . It means I now have three players who have started the Soul Shaker adventure with me as their DM.
Last week was a bit of a disaster when it came to the module changeover as you may recall, but I am very pleased to announce that this week went smooth as silk, as the saying goes. There were absolutely no issues during the session, although this should come as no surprise considering all the testing the module received and the large number of fixes I made for it since it was released on the Vault.
Basically, the session went very well, and I was pleased at how well the players quickly adapted to the "real time" combat, the first experience of such within the Althéa Campaign. A lot of the time was also spent in getting to grips with the differences that the demi-plane threw at them with regards to their PC's nature and development. It was interesting for me as a DM watching them learning to adapt to the strange situation and begin to understand the various roles each of them could adopt to help survive. I look forward to the next time we play, which may be as early as next week or the week after, subject to player availability. Either way, if it is as fun as it was this week, then I will be pleased. Read about this week's session in the synopsis at the website. For those players interested in keeping a copy of the previous chapter of the adventure, the download for the collection of synopses for Torén Norus is now available from here.
You will notice that the normal XP and TIME details in the header to the synopsis brief are different this week. This is because XP is calculated differently within the demi-plane and that it is only relevant at the end of the module. Therefore, I will display the heroes current "Realm Level" instead. Furthermore, TIME does not flow at the same rate as it does within the Prime Material Plane, and therefore, this too becomes an irrelevance. For this reason, TIME will always be displayed as UNKNOWN. Not even the ratio of time flow is currently known.
SYNOPSIS SNIPPET: (REALM LEVEL: Zero) TIME:Unknown
"As the combination locked door opened, however, a small group of undead humanoid creatures spotted the heroes from the other side, and immediately lurched towards the heroes screaming, "Give me flesh!"
Grimbold shouted an immediate retreat, but in the confusion Myara thought it was for the attack and dived into the undead group even before she had readied her club. Fortunately, Karasten mustered his will to deliver a "Spirit Attack" and found he successfully started to deliver bolts of energy towards the undead enemy. Realizing what had happened, Grimbold turned back and went to the halfling's aid." Read more here.
Monday, 17 March 2008
During my writing of the tutorial, I realised there was one term I was using that was a little misleading and so I decided to edit the word out for the correct name. However, I hope I explained its usage clearer than others have done in the past: Tags! In my working out of the code, I always saw the things like UIScene as "functions" and referred to them as such within the tutorial. However, as I learned more, I could see that it is the type of lines of code written above (in the first paragraph) that are actually the functions in XML and that these items I had been calling functions were merely "objects" with certain "tags", which I assume have been predefined by Obsidian. So, I edited all my incorrect references to "functions" and replaced them with the correct term of either "object" or "tag". Since then, I have also learned that what I have been calling "parameters", others are calling "attributes". However, as the word "parameter" has not been readily used elsewhere for XML, I have left my wording as it is for the time being, as it still makes more sense to me as a beginner, which is the audience I am aiming for.
I made another big discovery when testing my code as well: Functions like the two listed above must not have any spaces between their parameter listing. This had me stumped for ages, as I could see nothing wrong with my code and it was not until I copied and pasted a line almost identical to mine from another file and found that worked, did I then discover the spaces in my own code that made the difference.
Another discovery I made was that it is not yet possible to design a custom button that can be dropped onto a hotbar. Looking at the parameters available, I thought this could be done, but in practice it simply does not work. Then I checked the forums and someone else had mentioned they would like the facility to be able to do this, and so I assume it cannot be done after all. If anybody knows any different, then please let me know.
I intend to spend some more time looking over XML code made by others if and when I get the chance, especially some of the more advanced stuff, like that done by Adam Miller as part of his Dark Waters series. Maybe I can learn one or two tricks from him there.
Thursday, 13 March 2008
There were a few things worth pointing out though, some as a result of the crash and others just observed. This resulted in a final TNPatch for Torén Norus (0.05), even though we are finished with the mod:
1) Hit points calculated for the Realm went wrong after the player refreshed their main menus because a variable set during transfer was based upon the PC they were controlling and not the PM (Player Mannequin). This meant a couple of things (number of attacks and hit points) upon arriving at the Realm would have been inaccurately calculated for the PM, which is considerably lower level than the PC it was supposed to represent. This was the main fix for 0.05.
2) During my trouble-shooting to find what had happened, I discovered an exploit in Soul Shaker regarding Soul Fragments and fixed that. This and a typo correction were the 0.19 fix for Soul Shaker. Note, I will not upload these to the Vault until we have played Soul Shaker to completion. Then I will upload all fixes that we found along the way. NB: These are very unusual and unlikely to be encountered bugs and so I am not worried by them.
3) I added new code to help ensure the lich conversation starts when you encounter it. Again, this is a redundant fix for Torén Norus, as we have now finished it. I just like to make sure it is fixed for my own satisfaction.
Lastly, just to go back to the main crash that occurred. The only other thing that I could think of that may have been a contributing factor is that the level the module started in may have been too big for the game engine to handle across the Internet. In future, I will try to ensure all such module changeovers start in a small area by comparison, so that the game at least loads for all players before we start properly.
SYNOPSIS: (SESSION XP: 2579) 17/09/1197 (DEATH: Morgellin)
"A large round stone table stood in the center of the room, surrounded by four thrones: This was the ancient Meeting Chamber that the heroes knew lay somewhere within the tower, and now they had found it.
Yet, as the stared into the chamber, a ghostly voice sounded in their heads at the same time as they spotted the emaciated husk of a humanoid being sitting in one of the thrones. Almost by instinct, the heroes knew they had found Terrell ... or what remained of him."
Wednesday, 12 March 2008
First, let me apologise to my players and say that I hope it did not spoil the otherwise fun experience up to that point. It turned out to be a rough night for them, as they also lost their cleric, Morgellin, to an Iron Golem breath when he rolled a one on his saving throw! Furthermore, as it was the cleric that died and there was still no way out of the tower, it meant Morgellin had to be packed away in a bag of holding until the heroes could find another way to raise him. (Messy!)
Regarding the crash again, the only consolation I had was the fact that it did not appear to be anything to do with my code as such, but it simply seemed that NWN could not handle the module changeover over the Internet where one of the players was accessing the game. Why this would be the case, I don't know, but as soon as they were not involved, the module changeover process went smooth as silk.
So, in the end, I had to reload the game just for the LAN players, allow them to enter the Soul Shaker module from the Torén Norus module first, and then get the player on the Internet to do it separately afterwards. His joining still caused the game to crash, but by then all the data for his PC was recorded, and it meant we could start afresh with the Soul Shaker module and simply rejoin the module bypassing the module changeover step.
Unfortunately, the process did mean the players missed out on the introduction movie, and the opening speeches by Terrell, but at least we reached the point where we could save the game ready for the next time we played. I had looked forward to this moment for so long that the eventual disaster of the transition really annoyed me. I just hope now that the rest of the gaming experience is one of smooth sailing.
In the meanwhile, I ask that all players download and read the manual ready for the next time we play. The game is obviously a lot different from anything you will have experienced before, and even the brief introduction that we did see should have given you a clue to as much. The manual can be downloaded from here: SOUL SHAKER GAME MANUAL. Please spend some time reading pages 5 - 29 so that you are familiar with the basic mechanics of the game. Combat is no different from normal (real time) play, but character development and surrounding mechanics is definitely affected upon this demi-realm of the lich. I advise NOT TO READ past page 29, as it starts to speak of things that the player would not yet know about the Realm and so it would spoil their experience if they did.
After that disappointment and the extra time it took me to sort out the problem with the game to make it ready for next week, I have not had time to sort out the regular synopsis yet, but hope to find some time tomorrow - so please check back then.
On a positive note, I have been making headway with the XML & GUI Tutorial. I am making all sorts of discoveries about XML as I write it,which I hope will help others when the tutorial is finally released.
Monday, 10 March 2008
First, however, I want to be able to right my own XML file to demonstrate the level of knowledge I have reached and maybe to help show some of those elements that are not obvious, like the different fonts available.
Hopefully, once I have that off my chest, I will be able to start looking at writing more towards the first module of the campaign within the new era. I still need to add the books sections (which is why I did "Readable Books"), but maybe I can look at one or two other areas of the mechanics from a different approach now that my knowledge of XML has improved. I will have to wait and see how the mood and imagination takes me.
Sunday, 9 March 2008
I have to confess that I like the new GUI interface operations and how we can, as builders, develop various feedback and displays for our players. To me it adds a new dimension to the game, and allows me to help structure a module to keep players aware of events and help keep the plot focused. Or, I may also be able to design an interface to make use of new and complete independent systems that make the world of Althéa unique.
The only problem is that XML is new to me, much like script was when I first encountered it. However, whereas script appeared more logical, XML requires a little more forethought, as much of what you are doing is building something visual with numbers (or so it seems to me). In script the objects to code with were mostly already present, whereas XML is more like coding the object in the first place.
Therefore, if I wanted to make more use of the new GUI interface, I needed to start looking at what others have done and pull them apart to understand it. To help me in this project, I copied and printed off the small amount of information available at Obsidian's XML Blog. The XML information is on the first few pages (oldest) of the blog. I then opened up some XML files that others have written and started to try to make sense of everything.
I found that if I copied the text into something like Word and then highlighted different sections according to when each "function" appeared to start and end, I began to see a pattern among the otherwise just "rush" of text. Then, comparing the highlighted code with the information I copied from Obsidian, I could begin to see how the functions were being used, and even managed to start editing my example XML to test in game. The results were encouraging, and while I am not going to be making many of my own to begin with, I do believe I have enough knowledge now to be able to work on someone else's XML file and alter it for what I need. As there are quite a few official and unofficial files available, I should be able to do what I need when the time comes. (I will let you know.)
Here are some of the XML commands that I have started to get to grips with:
< !-- COMMENTS HERE -- >: How to make comments in the XML code.
- UIScene : Defines the main GUI size, placing and function. (The box that appears.)
- UIText : Places text within the main GUI.
- UIButton : For placing a button, but appears to rely a lot of UIFrame for visual look.
- UIFrame : Appears to be used with UIButton to define an image.
Feel free to comment on XML coding if you can help enlighten me to anything or lead me to a better understanding of it. There are still a few functions that I need to look at more closely and learn how all the different parameters interact with other, including:
- UIObject : Appears to be used with most other functions in some way.
- UIListBox : Has similarities with UIPane.
- UIScrollBar : Appears to be used UIListBox (among others).
I am pleased to report that my Readable Books hak has been very well received from the NWN2 community, and so far, has received all tens for its contribution. :) (Link to the mod is on the left.) Note, I originally uploaded this module into the mods section, but later had it transferred to the Custom UI section, which is more appropriate. This has, however, made some of the comments normally shown within the "View Comments" section unavailable. They can, however, still be read from the comments below the module listing.
Friday, 7 March 2008
I am spending a little time just surfing and looking at other NWN stuff in general and must confess how amazed I was when I saw Adam Miller's latest module "Dark Waters 2 - Beyond The Sea". It was the new GUI and custom content that has astonished me at the moment and I can say that I can't wait to take a look at what he has done and to see if I can learn anything more new from it that may be useful for some of my own designs. It's when I see work like his that I realise I still have a lot to learn about scripting and XML files in general. I have added his website to the links to the left, and will be keeping a close eye on his work.
Take a look at this video link to see what I mean:
Thursday, 6 March 2008
- I needed to add some books that some PCs needed to carry around for the resting system I am working on.
- I liked the way these books worked and always intended to have them for the new campaign, but wanted an easier way to add or remove the text data.
The original design by clubok required editing a TLK file and updating a 2da file so that the text could then be viewed. This has some advantages in that it is probably easier to write the text in the first place, but does, in my opinion, require too much extra work trying to keep track of stringrefs and having to update the 2da file with the various types of information it needs to work properly. I also believe that because my version is based in scripts, it is probably more flexible to the everyday builder. Each has its merits, and so I felt there was room for my version to be built, even if it is just me who ends up using it. ;)
One of the advantages was that I was able to add a "Picture Book", which is basically a book with pictures added. The pictures have to be added to the hak before build time, but after they are added, they can be selected to be viewed as if a page of a book. I included an example in the demo mod, but the pictures were not the best possible, as I did not want to spend too long on preparing them.
Not Bookworms - Bugs!
During my alteration of the code, it gave me a chance to learn a few more things about NWN2's tool set in general. Most of the time things went smoothly, but there were a few things that had me stumped for a while. Three things were related to some bugs in the engine:
1) Inventory Item Limit: The first problem that I encountered was that I was unable to limit the number of items that a placeable could hold. I wanted to reduce a bookcase's contents limit to no more than about ten items. Unfortunately, even though I changed the inventory limit figure, it would still default to a high number. I learned this is a known issue and will be dealt with soon.
2) SetFirstName(): The second issue that I encountered was to do with renaming an object using SetFirstName(). This function is supposed to work in a similar fashion as SetName() from NWN1. All my debug testing showed it to work, but the item would not change its name in game. It turned out the bug is that the name does change, but it is not updated on the item until after it has been moved within the PC's inventory.
3) GetHasSpell(): The last bug I encountered, which is probably the most frustrating in some ways, was the GetHasSpell() function. The function is supposed to check if a PC has a particular spell memorised. Unfortunately, it will say that a wizard has a Summon Creature spell memorised (for every level) even when they do not. I tried to exclude these particular spells from the check, but it prevented all the spells from working for a sorcerer. :(
There were a couple of scripting issues that came to light for me using NWN2, which I was not aware of when using NWN1:
1) Include Compiling: The first issue was the very important requirement to recompile scripts that rely on an include script, if the include is changed in any way. I don't ever recall having to do this when using NWN1, but it may be because I have done more with include scripts using NWN2 than I have done before when using NWN1. In this module I had three scripts that each used the include script called "alb_booktext". As this include file was where I write all the main text for the books in question, I soon came to realise that compiling and saving this single script to test my alterations in game was not enough. Basically, the three scripts that called upon the data from this include file also needed to be compiled and saved, even though there was nothing directly being changed in them! Now that I know this happens, I write it here as a reminder to myself and anybody else who may be wondering why a script is not applying updates one may have done to it.
2) Script Order: The second scripting issue I encountered was based upon the order in which my code was firing. At first I could not see any reasons why my loops were not working correctly. They would run through the loop for a while and then appear to drop out. It turned out that I was probably asking too much from the loop, and by altering where I did certain checks for the object being tested within the loop, it allowed the function to complete the loop without dropping out. The function in question is written below, and the original problem was that I was doing the if checks for the iCount number before checking if the PC had the spell. By moving the if checks until after the spell had been checked first, the script worked fine. Unfortunately, the "OR" commands do not show if I type the script and so I will have to rely on an image to show what I mean:
The rest of the coding went fairly smoothly. I would like to thank diophant on the NWN2 forums for pointing me in the right direction with one of the scripts. Check out the ReadBook.PDF file that comes with the ReadBooks module for more information about setting up the books themselves. (Link to the left in My NWN2 Modules.)
Wednesday, 5 March 2008
"Gary Gygax, co-creator of the first role-playing game Dungeons and Dragons, has died at the age of 69. Gygax, who developed the game in 1974 with Dave Arneson, had been suffering from health problems for several years.
Famous for its mythical creatures and odd-shaped dice, Dungeons and Dragons was an instant success that spawned a slew of video games, books and films. Gygax was also an author who wrote numerous fantasy books, including the Greyhawk series of adventure novels. He died on Tuesday at his home in Lake Geneva, Wisconsin, leaving a wife and six children. "
Readable Books (NWN2 Mod)
For the last few days, I have been rewriting clubok's "Readable Books" module to work without 2da and tlk files. I loved the original concept, and having books look like books adds a lot to the atmosphere of the game in my opinion. It was always something I intended to do, and as I have reached the stage where I needed to define the wizard or sorcerer's spell book and cleric's holy book for when it comes to resting within the new era of the campaign, I made the leap to go ahead and do it.
The end result, I believe, is a much easier process to manage , where all data is added or changed within one script within the module, rather than having to edit a tlk file and a 2da file, with confusing string resrefs and large tlk numbers. I have been able to maintain all the events that the original could do and even add one or two new elements of my own, including viewing pictures within a book.
I am in the process of finishing off the PDF manual that explains how to add new books and update the text, and once that is complete, I will upload everything to the Vault and give a link from the menu on the left hand side. Furthermore, I will give some feedback on the building of the module that may be useful to others. For those familiar with clubok's version, you may notice I have made a difference that the contents conversation stays open all the while the book is being used. I personally found this easier to work with.
Torén Norus Adventure Postponed
Unfortunately, unforeseen events caused me to have to postpone this week's D&D adventure, which means the launch of Soul Shaker has been put back another week. It has been a long time coming since I first started working with it in October 2004, and so one more week should not make much difference. As it happened, the Internet appeared to be somewhat sluggish tonight, and so it may have hampered our gaming experience anyway.
First Ever NWN2 Internet Connection
As the D&D adventure was postponed tonight, one of my players and I tried to play another CRPG. However, as that was hampered by the Internet problem, we then decided to try to use NWN2 for the first time over the Internet instead, using my Readable Books module as a test. At first, he kept being kicked out as he tried to join. Then, I quickly recalled something about a PWC file and after creating the file in the toolset and sending him a copy, we managed to connect fine.
I was a little disappointed with the functionality of the DM Client, as even the movement felt a little jumpy rather than smooth. It was probably due to the fast movement that the DM has, but it still felt a little awkward to use. I also found the controls a lot harder to find and some of the basic stuff (like searching an inventory), I could not find at all!
However, my use of the DM Client is a long way off yet, and so I hope many of these issues will be resolved by the time I come to use it, or I will have a better computer on which to run it, or I may just get used to using it in time.