Disabling Npc Interaction - Apparently it was meant to be in the game.

Users who are viewing this thread

Apparently I struggle with being smarter than the game files. Exactly where do I find the start_at_training_ground line to change the script?
 
Awesome, thanks a lot TML! 'Tween this and a few of the other code tweaks posted in the sticky thread, my game's running a lot smoother. :grin:
 
hey it does work! awesome! thank you! i had just accidentally forgot to take something out, but I found it so now it's not crashing anymore.
 
Alright, I managed to get the change in last night, but it doesn't seem to be working. I hit the training grounds and sparred a couple rounds on three separate occasions with the character I wanted to turn off NPC interaction with, then tracked down and recruited one of the problem NPCs and promptly got *****ed at by him and the people he doesn't like.

I've long since completed the initial training with this character, though until last night I don't think I'd ever bothered hitting another TG. Could that have something to do with it?
 
hey i have had a few problems implementing this line of script.
when i used the search tool in the text editor i searched the line 2133 2 144115188075856295 0. that came up with nothing, (i thought that was strange) so i searched the line 2133 2 144115188075856295. that gave me one result so i assumed that this was the line of code that i had to edit. when i added the 1 to the end of it (making it 2133 2 144115188075856295 1) i then tested the game, it froze on the loading screen. i then removed the 1 that i added, the game worked again, then i closely followed instructions to add the code to another place in the script. i used the training ground (start_training_at_training_ground -1) making sure i added 1 to the first number of that section of script as i had worked for others. i started a new game, and went to the training field but they were still bickering. can someone please tell me what i have done wrong?
 
Y'all are probably just editing the numbers wrong.

