Jump to content

[1.8.x-1.10.x] SmokeScreen 2.8.14 - Extended FX plugin (18 April 2020)


sarbian

Recommended Posts

I don't know why, but in that version all seems broken for me: the game becomes absolutely unstable and very slow when I try to launch a rocket. Oh, and the most important thing, no smoke at all.

I'm doing something wrong?, is there some change that I don't know?, or maybe are the .mu created for the previous version with a bad behavior now?

I have been unable to replicate this issue, having tried both with my own build and sarbian's Dev build #3 (I have not tried build #2). Could you

  1. double-check that you installed dev build #3 and that you installed it correctly;
  2. post your KSP_Data\output_log.txt, your .mu and .cfg?

By the way, your glowing smoke looks really good! this feels much better than weird clipping flames :)

EDIT: I asked around on #kspmodders and other modders don't seem to have this issue.

Edited by eggrobin
Link to comment
Share on other sites

Man this is looking good. Cant wait to see it implemented throughout the community. :)

I have a question, is it possible to drop an smoke effects emitter on the Launchpad at launch? Because, if so, that could be used for having the smoke roll-out over the launch area after the craft leaves the pad. Something like that would really finish off the effect. Its always bugged me how the smoke just ends at a certain distance behind the rocket, and it seems to me that's due to all the effects coming off the back of the rocket only. Dropping effects emitters every so often could change everything, if its possible. I don't know if that makes sense to anyone. Its just an idea I had, and thought I would pass it on. I have no idea how the effects work in this game, so maybe its not possible. But if it is, I think it would be worth experimenting with. :)

Link to comment
Share on other sites

Man this is looking good. Cant wait to see it implemented throughout the community. :)

I have a question, is it possible to drop an smoke effects emitter on the Launchpad at launch? Because, if so, that could be used for having the smoke roll-out over the launch area after the craft leaves the pad. Something like that would really finish off the effect. Its always bugged me how the smoke just ends at a certain distance behind the rocket, and it seems to me that's due to all the effects coming off the back of the rocket only. Dropping effects emitters every so often could change everything, if its possible. I don't know if that makes sense to anyone. Its just an idea I had, and thought I would pass it on. I have no idea how the effects work in this game, so maybe its not possible. But if it is, I think it would be worth experimenting with. :)

With my patches this is hopefully not needed. The smoke that you see coming out of the flame trench in Proot's screenshots can linger for a long time if the cfg settings are set correctly. This method (mostly collision with the help of buoyancy so things have a little more volume) has the advantage of also working when smoke interacts with the ground, buildings, other rockets or unsuspecting kerbals, while ad hoc emitters would not.

EDIT:

