First of all, I'll give a brief description of my mod: I've noticed that some plantations and compounds have no key. I find this irritating and I dislike having to use the console to force slaves to follow me to have a place to where I do have a key for. Now, I'm a master thief, dashing vagabond of catlike reflexes and all that, and I can pick just about any lock. So why can I not pick those bracers? Sure, they may have complex locks, but it just completely threw my immersion that I couldn't even try to pick them. And it frustrated me that I couldn't when there was no key.
So that's what this mod does, it tries to be completely compatible by only adding a new topic to slaves, it uses variables outside of the game and doesn't touch upon anything else. The only thing I touched upon that might have incompatibilities is one topic, because it was annoying me. That one topic states that the slave wishes they could go back to Argonia, this happens for Khajiit, too, which is baffling. Not only that but Argonians dislike being called Argonians, so why would they call it Argonia? Instead, I changed Argonia to 'my homeland,' which works for both Khajiit and Argonians alike, without being lore breaking.
Okay, so here's how the system works...
You have a dialogue where you can try to pick the lock, based on your skill and the quality of the lockpick you have equipped, you may either free the slave or fumble and drop your lockpick. (I originally had lockpick breakages, but limitations in the game seemed to create interesting results if I did a player->removeitem pick_blah 1 whilst I had a pick equipped. It would create a pick with over a hundred thousand uses, sometimes negative and minus a hundred thousand uses. This baffled me, as I could reproduce the effect via the console without my mod activated. So I just settled on a high failure rate and dropping the pick instead of it being destroyed, which should be annoying enough for a proper balance.)
If you succeed, there are a number of different responses for success. This is something I wanted to do to not make it seem too artificial. All of this works beautifully! The slave is also freed upon succeeding and 'go free' tells you that they're free, they drop their bracers, their disposition is modded by +50 as it should be. All is well, except...
I'm using slaveStatus to check which dialogue should run. If slaveStatus != 3 then I run the topic where the player is asked to pick the lock. (They get the option to say that the lock is beyond them if they don't have enough skill in security. I tried to cover every eventuality.) If slaveStatus == 3 I have it set to run a 'go free' style message, which uses exactly the same check, and in this one they express how happy they are to be free. The only problem is is that despite using the exact same system the game uses, the topic loops...
I have honestly tried everything that I could think of. I've done so much testing and every other aspect of the mod works fine. I hate asking for help because it means I have to bother people to help solve my own problems, but I've spent hours of the past two days working on this and banging my head against a wall. The reason I'm asking for help now is because I'm worried that it's a MWEdit bug and that the mod simply needs to be saved in the Construction Set for it to work properly. Here's the catch though: I'm using the Steam version, and the Steam version is sans construction set, so I have no CS.
I have tried resaving it in the Enchanted Editor, but that doesn't fix it. So... right now, I'm at a loss. It should be using the slaveStatus variable to show the correct dialogue but it's not. It's not a big deal but I would like this to be complete, bug free, and professional at least before I release it. I could keep this just for myself, but I want to share it! Being a fan of slave mods like Twin Lamps I've always wanted this, so I made it for myself, and I figure others might want it, too. So I've been working hard on making it cohesive and bug free. But I've reached the limit of my own capability...
If you want to help me out by taking a look, here's the file: http://www.mediafire.com/?bpppgt4glk3co48
This mod is complete aside from the looping topic, so if that doesn't bother you then feel free to use it! If anyone can help me fix this, I'll release it proper on PES and credit whomever manages to help me solve this. But... I really am at wits end. I don't like pestering people. I just see no way to make this work. (I even tried adding my own slaveLockpick short to the slaveScript and not even that works. So I'm convinced of two things right now. Either A.) there's a bug in MWEdit, or B.) I'm really, really stupid and missing something obvious that's just going over my head.)