Page 1 of 1

Wizmode Help Please: !Mut Monte Carlo

PostPosted: Friday, 1st September 2017, 15:02
by MainiacJoe
I would like to run a Monte Carlo simulation on wizmode of mutation roulette. How often does a mundane character, after quaffing one !Mut in 0.20, end up better off than before quaffing? My goal is to create a very long character dump file via repeated macros, and then parse the text file with Python to harvest the data.

Here is the progress I've made:
  1. I can't find a wizmode command, "Cure all mutations"
  2. Fortunately, wizmode will happily create obsolete !CureMut.
  3. Alas !CureMut does not remove a reliable number of mutations, particularly if Mutation Resistance is present
  4. Is there a command (not necessarily wizmode) that will dump the results from 'A" into the character file? The parser could use this to confirm before a given iteration that all mutations have been successfully removed, or throw out that iteration.
  5. How does one use the "0" repeat command with macros? Keymapping works for single keypresses, but when I try to repeat them the repeater function defaults to the standard command for that key, e.g. 'p' saying 'unknown command' or 'e' attempting 'eat' even after successful keymapping.

Re: Wizmode Help Please: !Mut Monte Carlo

PostPosted: Friday, 1st September 2017, 16:48
by advil
You're going to get much better results trying to do this in lua, the full mutation API is all there (it's used by the mutation tests) as well as some output code. As a starting point, look at test_potion and simulate_mutation_pot in test/mutation.lua. Caveat, I haven't updated the simulation code to the latest version of the mutation potion, but the numbers are easy to tweak.

Re: Wizmode Help Please: !Mut Monte Carlo

PostPosted: Saturday, 2nd September 2017, 05:02
by Airwolf
I think you could easily manually read the numbers and types of mutations from quaff.cc and then parse the types and weights from mutation-data.h to just calculate what you want outside the game engine.

(The filenames are from memory, so apologies if they're not completely accurate.)