More cum options: Fade time, cumspurt controls, etc... (1 Viewer)

Wither

Content Creator
Joined
Dec 16, 2011
Hey! This is a (hopefully) simple request. I know a bit about working with flash, but I have zero code knowledge, so this is completely beyond me, but I'd love a mod that allows me more control over how the cum mechanics work.

Alternatively, if it's possible for somebody to tell me how to do any number of these myself, that'd be great, too!

Some important options I'd like:

Fade time adjustments: Currently, the slow way in which cum/spit fades does a number on my performance. It runs smooth for a while, but if too many of the particles are on screen at once, well... Bye Bye fps. I heard tell of a mod that automatically deletes strands when too many show up and stuff but I am yet to see where that is. If somebody could direct me to it, that'd be great!

Spurt amount/duration controls: I know there's already a mod that allows you to add more cumspurts and control how long they are, but this doesn't seem to affect the default cumspurts. I wanted to play around with the idea of a "Watersports" style system, which would require one long, sustained spurt rather than the

Body friction controls: Currently the "friction" settings in the Settings.txt file go absolutely nuts if they go below 1, I'd love a setting that allows me to change how "sticky" the cum is on Her body. So that I can make it either stay where it lands with little/no change, or that it can slide down like water.

If somebody could make this, show me a mod that works to do these changes, or show me how to do them myself, that'd be fantastic! Thank you!
 

stuntcock

Content Creator
Joined
Jun 5, 2012
Feltorn said:
Fade time adjustments: Currently, the slow way in which cum/spit fades does a number on my performance. It runs smooth for a while, but if too many of the particles are on screen at once, well... Bye Bye fps. I heard tell of a mod that automatically deletes strands when too many show up and stuff but I am yet to see where that is. If somebody could direct me to it, that'd be great!
sby's Loader Imports. You're looking for the "strandLimit" mod.

Spurt amount/duration controls: I know there's already a mod that allows you to add more cumspurts and control how long they are, but this doesn't seem to affect the default cumspurts. I wanted to play around with the idea of a "Watersports" style system, which would require one long, sustained spurt rather than the
While you're in sby's thread, ask him to add this feature to his "moreCumSpurts" mod. It already does the "long sustained" thing but it does not allow you to reduce the number of spurts. sby shares his source code, so we could easily create a "fewerCumSpurts" mod which does what you're asking for. But it would be more appropriate to bundle the "more" and "fewer" behaviour into a single mod for the sake of simplicity.

Alternatively: just ask sby for permission to make the changes. The mod code is very straightforward. If you're interested in becoming a modder then I could walk you through the code and explain where changes are needed.

Body friction controls: Currently the "friction" settings in the Settings.txt file go absolutely nuts if they go below 1, I'd love a setting that allows me to change how "sticky" the cum is on Her body. So that I can make it either stay where it lands with little/no change, or that it can slide down like water.
In this context, friction means "air resistance" rather than "surface viscosity." Values below 1.0 imply negative friction, which causes spit particles to accelerate (by geometric progression) during every frame of gameplay:
Code:
this.speed.x = this.speed.x / g.friction;
this.speed.y = this.speed.y / g.friction;

This is obviously bad - you end up with spit strands stretching hundreds of meters "beyond" the visible gameplay scene (so they're mostly invisible, but we must still spend CPU cycles to manage them). In the extreme case, a strand might stretch so far that it crashes the game via overflow.

To achieve an adjustable "body friction" effect, we'd need to do one of the following:
  • tinker with strand-anchoring behaviour (via a proxy on strand::collide)
    • When the strand hits an anchorable object, it will not immediately anchor to it. Instead, it will be subjected to a greater-than-normal friction coefficient.
    • When this friction has reduced its velocity below some critical threshold, it will become anchored.
    • The coefficient and threshold would be user-configurable. You could tune the effects, but the system probably wouldn't be flexible enough to produce a convincing water effect.
    • The code here would be a bit more complex than the "fewer cum spurts" mod discussed above. I could walk you through it, but this would be a second or third modding project rather than an introductory one.
  • full rewrite of strand behaviour
    • physics overhaul would be a sub-goal here; the main objective would be performance optimization
    • The strand behaviour is "good enough" for me, and I'm not a fan of watersports, so you'd need to find someone else to write this mod.
 

Wither

Content Creator
Joined
Dec 16, 2011
Whoa... That? That is some in-depth answers there.

I managed to find the StrandLimit mod, so that's one of the fish in the fryer (god that's a weird analogy) and I think I'll PM Sby in regards to the morespurts mod, as well.

