I think most of you probably were aware that something odd was happening with the ai_chance calculations in 1.02. Not only did we track down and fix the problem, but you'll also notice that we have now added the option for events to apply modifiers to ai_chance calculations. Essentially, this now puts some power into the modder's hands in scripting ai behaviour - at least as far as making intelligenet event choices goes. I would recommend giving some strong consideration to adding these to pretty much any multiple choice event that you write (we got this new ability very late in beta and didn't have enough time to rescript all the existing events....a project for 1.04 most likely) to improve the AI's "thought" process.
They are pretty easy to use. Just assign an ai_chance value to an effect and then follow it up with modifiers in exactly the same way you would if you were writing modifiers for mtth...
EXCEPT do not forget to think backwards to the way you usually do since an mtth modifer of 0.5 makes something twice as likely to happen whereas an ai_chance modifier of 0.5 makes it half as likely that the AI will choose this option (NOT twice as likely).
One last note: you don't have to worry about some sort of balancing act to make the ai chances add up to 100%. The code will automatically adjust itelf to compensate and zero-sum it.
Enjoy!
They are pretty easy to use. Just assign an ai_chance value to an effect and then follow it up with modifiers in exactly the same way you would if you were writing modifiers for mtth...
EXCEPT do not forget to think backwards to the way you usually do since an mtth modifer of 0.5 makes something twice as likely to happen whereas an ai_chance modifier of 0.5 makes it half as likely that the AI will choose this option (NOT twice as likely).
One last note: you don't have to worry about some sort of balancing act to make the ai chances add up to 100%. The code will automatically adjust itelf to compensate and zero-sum it.
Enjoy!