[Bannerlord modding] Can I do a string comparison in a conversation?

Users who are viewing this thread

Adryl

Regular
Hi, thanks in advance for any help! I'm working on my first mod for Bannerlord and I've run into an issue. In my module, I am trying to set up some conversation replies such that I can have different replies for the same type of conversation depending on the NPC. Unfortunately, it seems the only variables I can use to do comparisons are numbers (level, age). So I can't actually check who the CONVERSATION_NPC is (by name or id, which is a string as I understand it). I want to do something like this in conversation replies:

"Hello! My name is {CONVERSATION_NPC.NAME}. {?CONVERSATION_NPC.NAME==Mitela}How dare you approach me!{?}Good day, sir.{\?}"

But, it seems the comparison operators (==, > etc.) only work on numbers. So I can't do the above. The below statement does work:

"Hello! My name is {CONVERSATION_NPC.NAME}. {?CONVERSATION_NPC.AGE==44}How dare you approach me!{?}Good day, sir.{\?}"

Does anyone know if there's a way to do a string comparison here so I can check NPC name? Or, am I wrong and there's a way to check a numerical ID? Also I would love to be able to do a relation comparison.
 
Back
Top Bottom