Who will be rebuilding the PRC to take advantage of the new unhardcoded possibilities?
Dark_Ansem
Member Posts: 992
Because I would like to contribute. I can't do much, but I can always try.
0
Comments
I wasn't checking NWN:EE for some time, can you tell me what unhardcoded possibility NWN:EE already brought? I didn't notice any to be honest...
However, eventually, new metamagic is going to be possible, as will be spellcasting classes with proper spellbook. So, the Archivist and other classes that make use of the workaround spellbook will likely need to be rebuilt?
As long as it isn't spellbooks or metamagic related it doesn't need to be unhardcoded. There is a work around for sneak attack and for unarmed damage progressions, so while opening them for some kind of hook-in scripting would be better it's not essential to implement features that use them.
The main difference is that haks preload. I've been doing some conversions of NWN2 based mods I was working on but I'm not certain I'll be releasing a pack for public consumption.
The problem with the unhardcoding of spellbooks is that we can't anticipate how Beamdog will decide to change the 2da data and encode it with scripting. The best you can hope is that spell scripts will only need minor editing to use new metamagic values.
Spontaneous casters are still easier to spoof, tho I think NWN might not have a GetRemainingFeatUses(int nFeat) function nor an AddFeat(int nFeat, object oPC) and RemoveFeat(int nFeat, object oPC) function so you're still kind of limited in what you can do neatly with modding.
Classes like Knight should work easily enough, and casting prestige classes like Force Missile Mage and Abjurant Champion should be doable within reason.
Plok is also trying to modularise PRC so that might be first step needed...
here is the link to the original thread: https://forum.neverwintervault.org/t/modularising-the-prc/653
First step is breaking up the dependency of the PRC scripts on the classes they provide - there's odd bits and pieces of if (SOME_CLASS) { DO A THING }else{ DO OTHER THING } littered everywhere and they get in the way of doing anything else. These need to be removed before anything else can be done.
TLDR plan for breaking up classes: instead of having the PRC being a bunch of scripts to implement a bunch of classes it will be a bunch of scripts to implement a bunch of class features (such as sneak attack, caster level etc.). Then a class initialisation script describes how a given class uses those features. That way there's no special case code for individual classes. All spells/active feats will remain untouched and should work exactly the same.
The word describe is incredibly important here. It turns the class code from being procedural (do this thing, give me the result) into declaritive (I want this result, how you get there is up to you). This means there won't be any class independent code - only a description of a class. No code means no dependency. As an added bonus, making a new class will be much easier because it now lives in one solitary directory.
I haven't really planned too far in advance of that, but I'd imagine that Tome of Battle, Psionics, Invocations, New Spellbooks, Crafting etc. could all be pulled out into their own systems. The key thing is to try and get a collection of files together that are for a particular system and have the rest of the code be oblivious to them. This is going to involve using ExecuteScript to call them rather than #including them and caching the crap out of things to minimise the performance cost.
There's a crap load of work to be done to achieve this. I still haven't even finished updating the tools the PRC uses yet. This isn't something you're going to be seeing any time soon.
P.S: I'm ignoring 2das/tlks. I can't do anything about them without some way of adding rows to 2das/tlks via hak instead of just overwriting the whole files. It could be that using an external program to generate the 2das/tlks is a way around this. You could also support the suggestion I've been putting forward of being able to add rows to a 2da via hak.
But I took the reigns of the PRC a couple years ago. Just got a team together as interest in it was not active till the EE edition came out.