As for the friction? I have no gosh damn clue how to anything regarding coding. But if you want to shoot me a PM and give me a run-down on what I'd need to do, then I'd be down for it!

Thanks for the response!
 

stuntcock

Content Creator
Joined
Jun 5, 2012
Feltorn said:
As for the friction? I have no gosh damn clue how to anything regarding coding.
Do you mean "no clue how to compile an SDT mod" or "no experience with ActionScript"? Or literally "never done any coding in my life"?

I can walk you through the "fewer spurts" mod regardless. But the friction stuff is more complex - if you have zero coding experience then you wouldn't benefit much from a tutorial approach, and it would be much simpler for me to just write it alone. Of course, you'd be free to review the code later and tinker with it, if you like.

Question: did you ask sby for permission to create a derivative mod, or did you ask him to upgrade his own mod with the new feature?

But if you want to shoot me a PM and give me a run-down on what I'd need to do, then I'd be down for it!
Nah. It's more useful to keep the posts in the open. In that way, they can serve as ersatz tutorials for someone who discovers the mod six months later and wants to expand it. If I provide any bad or misleading advice then someone can correct it; if I get hit by a meteor tomorrow then someone else can take over. I'll collaborate via PMs if someone is shy about their work and doesn't want to publish it in an unfinished state, but that doesn't seem to be the case here.

Also: the PM mailbox capacity on this site is fairly small (50) and so it's difficult to keep track of a complete discussion. Eventually you're forced to purge old messages and you may lose information, or forget to followup on old promises because the records have vanished.
 

sby

Content Creator
Coder
Joined
Sep 11, 2012
lol, posting at the same time of others, apparently

gonna throw it here for now until i am not lazy enough to do my thread update

morecumspurtsV3 - added ability to make amount of cumspurts negative to decrease them instead
https://app.box.com/s/lwc56wubitb52oqi7pwzs5xdvabvj46n



QA testing level amount: 2xMG
 

aztlan

Casual Client
Joined
Sep 14, 2013
How does

randomizeadditionalcumspurtsreductionfactor=0.3

work if you set

additionalcumspurts=-3

to a negative value?

The latter line means we should get 5-3 = 2 spurts. What happens when we introduce the first line now?
 

sby

Content Creator
Coder
Joined
Sep 11, 2012
for each strand that is going to be subtracted, there is a 30% chance that it will not be. (with a 0.3 value)
 

Wither

Content Creator
Joined
Dec 16, 2011
sby said:
lol, posting at the same time of others, apparently

gonna throw it here for now until i am not lazy enough to do my thread update

morecumspurtsV3 - added ability to make amount of cumspurts negative to decrease them instead
https://app.box.com/s/lwc56wubitb52oqi7pwzs5xdvabvj46n



QA testing level amount: 2xMG

Oh, whoa! didn't expect a reply this quickly from it.

The mod works perfectly! Thanks for the adjustment, now I just need to figure out how to stop the strand shaders from lagging me like crazy...

It'd be fine if I could turn every shader off except transparency, but guess who has no goddamn clue how to do that!

That's right, me.

stuntcock said:
Do you mean "no clue how to compile an SDT mod" or "no experience with ActionScript"? Or literally "never done any coding in my life"?

Option #4: None of the above.

I've done some scripting in pre-built game engines in the past, but most of that is code that was already written for me, I just slotted the commands into the right places. I could never figure out ActionScript during my flash working days, and I wouldn't even know where to begin compiling something.

Say I wanted to make a mod that allowed me to change the Alpha of the cum/spit strands even with the "Strand Shaders" option disabled. How would one go about that, persay? Because I don't even know where to start.
 

stuntcock

Content Creator
Joined
Jun 5, 2012
Feltorn said:
now I just need to figure out how to stop the strand shaders from lagging me like crazy...

