On that subject, to you foresee it being possible to significantly expand the various UI elements to accommodate a more modern feel to the many UI windows? Take the crafting UI for example - I could easily see that being twice it's current dimensions, and that would eliminate some issues with text fit.
I'd like to circle back to the original topic of this thread, if I may be so bold. I've added the ability to brew the Potion of Hiding and Potion of Sneaking, as they are based on 2nd level spells, even though the Elixirs are wondrous items. These are the original prereqs for crafting the elixirs as wondrous items: {8034}{"FCraft Wondrous Item" "SInvisibility" } // elixir of hiding {8035}{"FCraft Wondrous Item" "SSilence" } // elixir of sneaking So, this is how I chose to add them as potions: {8024}{"SInvisibility" C3} // potion of hiding {8026}{"SSilence" } // potion of sneaking In protos.tab I also made these changes: - Potion colors were changed to 481 (grey), to reflect the Illusion school color. - Price was changed to 30000, as per 2nd level spell potions Also, I think taking the word "Potion of" out of the name of every potion in item_creation_name.mes makes for a less cluttered list, and it should be OK since it's clear they are brewing potions, and the word "Potions" is written at the top of the list. Finally, I'm not sure how to ask this exactly, but how are new mods folded into a new release? I don't mean how they get chosen, but how are they added to the "master files" for lack of a better term. I know things are kind of slow, but if multiple people want to add new items to the game, and each one is updating protos.tab and many other files at the same time, it must be a painstaking process to pull out all the changes individually from a dozen different mods to update the main files. Many of the mods I am making for my own project, which will take a while to release, could easilly be put into the 8.2.0 or w/e the next version is, but I am concerned about the complexity of conflicting with other mods.
While I don't plan to add any non-PnP potions myself, I would recommend you make the caster level requirement of the two C5, because that is the requirement for the corresponding elixirs. Your call, obviously. Yeah, I did exactly that; it will be in the next iteration of my mod. As far as complexity, I'm in the process of creating a google doc that outlines exactly what I changed for each thing; I figure that will make it at least somewhat easier to pick and choose. Sitra: For exactly the reason you state, I've decided not to make multiple levels of potions beyond the ones for my custom spells (which I've already made); such would be made redundant by a custom crafting system.
C5 seems reasonable as they are not directly using the spell, but performing some "twist" on it, which is why I guess they should be in Wondrous Items only maybe. I'll keep it. Your documentation is top notch, and it probably takes as long to do as the mods themselves, but I'm thinking of the poor slob (who is probably Gaer) who has to got thru and pick things out and paste them in individually when 4 people all put their new items into proto slot 8225, or altered a specific spell file in a different way.
Yeah; I don't see any obvious solution. Though, if you're reading this, Gaear, I'm happy to move any of the custom items or spells I make to different slots on request, if there is such a conflict.
Everything gets compared into the master build. It' can be a bit painstaking if there are a number of contributions, but generally it's not much of an issue ultimately except for ptotos.tab. We've bandied about various solutions for that over the years, but none of them really work. Are you familiar with Agetian's proto import/export tool? It's a really handy way to make a custom protos.tab that only contains your modifications for much easier integration. Unfortunately it's not a perfect solution either, because it doesn't address the possibility that multiple people could be modding the same protos, but at least it alleviates the issues with everyone submitting their own full giant protos.tab. edit - link here The utility should live in your WorldBuilder directory alongside protos.tab.
Gaear, Thanks for that info! Chiming in late on this particular topic... I find it both confusing and suspicious that there is not an existing call like obj.condition_has ('sp-Invisibility') which of course does not exisit. But I did find something close, which does exist: obj.d20_query_has_spell_condition ( sp_Invisibility) Note that the input arguments are actually different. The 'sp-Invisibility' is a string, and the sp_Invisibility == 137 whose declaration I can't find anywhere. But there's a variable for almost every spell with a condition. Unfortunately the call to this function only works in about 25% of the cases. Of the spells I checked, it works for these: Mirror Image Invisibility Meld Into Stone Enlarge Reduce Gaseous Form Dimensional Anchor Otiluke's Resiliant Sphere But doesn't work for many like Protection From/Resist/Endure Elements, Bull's Strength and its 5 brethren, Barkskin, Mage Armor, and many more. Sitra, Regarding the Co8 persistent data solution, that seems like a great idea. Correct me if I'm wrong, but unless someone goes into the code of every spell in the game and mods that in, you can't rely on it to give you an active list of every condition. It would be a very satisfying project to finish, but no one has stepped up yet and I can imagine why. Noob question of the day: Why do some spells have spell.spell_end( spell.id ) at the end of OnSpellEffect( spell ), while some don't, even though they are all spells that have a duration. For example: Mage Armor and Invisibility make this call, but Shield and Mirror Image do not.
Spells that create a spell effect on a target do not need to manually end the spell. This is because the spell effect keeps track of the spell and ends the spell when the effect expires (this is why the add condition line needs to be passed the spell.id, as opposed to just the spell.duration) Things like fireball, which do not create a condition, have to end the spell manually. Note that spells cannot be ended manually when they still have active targets, which is why those spells also have commands to clear the target lists. It is odd that mage armor and invisibility have a manual end line, since they also apply spell conditions, but I'm fairly certain (not at my home computer to test this) that you could remove those lines without ill effect. But, you could not remove the line from fireball without causing the spell to last forever in the ether. In may in fact be bad to manually end the mage armor spell, instead of letting it end with the condition, because (and I'd have to test this), it may make it impossible to use Dispel Magic on the mage armor, since the spell ends instantaneously, while the effect continues.
That really clarifies things, super answer. The reason I asked that was I've been experimenting with calls to condition_add_with_args () outside of spell files, and was worried about what the spell ID would be, and how to shut it down. But, it seems to work fine just setting the spell ID argument to 0, like: obj.condition_add_with_args( 'sp-Bulls Strength', 0, 100, 4) No problems so far, and the condition wears off without any CTD's or other ill effects. Plain old obj.condition_add ('sp-Invisibility') works great too, if the effect has not args, but the duration is permanent.
@marc the d20 queries depend on the spell condition being defined with a Query callback. Unfortunately not all spells have this, and those that do may have flaws in implementation. For instance the prot from elements spell has a callback for Q_Critter_Has_Protection_From_Elements, which can even be used to test the element type, but the implementation is buggy in case you have more than 1 such effect. Another possibility is to run a script off of a critter's san_spell_cast. Lastly we can do it in TemplePlus since internally there is already such a list. Well, sort of anyway - this ties in to your question about spell_end. What it does is unset an 'iis active' flag in that list, which I think is only meaningful for spells that execute something every round. If you want to learn a bit more, take a look at the documentation in the TemplePlus wiki about the Dispatcher system. I'd be careful about using null spell.id though. I think it could cause trouble if you apply more than one effect this way, as the spell Id defines which condition callbacks belong to which spell, and it's definitely sthg the game checks. I think the biggest issue might be that one spell ending would remove another with the same Id. Or if two spells have a 'remove when duration expires' callback, not sure what would happen, depends on the implementation.
That makes me a bit worried about the elixirs (from vanilla), which use: "target.obj.condition_add_with_args( 'Elixer Timed Skill Bonus', 0, 0, 0 )" "target.obj.condition_add_with_args( 'Elixer Timed Skill Bonus', 1, 0, 0 )" and "target.obj.condition_add_with_args( 'Elixer Timed Skill Bonus', 2, 0, 0 )" It seems that another spell could have id 2, for example.
Alright, it seems that if another spell has spell.id that matches these numbers, it will end the Elixer condition upon application. This spell effect looks like it was made in a mad rush to complete a milestone goalset...
Or if the elixir is applied it will end a spell with the same id, presumably? This sounds like something that is annoying, but shouldn't break the game, and shouldn't happen often. Do you have any idea what range of spell ids tend to float around? If not, no big deal. Hope you had a nice vacation!