magyur,
The 2133 2 144115188075856295 0 line SHOULD be there, unless you're using a modified scripts.txt. Are you playing a mod? As far as adding a 1, you can't add numbers like that. It has to be changing a number. Heres what that line does:
2133 = Assign (this is a function)
2 = the number of things used in the function (basically the # of #s to follow it)
144115188075856295 = the global variable for disabling NPC complaints
0 = the value that you're assigning it to

Since the 2 is there, there must be a number (any number) following the 144115188075856295. Whatever number that is, that's what 144115188075856295 is being set to. In the native game it's a 0, and changing it to a 1 disables most of the companion interaction stuff. For instance, the part where they complain after battle has a check to see if that number equals 0. If it doesn't equal 0, it doesn't continue the script. Any number but 0 would probably work for that kinda stuff. I think theres a few places that check specifically for a 1, but I haven't really looked into it if it would be better to have a 1 or higher than a 1.
 
mine works... they dont say a word about each other... but they still leave my party... tnx to my persusion skill to persuade them to stay more....
 
na i haven't installed any mods at all, and i installed it again but the same thing:

game_event_party_encounter -1
82 21 1 144115188075856114 22 1 144115188075856290 2204 2 144115188075856291 144115188075856114 2190 3 144115188075856292 144115188075856291 432345564227567628 521 3 144115188075856293 144115188075856114 0 1609 2 144115188075856294 144115188075856114 1 2 936748722493063235 648518346341351424 2133 2 144115188075856295 72057594037927936....

144115188075856295 is followed directly by 72057594037927936. i am running v.960 on a fresh install, no mods, and i have not tampered with the script before at all.
 
EiO said:
mine works... they dont say a word about each other... but they still leave my party... tnx to my persusion skill to persuade them to stay more....


Huh? Are they still leaving or not?

I implemented the script change in a game already in progress via the "training field" and so far so good. Borsch did leave but it was right after the modification and he was trying to leave before I changed it. But Dashevi stayed although she was leaving before the change. She is why I had to have this script because I had too much invested in her to just let her walk away.

This one's a life saver if they all stay.

Thanks a Million!!!!
 
I haven't tested long-term if it works to keep them all or not, all I did was turn it on and run get everybody and then fight a bunch of battles and wait a few days. Nobody complained or became unhappy, so I figured it worked. I don't play with that many heroes normally, though.

It does keep them from getting unhappy over who is there, but I think the scripts might add the other kind of unhappiness factors in without telling you. I seem to recall seeing something that added morality checks in even if it was set, it just didn't say anything about it. So if you, for instance, raid a bunch of villages while you have someone who doesn't like that, they may get mad and leave. But just having them in the party with someone they don't like shouldn't make them go.
 
Is there any way to stop them from leaving at any reason ? i want to collect all of them but they keep leaving and spread around the world fast, i can find them and get them back but still it's boring to check every tavern one by one, maybe they could spawn only in one of the towns so i can pick them up at the same time :wink: ?
 
Yeah, when I first added this to the game, I had a few leave me for apparently no reason (I wasn't raiding, failing quests, etc). What's even more strange is that after you pick them back up again, you no longer have any problems with them leaving.
 
There are three different checks for hero happiness. You see these by talking to a companion and asking them how they feel about...

Choice of companions - should be fixed by this tweak.

Party leadership - I'm guessing has to do with battles being won or lost and numbers of casualties, because a couple times heroes have *****ed about 'bloodbath' losses after repeated city siege attempts to wear them down.

'General state of affairs.' - I have no idea what this actually means but it's probably linked to morality... whether they like/dislike raiding villages, helper quests, killing/joining certain factions, personal agendas etc. I've also had heroes leave because I sidelined them too long (take their weapons and leave them on mounts and they'll just sit at spawn) to soak party xp, so their personal kills probably factors in here too. Dunno.

You can't see the actual number values in game, instead it's text from 'downright appalled' to 'very pleased' or something like that so you have to guess. I'm also not sure if just one going too far negative will make them leave or if it's an average.

If an average is the case, then disabling party interaction might end up making them more unhappy overall if they can't annoy you with how much they like someone else - that value won't go up and offset the others if you decide to go village/caravan raiding or rogue faction.

So to effectively prevent heroes from ever leaving you'd have to disable/tweak all three values. I'm not cool enough to track down the code myself, but I thought I'd chip in some info. If MageLord is bored/motivated enough I'm sure he could figure it out.

Btw thanks for all the work on all these text tweaks. I was getting bored and frustrated with the game until I resorted to hitting the forums. I'm not a python coder so I would have had no hope of translating all those crazy numbers into something recognizable. (:
 
it seems that i have found a way to hold all 16 npc heros together in your party.
i've found that my npc heros start to get along after some level ups into their power strike skill.
it seems that heros with shared skills will not complain about each other any more and will eventually tell you each other are good soldier(in my case that i trained them power strike), so i guess all it take is a few investment in a common interest.
 
TheMageLord said:
By request of Wraithcat, I looked into a way to disable companion interaction. It turned out to be much simpler than I thought it would be - there is a built in toggle to disable it, but the option to disable it wasn't added in. It's actually there in the .960 module system, but commented out - and doesn't exist in the 1.003 text files. The value is initially assigned as 0 in game_start, though, which is what I'll be editing here (so it would require a new game, unlike the other tweaks).

I won't copy the whole script on this one, since it's ridiculously large, but heres the line of code you need to search for:
2133 2 144115188075856295 0
144115188075856295 is the actual thing being assigned here, and 0 is what it is being assigned to. Normally this is to get the variable ready to be set elsewhere, but we can just set it here and save the hassle. Change the 0 to a 1, and presto - the next time you start a game, companions will no longer interact (no complaints or compliments).

You COULD work it into a game in progress if you really wanted to, but you would have to add the line of code somewhere. I won't cover that here, but basically you'd just pick a script that will be triggered and add in the 2133 2 144115188075856295 1 thing to the end or beginning of it. Then you add 1 to first number in the script (which is the # of lines in that script, it needs to add 1 because you're actually adding in an extra line of code). You could remove it after you know that the script has been triggered - it stays once set.

This is the first of my tweaks that I won't actually be using, since I usually only keep 2 or 3 companions anyway, but it's good for those who want companion armies. Enjoy.

-edit- For those new to M&B modding, this is all in scripts.txt, which is in Mount&Blade\Modules\Native.

Link to other tweaks.

-edit- If you want to put this into games in progress, you can do like lord Kinlar said and add the line to start_training_at_training_ground. See this for a good (I hope, anyway...) explanation of doing that.

I don't think this one works anymore. I tried searching for 2133 2 144115188075856295 0, but this wasn't even found in scripts.txt.
 
Oh dear. 1.

:lol:

Edit: I'll see if it works.. so far I've made the changes, started training to activate the trigger and it *seems* to be working. The enthusiasm level of everyone is at 99 despite a snarl of someone "Matheld needs to have her tongue cut out" or something. Maybe that was the last one... hopefully it worked.
 
Back
Top Bottom