In order to have multiple programs/instances access the same specific file at the same time requires you to implement a database model of data access rather than a simple text
Although it might be possible to use different files for different accounts and only have OCD load the files specifically matching the account name in question. That way so long as your multiple mafia instances are for different accounts it should work.
Last edited by taltamir; 01-03-2018 at 06:24 PM.
Ummm... Your last comments describe how OCD does work. Specifically, for the files that it writes, the file names are different for each character.
If a script reads and writes to the same file for all characters then yes, it is possible that the script would end up with files that mix and match data.
KoLmafia has had problems in the past where information from one session/character would "bleed" over to another. If that is happening here then it is a legitimate bug and worth trying to investigate to the point of repeat-ability so it can be fixed.
Ok, this is somewhat odd. Changes to "display" only take effect after I restart mafia. while chinese to mall, autosell, or keep take effect as soon as I hit the save button
Perhaps of interest. For all my characters, I open up the relay browser, select the OCD script and it loads. It reports items as uncharacterized which I know are characterized. I immediately reload the script and the uncharacterized report is then correct. I have found that Weird Things Happen if I do not reload the second time, but if I do reload then everything behaves as expected. I have always suspected some kind of timing issue with my browser - perhaps it starts displaying before it has read the data file completely? - but reloading has always been easier than actually trying to track the cause down.
Just now OCD decided to go crazy and sent all my yesterday stuff to "true" user.
Log is full of lines like
What did I do wrong? What is the solution? Will I ever see my items again? (last question is rhetoric, of course).> send to mallmulti true: 1 "KICK ME" sign, 30 Angry Farmer candy, 1 Aye Aye, Tooth Tooth, 184 bag of W&Ws, 13 ball, 7 blue mana, 176 box of Dweebs, 5 breakfast mess, 5 breath mint, 12 buckyball, 2 can of sardines
> Sale price for this line: 0
Hmm, taking into account that "true" was created in 2010 and never visited since then, it's even more rhetoric than I thought. :|
Last edited by Smiling Spectre; 01-09-2018 at 11:51 AM.
Just an fyi, I had issues where the ocd script was getting confused between my main and multi characters, I resolved them by putting the following in my login script:
I never had a chance to look into the root issue since this fixed it.Code:cli_execute("zlib BaleOCD_DataFile = " + my_name()); cli_execute("zlib BaleOCD_StockFile = " + my_name());
I had an issue where some of the items on my "items to stock" list would be closetted (not all oddly enough the different items would do that... and not consistently. A few days ago my sea cowbells were auto closetted, but today they weren't. A few days ago all 230 of my new age hurting crystal were closetted, but today only 30 were, 30 is the amount i told it to stock... i think something weird is going on with how much i have in stock already vs how much i told it to stock).
Auto closetting those items is a problem for combat items that I specifically put there so I can use them; since you can't use them from the closet.
I tracked down the issue to line 460 through 462 which I proceeded to disable via //
I am posting this in case someone else has the same issue. Also, I am curious, what is the logic behind autoclosetting stuff on the "items to stock"? The logic doesn't seem to be designed with combat items in mind, so what scenario is it meant for that it would auto closet the stuff?Code:// Closet everything (except for gear) that is stocked so it won't get accidentally used. if(it.to_slot() == $slot[none] && stock[it].q - ocd[it].q > closet_amount(it) && item_amount(it) > ocd[it].q) put_closet(min(item_amount(it) - ocd[it].q, stock[it].q - ocd[it].q - closet_amount(it)), it);