It'd be fine if I could turn every shader off except transparency
After launching the game, toggle Strand Shaders on and then back off again. Spit strands should have a 0.25 alpha value.



Say I wanted to make a mod that allowed me to change the Alpha of the cum/spit strands even with the "Strand Shaders" option disabled. How would one go about that, persay? Because I don't even know where to start.
  • Decompile SDT.swf (JPEXS works well)
  • Search for the relevant keywords. "shader" is a good place to start.
  • Trace through the code; follow references. You might find a simple UI-related method, and then discover that it invokes a more "meaty" function which does some real work.
  • You can skim heavily at first. As you zero in on the relevant code, pay greater attention. In order to mod the game behaviour effectively, you'll need to understand what the game is doing.
    • In this case, you'll learn that all of the strands (spit and semen) are placed on three special layers. Although the strands interact with objects on other layers (such as the penis, mouth, and torso) via anchoring, strands are not actually drawn on those layers.
    • Because the strands belong to their own special layers, the game simply applies filters (aka shaders - the distinction isn't important here) to these layers. This is much easier than applying filters to each of the individual graphical elements which compose the strands, and it means that modding is also fairly straightforward -- we won't need to keep track of dozens of spit globules.
    • Therefore: one possible approach would be: find the code which applies the filters to the special layers, block/cancel/undo the application, and then slap on a simple transparency effect instead.
      • Remember that this is all hypothetical. We already have a viable workaround, but we'll run through this as a learning exercise.
    • Alternatively: we could redefine the filters. Strip out all of the CPU-intensive stuff, and leave only the transparency effect. Then we could allow the game to apply and remove the filters as much as it wants without any Mod interference; we'll never incur the CPU burden of fancy filter effects.
  • Code-tracing will eventually lead you to obj.InGameMenu.updateStrandShaders. This would be a good place to attempt the first approach.
Code:
public function updateStrandShaders_l() : void
      {
         this.setcbStrandShaders();
         if(g.strandShaders)
         {
            g.strandBackLayer.filters = g.spitShaders;
            g.strandFrontLayer.filters = g.spitShaders;
            g.cumLayer.filters = g.cumShaders;
            g.strandBackLayer.alpha = 1;
            g.strandFrontLayer.alpha = 1;
         }
         else
         {
            g.strandBackLayer.filters = [];
            g.strandFrontLayer.filters = [];
            g.cumLayer.filters = [];
            g.strandBackLayer.alpha = 0.25;
            g.strandFrontLayer.alpha = 0.25;
         }
      }
  • Additional code tracing will lead you to DT.DT(). This is not a good place to apply the second modding approach (because we can't hook the constructor for the entire game) but it does show you how the filters and shaders are defined.
Code:
      public function DT()
      {
         // extra code omitted for brevity
         g.highlightShader = new Shader(new this.HighlightFilter() as ByteArray);
         g.highlight = new ShaderFilter(g.highlightShader);
         g.highlightShader.data.trans.value = [0.275];
         g.highlightShader.data.totMult.value = [0.2];
         // extra code omitted for brevity
      }
  • For the first approach, you'd need to write a new version of the updateStrandShaders_l method. You could then use the lProxy technique to make your version "replace" the vanilla version.
    • lProxy is a more advanced technique. It helps if you're already familiar with function declaration and function invocation. I'd advise you to spend some time reviewing code (or running through some online tutorials) before attempting it.
  • For the second technique, you would simply need to redefine the g.highlightShader variables. This is as simple as putting "g.highlightShader = [whatever]" in your Mod's loading script. If you're very circumspect, then you'll ensure that your Mod's unloading code reverses the effect (restores the shaders to their original values).
 

sby

Content Creator
Coder
Joined
Sep 11, 2012
instead installing software to decompile sdt, i actually have all of the actionscript files for sdt in my thread under 'other downloads'

i also have a couple of code modding tutorial videos if you are interested in this stuff. nice thing is that you don't really need adobe flash cs5 for this stuff
 

Users who are viewing this thread

Top


Are you 18 or older?

This website requires you to be 18 years of age or older. Please verify your age to view the content, or click Exit to leave.