Author Topic: weird GetCreatureTalentBest behavior  (Read 345 times)

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
weird GetCreatureTalentBest behavior
« on: December 23, 2012, 11:08:52 pm »


               Few months ago, I described a bug in this and (talentRandom) function that searching for talents of the category TALENT_CATEGORY_HARMFUL_AREAEFFECT_DISCRIMINANT returns actually talents of the category TALENT_CATEGORY_HARMFUL_AREAEFFECT_INDISCRIMINANT. And thus I swapped those two constants in nwscript.nss and recompiled AI for that matter (and then added into my patch project).

But recent testing revealed that this behavior doesn't always happen. I made some test and with help of henesua I come to the closure that this bug happens only in singleplayer - as its correct in multiplayer. But still on my other computer this is correct even in singleplayer and there is more discrepancies.

LINK: Test module for this bug. Simple, clean module to test this issue. In game type "test" into chat and you should see two lines indicating best discriminant and best indiscriminant talent of the beholder - eyeball creature nearby. Also this creature should normally activate stunning aura, then try strength drain pulse and then beholder dispell.

Got two computers. Both trying with clean 1.69 install (or rather rebuild, I was too lazy to reinstal, so I simply reinstalled english 169 patch), no override, patch haks, community patch, nwnx, nothing, really clean install.

Still the behavior is different on my two computers.

how it should be:
best discriminant should be strength drain pulse, best indiscriminant should be beholder dispell, creature should first activate stunning aura, then drain strength and then dispell the PC

Computer 1:
behavior there is correct as it should be

Computer 2:
best discriminant returns beholder dispell which is wrong, indiscriminant returns drain pulse

both computers has Win XP OS, 32bit

Could someone try this module (its a matter of 5minutes) with clean install and post results? What I know is that if I run this module via nwserver on my second computer the behavior/order is correct/reversed but thats all. It disturbs me that NWN behaves differently on two instances.
               
               

               
            

Legacy_Failed.Bard

  • Hero Member
  • *****
  • Posts: 1409
  • Karma: +0/-0
weird GetCreatureTalentBest behavior
« Reply #1 on: December 24, 2012, 12:34:24 am »


               Were you testing it with the exact same character on both computers?  It's my understand "best" is determined based on target CR, not the actual best ability.
               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
weird GetCreatureTalentBest behavior
« Reply #2 on: December 24, 2012, 03:46:58 am »


               

Failed.Bard wrote...

Were you testing it with the exact same character on both computers?  It's my understand "best" is determined based on target CR, not the actual best ability.

not exactly because the parameter for this function is not target object but CR which I set to be 21, but i did tried several characters on both computers lvl 1 or 40, doesnt matter.