Submitted a pull request (#8) implementing suggestion #5 (and fixing some documentation).

Here is the updated list of new features---where I define new by 'not documented in the OP':


[COLOR="#008000"]// Initial density of the particle seen as sphere of radius size of perfect
// gas. We then assume (only true for ideally expanded exhaust) that the
// expansion is isobaric (by mixing with the atmosphere) in order to compute
// the density afterwards. Units (SI): kg / m^3.[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public double[/COLOR] initialDensity = [COLOR="#B22222"].6[/COLOR];

[COLOR="#008000"]// Whether to apply Archimedes' force, gravity and other things to the
// particle.[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public bool[/COLOR] physical = [COLOR="#0000FF"]false[/COLOR];

[COLOR="#008000"]// How much the particles stick to objects they collide with.[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public double[/COLOR] stickiness = [COLOR="#B22222"]0.9[/COLOR];

[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public double[/COLOR] dragCoefficient = [COLOR="#B22222"]0.1[/COLOR];

[COLOR="#008000"]// Logarithmic growth applied to to the particle.
// The size at time t after emission will be approximately
// (Log(logarithmicGrowth * t + 1) + 1) * initialSize, assuming growth = 0.
// TODO(sarbian): make this a cfg-configurable curve (as a function of
// density).[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public double[/COLOR] logarithmicGrowth = [COLOR="#B22222"]0.0[/COLOR];

[COLOR="#008000"]// Whether to nudge particles in order to alleviate the dotted smoke effect.
// Set this to true (default) when using 'Simulate World Space' in Unity,
// false otherwise.[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public bool[/COLOR] fixedEmissions = [COLOR="#0000FF"]true[/COLOR];

[COLOR="#008000"]// The initial velocity of the particles will be offset by a random amount
// lying in a disk perpendicular to the mean initial velocity whose radius
// is randomOffsetMaxRadius. This is similar to Unity's 'Random Velocity'
// Setting, except it will sample the offset from a (normal) disk rather
// than from a cube. Units (SI): m/s.[/COLOR]
[[color=teal]Persistent[/color]]
[COLOR="#0000FF"]public float[/COLOR] randomInitalVelocityOffsetMaxRadius = [COLOR="#B22222"]0.0f[/COLOR];

Some suggestions for mu files:

  • Do not use damping in Unity, use physical=true and tweak dragCoefficient instead.
  • Do not use Random Velocity in Unity, this leads to smoke pyramids. Use randomInitialVelocityOffsetMaxRadius in the cfg instead.
  • Avoid using grow, use logarithmicGrowth instead. This should become a curve like grow, but I'll let sarbian do that.
  • I cannot think of any good reason to set collideRatio (the restitution coefficient of smoke "collision") to something other than 0.

EDIT:

Performance considerations: collide=true can be costly. physical=true, randomInitialVelocityOffsetMaxRadius and logarithmicGrowth have negligible performance cost.

EDIT:

Merged by sarbian, get it in Dev build 4!

Edited by eggrobin
Link to comment
Share on other sites

To use dev build 4 - do I need to compile the code, or is there a way of getting it already compiled? (I am computer illiterate)

You need to click on the link provided by sarbian to his "SmokeScreen Dev" Jenkins job (below), then on "Last build (#4)".

You can get the dev version with his fix here :

http://ksp.sarbian.com/jenkins/job/SmokeScreen%20Dev/

Link to comment
Share on other sites

I think you people need to put your efforts together and in one thread. Smokescreen is essentially used in Hotrockets only so far.

It's kinda hard to follow both topics and to understand which of the two threads to follow for updates on the mods.

Link to comment
Share on other sites

I think you people need to put your efforts together and in one thread. Smokescreen is essentially used in Hotrockets only so far.

It is being used in at least one other already-released mod, stubbles's Zenit-3SLB. It also being used by erona, nothke, Proot and many other modders whose work has not been released yet.

To quote the author:

This plugin is here so that people with actual artistic taste ( not me ;) ) can do improved effect.

Unless you make your own effects or at least cfg edit them, you'll find that pushing the dev build on top of HotRockets! either breaks it (flames behave weirdly due to the dotted smoke fix, they should have fixedEmissions=false) or does nothing (my collision fixes only apply if collide=true; drag, buoyancy, logarithmic growth and the random normal offset are off by default).

Edited by eggrobin
Link to comment
Share on other sites

It means that if I want to use the latest when it comes to the advancements of SmokeFX, I will have to rely on Nazari to update HotRockets...well..

And yes, with Dev 4 applied on top of the latest release of HotRockets all the effect go wild - dotted smoke on SRBs, engine fire disappears at some altitude only to reappear once you enter vacuum at 70 km, engine fire trail still conforms to velocity indicator...

Link to comment
Share on other sites

It means that if I want to use the latest when it comes to the advancements of SmokeFX, I will have to rely on Nazari to update HotRockets...well..

And yes, with Dev 4 applied on top of the latest release of HotRockets all the effect go wild - dotted smoke on SRBs, engine fire disappears at some altitude only to reappear once you enter vacuum at 70 km, engine fire trail still conforms to velocity indicator...

I think you summed it up well in your previous post -- so many of these mods (and the game itself, if we can all remember) are early in development. To keep up with the latest tricks and tools and visual effects it's going to be necessary to follow many topic threads. Sure it's easy to lose track, but part of what makes modding "fun."

These folks are doing some amazing stuff for us. It's the least we can do to give them our patience. :D

---

Now get that smoke working!

Link to comment
Share on other sites

  • 3 weeks later...

Any chance of getting the fx to change based on altitude? Kind of like how smoke is, but it will change the look of what i call the "thrust cloud". This will change inefficient red/smoky to efficient blue, and hotter?

The default smoke effect is dependant on atmosphere, its visible at x altitude, and invisible at x altitude, but can this be applied to change the color of the fx of the thrust vector?

Had asked this in the HotRocket's thread but got redirected here.

Link to comment
Share on other sites

hum, Right now you could do that with multiple effect and each one only showing at a specific alt.

I'll have to see how I could change the colors without adding too much params

Link to comment
Share on other sites

You mean something like HotRockets! or KSO that both uses SmokeScreen since a long time ago ? As said in the first post this is a plugin to be used by other modders, not a "consumer version mod".

And I don't see why it should break with .24 unless you want to start some FUD campaign.

Edited by sarbian
Link to comment
Share on other sites

Is there an incompatibility between this mod and 0.23.5? I'm not sure if it's SmokeScreen or Hot Rockets but I'm getting a missing texture for the smoke particle effects on the stock SRB (the really short one). I'm using this mod for the Renaissance artistic mod. This is what happens:

http://i.imgur.com/uP2hVIk.png ; http://i.imgur.com/Z04h6EV.jpg

Any ideas?

Link to comment
Share on other sites

  • 2 weeks later...

Smokescreen 2.0 is nearly done. I added 2 inputs for curve ( part temperature & external temperature ) and new curves (for logarithmic Grow). I want to add color and alpha curve too but I think I'll release this version and add it for 2.1, since I want a "clean" way to add it (ie not adding a curve for each component r g b a).

There is a basic UI for some config and to help making effect (this part is far from done but I'll add a way to edit all the config from inside the game later)

Collision and the physic system takes a lot less CPU so it should be usable for more (and you can turn it off from the UI)

Link to comment
Share on other sites

And SmokeScreen 2.0 is done. The last few days were spent fixing a nasty bug and I could not add all I wanted in this release, but this need to get out so since more modder want to use it.

From a user point of view the change are quite small :

- Added a ToolBar icon to open a configuration screen. This will let you globally disable particle collision and physic if you feel it takes too much of your FPS.

From a modder point of view there is a bit more change :

- New input for the curves : part temperature & external temperature (those are in °C)

- All inputs can now go thru a log10 function so small numbers are more usable (good for the atmosphere curve near space). Just add "log" in front of the input (ie density => logdensity )

- New Input for logarithmic growth applied to the particles

- New offset curve and offsetDirection vector. This will let you move the particle emitter with the inputs (for example get the flame move away for the nozzle when power increase)

- UI for in game config. From the toolbar open the settings and then you can open 1 window per active SmokeScreen effect. See bellow for the use

The new UI let you :

- See the current Values for the inputs

- Override the inputs Values, so you can test all your config from the launchpad

- Clear the particles when you feel there is a bit too much smoke around

- Edit the effect config from inside the game !

- Import Button display the current active config. If used after a game start it will load the effect config as it is in the part .cfg

- Rebuild will display the current config and add ALL the default parameters. This is the config as seen by the game

- Apply will update the effect to use the content of the window

You can get it here :

https://ksp.sarbian.com/jenkins/job/SmokeScreen/lastSuccessfulBuild/artifact/jenkins-SmokeScreen-8/SmokeScreen-2.0.0.0.zip

The license was changed to a BSD 2-Clause License

Next version should add what I wanted to do for this one : a module to add effects to any part.

HoneyFox & Nazari : Beside the missing module did I forgot any of the feature we talked about ?

Link to comment
Share on other sites

I updated my SmokeScreen.dll with this new release and things are going a bit... weird, engine effects (HotRockets!) detach from their engines shortly after takeoff (~25,000 altitude seems to be ~750 m/s) and appear in space somewhere off to the side while spitting their effects ~perpendicular in a stretched fashion, example image;

uDSl7gX.jpg

Those blue dots are the engine effects which are now emitting in space nearby rather than from the engines

[Edit] Later on in space

8s72VTY.jpg

Edited by NoMrBond
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...