Aller au contenu

Photo

Retrieving the current AB of a creature


  • Veuillez vous connecter pour répondre
6 réponses à ce sujet

#1
Kato -

Kato -
  • Members
  • 392 messages
Hi,

Does anyone know of a function doing this? GetBaseAttackBonus returns the BAB, but what about the AB(shown on the character sheet)? Sorry if it's been asked before, I've searched in the lexicon, the Omnibus and these forums, but no luck yet. Maybe a nwnx plugin...

Thanks in advance


Kato

Modifié par Kato_Yang, 23 janvier 2012 - 06:54 .


#2
Shadooow

Shadooow
  • Members
  • 4 471 messages
Im calculating this on paper, BAB+mod str/dex/wis+weapon+feats ;)

#3
WhiZard

WhiZard
  • Members
  • 1 204 messages
The AB depends largely on the weapon that you are looking at. For example, the character sheet does not consider creature weapon slots and thus ignores AB bonuses that creatures have on their creature weapon. There are many other bugs with the character sheet report (including the epic prowess bug) where DebugMode will show different results than the character sheet.

EnableCombatDebugging reports the real attack rolls. If you want to parallel this you may find yourself going through a whole mess of feats including bane of enemies and nature sense, as well as checking to see which slots override other slots.

#4
Kato -

Kato -
  • Members
  • 392 messages
Okay, thank you both. I guess I'll have to retrieve this manually in code, even though it indeed makes a lot of potential feats to check. I'm surprised that not even a nwnx plugin does this. I'm using nwnx_cool to override some special attacks(knockdown, smite etc...), thus the AB of the attacker must be retrieved quite often in order to apply the corresponding bonuses/penalties to it. The plugin hooks GetAttackModifierVersus(), GetRangedAttackBonus() and GetMeleeAttackBonus() but these functions are not exposed to nwscript... Would there be a way to at least simulate such a special attack at full/modified AB?


Kato

Modifié par Kato_Yang, 23 janvier 2012 - 06:55 .


#5
ShadowM

ShadowM
  • Members
  • 768 messages
Funky had a custom function that found it, I use it in my HR base and added in size mod. to it. I will look for it. Do a search for it. Maybe Funky will post it again.

#6
Kato -

Kato -
  • Members
  • 392 messages
Indeed, I have found it searching by author, in the Omnibus, topics "Emulated Attack Roll" and "How to get real AB?", for anyone interested. Thank you very much for the info ShadowM!

@Funky: Very nice system, thanks a lot for sharing it!!

Modifié par Kato_Yang, 23 janvier 2012 - 11:44 .


#7
Kato -

Kato -
  • Members
  • 392 messages
Very good news: Tera_777 has updated nwnx_cool(0.8), so we can now retrieve the AB vs(same with AC vs) with a single, fast function! A thousand thanks Tera_777!


Kato 

Modifié par Kato_Yang, 26 janvier 2012 - 07:52 .