Jump to content

Updating scripts. A Weidu question


temnix

Recommended Posts

I've gotten to changing scripts for both unmodded and modded games so that NPC start using my sight cone-type detection spells when party members are near on them rather than themselves. This is a simple change, but I want to make sure I get all of the situations and don't end up with wrong syntax. Generally what I'm doing is replacing lines like

Spell(Myself,WIZARD_ORACLE)

with

ForceSpell(LastSeenBy,WIZARD_TRUE_SIGHT)

True Sight replaces Oracle, because that spell will now do something else. I want to make sure I don't accidentally rewrite scripts with ForceSpell in them with my own ForceSpell, which could result in errors. I'd like to get the exact match, with just these characters, for Weidu to work on. What code do I need? Not simply EXACT_MATCH, because that gets anything containing my expression.

The second problem I thought of right now. I suppose that NPC who detect PC with their spells expend them, that's what the Spell action does. There is then only a limited number of times they can pull off these detections. I hope it isn't any more complicated than that, because if they actually have ForceSpell there (talking about Sword Coast Stratagems now mostly, whose author is too cryptic in his self-importance to answer a question) and something like timers, then a simple replacement like the one above may not work. On the other hand, if they have Spell conditioned by HaveSpell(WIZARD_ORACLE), then casting True Seeing instead isn't going to wipe Oracle from their memory, and they are going to do it again and again.

I don't know how much of a problem this will really be, but short of tearing Oracle from their spellbooks when they cast True Seeing, how can I make sure they cast one instead of the other? Perhaps what I need is to patch spellcasters so they all have True Seeing memorized instead of Oracle, but I have no idea how to do that. There is a good news, though: the G3 guide is wrong that NPC need to meet level requirements for the ForceSpell action. They don't, at least in the Enhanced Edition. They will be able cast True Seeing no matter what their level is. Still, I would appreciate any advice on tuning Weidu so that it patches all such possible casting actions in the broadest and most correct way.

Link to comment

No relation to this topic. A garbage post just to upload an image I could insert in a private message to somebody here. Why? Because the PM system doesn't let people upload images from their computers, only use images already uploaded for topics. Hooray for the intelligence of this!

Screen.jpg

Edited by temnix
Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...