Re: One-Click Wossname 1.2 -- automatic level 12 quest completion
Good news everyone:
version 1.2! It so happens that I have two characters who arrived at the level 12 quest at the same time, one hardcore and one casual. So I've been running this script with both of them, doing some testing and bugfixing. I also recently discovered that you can declare functions within functions (subroutines) so I've rearranged things a bit to make it more memory-efficient.
I also rewrote the postwar item-trade-in function and added an option to automatically buy and autosell the 1000-meat-autosell item, effectively converting your war items to meat. The new option is at the top of the script. I haven't tested it yet, so let me know any errors you find.
Changes:
[*] Fixed the problem with the filthworm sidequest and the lighthouse stopping on required items. I'd been mistakenly using
retrieve_item() on all items (even quest items), not knowing that if it couldn't get it it would break execution. So that shouldn't happen any more. Updated version worked for me with both characters.
[*] Added a
change_to_meat option. If true (default), the script will use all your dimes and quarters after the war to get meat. It does this by maxbuying the item at each camp with an autosell value of 1000 meat, then selling them. It buys a few bombs if you have any leftover coins.
[*] Better postwar error checking, and improved flexibility for non-Wossname-getting warplans.
[*] Fixed some bugs with the fratboy side of the item tradein function.
[*] Functions that were merely subroutines of another function have been moved inside that function. This also reduced the number of global variables.
Sorry, but I didn't touch the junkyard yet, since neither of my characters are there yet. I'll get to that soon.
Properties Accessed by OCW
@kiltchdie and others -- the properties you should be concerned with are these, shown here with their initial values.
Code:
hippiesDefeated=0
fratboysDefeated=0
sidequestArenaCompleted=none
sidequestFarmCompleted=none
sidequestJunkyardCompleted=none
sidequestLighthouseCompleted=none
sidequestNunsCompleted=none
sidequestOrchardCompleted=none
If you have completed a sidequest, it should say "hippy" or "fratboy", the side you completed it on. The two
xxxxxDefeated properties hold the number of each side you have slain (
not the number of adventures spent!). Reference my above post of the optimal plan if you want to try repairing an incorrect settings file.
Some warnings:
[*] If you delete your settings file or run this script on a computer that does not have your most recent settings file, you're screwed unless you know what step you were on. Even so, if you were in the middle of a battlefield step and don't know what number you were on, you're probably still screwed.
[*] As macman104 and Veracity noted above, using the script with multiple characters is fine, but multiple computers is not, unless you first import your character's settings file.
[*] When I ascended (manually, because it wouldn't work within mafia), mafia did NOT reset those values. I reset them manually. So be careful before beginning the quest that these properties are reset to the initial values! I'll try to write some kind of "property reset" into the next version.