I’ve been diving into the files and trying to mod my game, and I’ve come across a few functions that I would like a better understanding of what they do. Is there a list of functions used in fetish master and how they work?
Some are pretty self-explanatory, such as addStat, doAction, etc., but others I’m not quite as sure. For example, what the calculations are for LustShame or updateEffect, or the differences between GetFlag and PerGetFlag. I’m sure there are plenty more that I can’t remember or just have encountered yet.
If there is information out there that would give me a better understanding of the tools available in the code, I would be very appreciative.
H.Coder has released some documentation and a partial source code on his website. So you can take a look at that. But mostly I’ve taught myself about specific syntaxes the game uses.
Lustshame essentially gives a proxy a mood hit if their lewdness is below the number you specify.
UpdateEffect does as it says, it updates the properties of an effect. I literally have never used it, so i can’t give many details.
As for GetFlag, and GetPerFlag. they both use the same syntax, but Flags are global, and PerFlags are linked to specific characters(per = personal)
Other than that feel free to ask anymore questions!
There used to be a handful of basic engine guides on the FM blog, but the links to download them seem to be dead. I’m not sure whether they’d really have answered all your questions in the first place.
Most of what I’ve learned, I’ve learned either through looking at other mods or through the game’s source code itself. The source code for 0.99 is available on GitGud. Most of what gets called in user-scripted stuff can be found in ScriptVarsIntegrator.java (in /src/fetishmaster/engine/scripts/), but you’ll also have to dig into the actual methods for Creature and even RNAGene to get a full picture.
In response to your specific questions, GetFlag refers to a global flag, while PerGetFlag/GetPerFlag refers to a personal flag tied to a specific character. Calling a character’s GetFlag (proxy.GetFlag(“flag”), for example) also refers to a personal flag rather than a global one.
updateEffect generally takes two strings and an int - the stat name, the name of the effect, and the value of the effect (a modifier to the named stat). If the stat already has an effect with the same name, the value of that effect is updated with whatever it was just given; otherwise, a new effect is applied with that value. You can also add a fourth value, time, to adjust how long that effect lasts, and in conjunction with it a fifth value, a string to be printed when the effect expires.
LustShame requires a bit more code-hopping to see the full logic of it, as it calls a couple other methods and references stats that really never get used. Essentially, it takes a creature, a lust value, and a shame value as input. Shame is adjusted to generally equal lewdness - shame (or zero if lewdness > shame), arousal is adjusted by, essentially, (lust - adjusted shame) times (libido/10), and mood is adjusted as usual based on original shame amount. There are other factors here that modify all that, but I don’t actually know that they’re used in the base game.
Thanks. I will definitely be taking a look at the source code. It might help me get some ideas too.
Thanks. Is there any way to raise one number to the power of another? I’ve tried both pow(x,y) and math.pow(x,y). Much appreciated.
You’ll want Math.pow - the upper-case M is important.
Thanks, it’s working now.
How is a proxy’s health calculated?
I have a REALLY large proxy (BMI = 63000), and as soon as she eats an item from her inventory, her health drops into the negative tens of thousands.
If possible, I would like to make her robust enough that she won’t get stuck in the hospital. ;
Is there any documentation for how to use the different editors? (gene editor, organ editor, etc.), or some document that breaks down how organs, DNA, RNA, and other complex concepts of this game work for beginners?
I LOVE this game and have put a lot of time into it. Therefore, I would really like to learn how to make my own custom organs, genes, and events so that I can customize this game in any way my heart desires. I think anyone who loves this game would value that sort of thing.
These links should still work, as far as whatever documentation actually got released. Beyond that, your best bet is to dig through other files and mods to try and understand what each one is doing and how it works.