Can anyone brief me on the current workings of the engine regarding a few things?
caruga
Member Posts: 375
Was just reading through the g3 fixpack docs and come across entries like:
I've seen instances where tweeting birds float above my character's head even though no status effects are attached to my character portrait. This tells me either that the engine doesn't have inheritable script-logic, or it isn't using it maximally, to be able to snare such inconsistencies across the board without having to cut&paste checks everywhere, and make sure that, in this case for example, the status effect, its icon, and the visual attached to the character sprite are all mutually inclusive (I mention garbage collection; in this case the tweeting birds are the 'garbage').
The various spells and abilities that allow party members to transform are a bit of a mess. They're pretty good about cleaning up leftover abilities if you shift to a form and then back to human, but if you start going directly between forms without returning to human and/or mixing in transformations from items (i.e. Cloak of the Sewers) you can be left with a lot of spell cruft by the time you're back to human. We patch many of the transformation spells to be more thorough in cleaning out leftover spells and abilities. This patch also corrects an oversight where the Cloak of the Wolf had no way for the wearer to return to human form prior to the expiration of the spell.EDIT: better example:
Melf's Acid Arrow FixesEven better:
Melf's Acid Arrow can be resisted by magic resistance, but the accompanying portrait icon was not.
Blindness Not Always Causing 'Blinded' String or Portrait IconWhat is going through the back of my mind when reading things like this is: do the game's systems have any sort of inheritance in regards to cleanup code and such, i.e. for example a common 'spell' script that has a prefix and postfix script that attaches to any narrower spell script that another spell inherits, and ensures the integrity of game-state (sanity checking and garbage-collecting); or do you have to hand-write everything, with lots of code-duplication?
Some spells and effects that cause blindness were not being accompanied by portrait icons and messages indicating that the target had been blinded.
I've seen instances where tweeting birds float above my character's head even though no status effects are attached to my character portrait. This tells me either that the engine doesn't have inheritable script-logic, or it isn't using it maximally, to be able to snare such inconsistencies across the board without having to cut&paste checks everywhere, and make sure that, in this case for example, the status effect, its icon, and the visual attached to the character sprite are all mutually inclusive (I mention garbage collection; in this case the tweeting birds are the 'garbage').
Post edited by caruga on
0
Comments
Heck, I'd like to see an engine (or a soft-coded layer) where you can write a new value into the variable and the game will automatically update the presently-displayed string using hooks, rather than the programmer having to tell the graphic to be redrawn in-code.
In the case of the transformation spells, the problem was that the transform-to spells have give-spell-X effects, but the transform-back spells did not always have effects to remove the spells. Furthermore, the transform-to rarely removed the spells granted by another transform-to, nor did the second transform-to's transform-back remove them.
Each effect has a field for whether it respects MR, and in the case of Melf's, one effect did while the other did not.
Effects are generally rather narrow, e.g., we have the 'blind' effect, which imposes the THAC0 penalty and cuts visual range, but does not itself cause an icon to be displayed, or show a feed-back string in the dialogue bar. For the icon and the feed-back, you need two more effects.
It is a bit intricate, and this sort of stuff probably accounts for a good percentage of the fixes in the G3 Fixpack.
IIRC, the THAC0 thing was that the (en)rage ability used a THAC0-mod effect that does not update the character sheet. The fix was to use the other effect, that does update the sheet.
I wonder if in the EE binary, the data structure you speak of could be interpreted by a macro/script-driven part of the engine, and it could be refined and enhanced by modders, assuming they don't already refine it themselves.