diff --git a/.vs/Firespitter/v15/Server/sqlite3/storage.ide b/.vs/Firespitter/v15/Server/sqlite3/storage.ide index a6edfc40..e0e46c05 100644 Binary files a/.vs/Firespitter/v15/Server/sqlite3/storage.ide and b/.vs/Firespitter/v15/Server/sqlite3/storage.ide differ diff --git a/Firespitter/Firespitter.csproj b/Firespitter/Firespitter.csproj index ea6dcd02..3a7c577c 100644 --- a/Firespitter/Firespitter.csproj +++ b/Firespitter/Firespitter.csproj @@ -9,7 +9,7 @@ Properties Firespitter Firespitter - v3.5 + v4.0 512 @@ -53,10 +53,50 @@ ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.dll False + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.AnimationModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.AudioModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.CoreModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.IMGUIModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.InputLegacyModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.InputModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.PhysicsModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.TextRenderingModule.dll + False + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.UI.dll False + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.UIModule.dll + False + + + ..\..\..\KSP_DEV\KSP_x64_Data\Managed\UnityEngine.VehiclesModule.dll + False + diff --git a/Firespitter/engine/FSgroundParticles.cs b/Firespitter/engine/FSgroundParticles.cs index 33a7e037..8e21b38d 100644 --- a/Firespitter/engine/FSgroundParticles.cs +++ b/Firespitter/engine/FSgroundParticles.cs @@ -56,8 +56,10 @@ public class FSgroundParticles : PartModule private MeshFilter meshFilter; // a class which contains mesh emitter, animator and renderer, assigned to a GameObject - private FSparticleFX particleFX; - private Texture2D particleTexture; + //KSP 1.8 + //private FSparticleFX particleFX; + //private Texture2D particleTexture; + //KSP 1.8 void Start() { @@ -70,44 +72,46 @@ void Start() meshFilter = washDisc.AddComponent(); meshFilter.mesh = MeshCreator.createDisc(emissionDiscSize, 100); + + //KSP 1.8 // fetch the particle texture from KSP's Game Database - particleTexture = GameDatabase.Instance.GetTexture(particleTextureName, false); + //particleTexture = GameDatabase.Instance.GetTexture(particleTextureName, false); - if (particleTexture == null) - { - Debug.Log("FSgroundParticles: particle texture loading error"); - // it should use the default particle in this case, or just some pink crap maybe - } - else - { - //Setting the values for the particle system. the animator is never doing anything exciting, all particle motion is handled in the late update code - particleFX = new FSparticleFX(washDisc, particleTexture); + //if (particleTexture == null) + //{ + // Debug.Log("FSgroundParticles: particle texture loading error"); + // // it should use the default particle in this case, or just some pink crap maybe + //} + //else + //{ + // //Setting the values for the particle system. the animator is never doing anything exciting, all particle motion is handled in the late update code + // particleFX = new FSparticleFX(washDisc, particleTexture); - // particles change color and alpha over time. - particleFX.AnimatorColor0 = getColorFromV4(particleColor0); - particleFX.AnimatorColor1 = getColorFromV4(particleColor1); - particleFX.AnimatorColor2 = getColorFromV4(particleColor2); - particleFX.AnimatorColor3 = getColorFromV4(particleColor3); - particleFX.AnimatorColor4 = getColorFromV4(particleColor4); - - particleFX.EmitterMinSize = particleSize.x; - particleFX.EmitterMaxSize = particleSize.y; - particleFX.EmitterMinEnergy = particleEnergy.x; - particleFX.EmitterMaxEnergy = particleEnergy.y; - particleFX.EmitterMinEmission = 0f; - particleFX.EmitterMaxEmission = 0f; - particleFX.AnimatorSizeGrow = particleSizeGrow; - - particleFX.EmitterLocalVelocity = new Vector3(0f, 0f, 0f); - particleFX.EmitterRndVelocity = new Vector3(0f, 0f, 0f); - // creates the emitters etc and assigns the above values - particleFX.setupFXValues(); - - //particleFX.pEmitter.rndRotation = true; - - // Can't turn on Interpolate Triangles on the emitter, casue it's not exposed to code. REALLY?!? WHY? - } - + // // particles change color and alpha over time. + // particleFX.AnimatorColor0 = getColorFromV4(particleColor0); + // particleFX.AnimatorColor1 = getColorFromV4(particleColor1); + // particleFX.AnimatorColor2 = getColorFromV4(particleColor2); + // particleFX.AnimatorColor3 = getColorFromV4(particleColor3); + // particleFX.AnimatorColor4 = getColorFromV4(particleColor4); + + // particleFX.EmitterMinSize = particleSize.x; + // particleFX.EmitterMaxSize = particleSize.y; + // particleFX.EmitterMinEnergy = particleEnergy.x; + // particleFX.EmitterMaxEnergy = particleEnergy.y; + // particleFX.EmitterMinEmission = 0f; + // particleFX.EmitterMaxEmission = 0f; + // particleFX.AnimatorSizeGrow = particleSizeGrow; + + // particleFX.EmitterLocalVelocity = new Vector3(0f, 0f, 0f); + // particleFX.EmitterRndVelocity = new Vector3(0f, 0f, 0f); + // // creates the emitters etc and assigns the above values + // particleFX.setupFXValues(); + + // //particleFX.pEmitter.rndRotation = true; + + // // Can't turn on Interpolate Triangles on the emitter, casue it's not exposed to code. REALLY?!? WHY? + //} + //KSP 1.8 thrustTransform = part.FindModelTransform(thrustTransformName); } @@ -168,35 +172,39 @@ void Update() } currentEmission = Mathf.Clamp(currentEmission, 0f, emission); - particleFX.pEmitter.minEmission = currentEmission; - particleFX.pEmitter.maxEmission = currentEmission; + //KSP 1.8 + //particleFX.pEmitter.minEmission = currentEmission; + //particleFX.pEmitter.maxEmission = currentEmission; + //KSP 1.8 } - void LateUpdate() + void LateUpdate() { if (!HighLogic.LoadedSceneIsFlight) return; - // to change particles you first have to get the array, modify it, then feed the whole thing back to the emitter - Particle[] particles = particleFX.pEmitter.particles; - - for (int i = 0; i < particles.Length; i++) - { - // Oh hey, you can't access Interpolate Triangles on mesh emitters, so I have to this junk! Fuck you, whoever made the old Unity particle system. - // if a new particle has a very high energy, it means it's a newly created one. Move it! - if (particles[i].energy > particles[i].startEnergy - (Time.deltaTime * 1.1f)) - { - //particles spawn on the outer points of the disc. move it a random amount towrds the center to distribute the spawning. a high number of outer points makes it look OK without exra sideways randomness. - particles[i].position = Vector3.Lerp(particles[i].position, washDisc.transform.position, UnityEngine.Random.value); - } - - // The position of the current particle relative to the disc center - Vector3 offset = washDisc.transform.position - particles[i].position; - // Repel the particles. The closer a particle is to the disc center, the faster it moves away from it. - particles[i].position -= offset.normalized * 0.01f * Mathf.Clamp((maxDistance - currentDistance) - offset.magnitude, 1f, 15f); + //KSP 1.8 + // // to change particles you first have to get the array, modify it, then feed the whole thing back to the emitter + // Particle[] particles = particleFX.pEmitter.particles; + + // for (int i = 0; i < particles.Length; i++) + // { + // // Oh hey, you can't access Interpolate Triangles on mesh emitters, so I have to this junk! Fuck you, whoever made the old Unity particle system. + // // if a new particle has a very high energy, it means it's a newly created one. Move it! + // if (particles[i].energy > particles[i].startEnergy - (Time.deltaTime * 1.1f)) + // { + // //particles spawn on the outer points of the disc. move it a random amount towrds the center to distribute the spawning. a high number of outer points makes it look OK without exra sideways randomness. + // particles[i].position = Vector3.Lerp(particles[i].position, washDisc.transform.position, UnityEngine.Random.value); + // } + + // // The position of the current particle relative to the disc center + // Vector3 offset = washDisc.transform.position - particles[i].position; + // // Repel the particles. The closer a particle is to the disc center, the faster it moves away from it. + // particles[i].position -= offset.normalized * 0.01f * Mathf.Clamp((maxDistance - currentDistance) - offset.magnitude, 1f, 15f); + // } + + // // assign the array back to the emitter + // particleFX.pEmitter.particles = particles; + //KSP 1.8 } - - // assign the array back to the emitter - particleFX.pEmitter.particles = particles; } - } -} \ No newline at end of file + } \ No newline at end of file diff --git a/Firespitter/engine/FSparticleFX.cs b/Firespitter/engine/FSparticleFX.cs index 265351aa..6cce79aa 100644 --- a/Firespitter/engine/FSparticleFX.cs +++ b/Firespitter/engine/FSparticleFX.cs @@ -2,107 +2,108 @@ namespace Firespitter { + //RBP - Deprecating this due to particle system changes. public class FSparticleFX { - public GameObject gameObject; - public GameObject parentObject; - public Texture particleTexture; - public bool useLocalSpaceVelocityHack = false; + //public GameObject gameObject; + //public GameObject parentObject; + //public Texture particleTexture; + //public bool useLocalSpaceVelocityHack = false; - public ParticleEmitter pEmitter; - public ParticleRenderer pRenderer; - public ParticleAnimator pAnimator; + //public ParticleEmitter pEmitter; + //public ParticleRenderer pRenderer; + //public ParticleAnimator pAnimator; - private bool componentsAdded = false; + //private bool componentsAdded = false; - #region component variables + //#region component variables - public string RendererShader = "Particles/Alpha Blended"; + //public string RendererShader = "Particles/Alpha Blended"; - public float EmitterMinSize = 0.1f; - public float EmitterMaxSize = 0.2f; - public float EmitterMinEnergy = 0.1f; - public float EmitterMaxEnergy = 0.8f; - public float EmitterMinEmission = 120f; - public float EmitterMaxEmission = 160f; - public Vector3 EmitterLocalVelocity = new Vector3(0f, 0f, 1f); - public Vector3 EmitterRndVelocity = new Vector3(0f, 0.1f, 0.1f); - public bool EmitterUseWorldSpace = true; - public bool EmitterRandomRotation = true; + //public float EmitterMinSize = 0.1f; + //public float EmitterMaxSize = 0.2f; + //public float EmitterMinEnergy = 0.1f; + //public float EmitterMaxEnergy = 0.8f; + //public float EmitterMinEmission = 120f; + //public float EmitterMaxEmission = 160f; + //public Vector3 EmitterLocalVelocity = new Vector3(0f, 0f, 1f); + //public Vector3 EmitterRndVelocity = new Vector3(0f, 0.1f, 0.1f); + //public bool EmitterUseWorldSpace = true; + //public bool EmitterRandomRotation = true; - public bool AnimatorDoesAnimateColor = true; + //public bool AnimatorDoesAnimateColor = true; - public Color AnimatorColor0 = new Color(0.2f, 0.2f, 0.2f, 0.1f); - public Color AnimatorColor1 = new Color(0.3f, 0.3f, 0.3f, 0.1f); - public Color AnimatorColor2 = new Color(0.5f, 0.5f, 0.5f, 0.09f); - public Color AnimatorColor3 = new Color(0.8f, 0.8f, 0.8f, 0.07f); - public Color AnimatorColor4 = new Color(1f, 1f, 1f, 0.05f); - - public float AnimatorSizeGrow = 0.5f; - - #endregion - - public FSparticleFX(GameObject _gameObject, Texture2D _particleTexture) - { - gameObject = _gameObject; - particleTexture = _particleTexture; - } - - private void addComponents() - { - pEmitter = gameObject.AddComponent(); - pRenderer = gameObject.AddComponent(); - pAnimator = gameObject.AddComponent(); - } + //public Color AnimatorColor0 = new Color(0.2f, 0.2f, 0.2f, 0.1f); + //public Color AnimatorColor1 = new Color(0.3f, 0.3f, 0.3f, 0.1f); + //public Color AnimatorColor2 = new Color(0.5f, 0.5f, 0.5f, 0.09f); + //public Color AnimatorColor3 = new Color(0.8f, 0.8f, 0.8f, 0.07f); + //public Color AnimatorColor4 = new Color(1f, 1f, 1f, 0.05f); + + //public float AnimatorSizeGrow = 0.5f; + + //#endregion + + //public FSparticleFX(GameObject _gameObject, Texture2D _particleTexture) + //{ + // gameObject = _gameObject; + // particleTexture = _particleTexture; + //} + + //private void addComponents() + //{ + // pEmitter = gameObject.AddComponent(); + // pRenderer = gameObject.AddComponent(); + // pAnimator = gameObject.AddComponent(); + //} - public void setupFXValues() - { - if (!componentsAdded) - { - addComponents(); - componentsAdded = true; - } - pRenderer.materials = new Material[1]; - pRenderer.materials[0].shader = Shader.Find(RendererShader); - pRenderer.materials[0].mainTexture = particleTexture; - - pEmitter.minSize = EmitterMinSize; - pEmitter.maxSize = EmitterMaxSize; - pEmitter.minEnergy = EmitterMinEnergy; - pEmitter.maxEnergy = EmitterMaxEnergy; - pEmitter.minEmission = EmitterMinEmission; - pEmitter.maxEmission = EmitterMaxEmission; - pEmitter.localVelocity = EmitterLocalVelocity; - pEmitter.rndVelocity = EmitterRndVelocity; - pEmitter.useWorldSpace = EmitterUseWorldSpace; - - pAnimator.doesAnimateColor = AnimatorDoesAnimateColor; - - Color[] colorAnimation = pAnimator.colorAnimation; - colorAnimation[0] = AnimatorColor0; - colorAnimation[1] = AnimatorColor1; - colorAnimation[2] = AnimatorColor2; - colorAnimation[3] = AnimatorColor3; - colorAnimation[4] = AnimatorColor4; - pAnimator.colorAnimation = colorAnimation; - - pAnimator.sizeGrow = AnimatorSizeGrow; - } + //public void setupFXValues() + //{ + // if (!componentsAdded) + // { + // addComponents(); + // componentsAdded = true; + // } + // pRenderer.materials = new Material[1]; + // pRenderer.materials[0].shader = Shader.Find(RendererShader); + // pRenderer.materials[0].mainTexture = particleTexture; + + // pEmitter.minSize = EmitterMinSize; + // pEmitter.maxSize = EmitterMaxSize; + // pEmitter.minEnergy = EmitterMinEnergy; + // pEmitter.maxEnergy = EmitterMaxEnergy; + // pEmitter.minEmission = EmitterMinEmission; + // pEmitter.maxEmission = EmitterMaxEmission; + // pEmitter.localVelocity = EmitterLocalVelocity; + // pEmitter.rndVelocity = EmitterRndVelocity; + // pEmitter.useWorldSpace = EmitterUseWorldSpace; + + // pAnimator.doesAnimateColor = AnimatorDoesAnimateColor; + + // Color[] colorAnimation = pAnimator.colorAnimation; + // colorAnimation[0] = AnimatorColor0; + // colorAnimation[1] = AnimatorColor1; + // colorAnimation[2] = AnimatorColor2; + // colorAnimation[3] = AnimatorColor3; + // colorAnimation[4] = AnimatorColor4; + // pAnimator.colorAnimation = colorAnimation; + + // pAnimator.sizeGrow = AnimatorSizeGrow; + //} - public void updateFX() - { + //public void updateFX() + //{ - if (useLocalSpaceVelocityHack) - { - //float velMagnitude = parentObject.GetComponent().velocity.magnitude; - float fxSpeed = Vector3.Dot(gameObject.transform.forward, parentObject.GetComponent().velocity); - if (fxSpeed > 0f) - fxSpeed = 0; - pEmitter.localVelocity = new Vector3(0f, 0f, 1f + (-fxSpeed * 0.1f)); - //pEmitter.maxEmission = pEmitter.minEmission + (velMagnitude * 3); - } - } + // if (useLocalSpaceVelocityHack) + // { + // //float velMagnitude = parentObject.GetComponent().velocity.magnitude; + // float fxSpeed = Vector3.Dot(gameObject.transform.forward, parentObject.GetComponent().velocity); + // if (fxSpeed > 0f) + // fxSpeed = 0; + // pEmitter.localVelocity = new Vector3(0f, 0f, 1f + (-fxSpeed * 0.1f)); + // //pEmitter.maxEmission = pEmitter.minEmission + (velMagnitude * 3); + // } + //} } } diff --git a/Firespitter/engine/FSvelocityController.cs b/Firespitter/engine/FSvelocityController.cs index 56403679..36795c20 100644 --- a/Firespitter/engine/FSvelocityController.cs +++ b/Firespitter/engine/FSvelocityController.cs @@ -34,7 +34,9 @@ public class FSvelocityController : PartModule Transform[] transformArray; private bool transformsFound = false; private Vector3 velocityDirection = new Vector3(0f, 0f, 0f); - private Firespitter.FSparticleFX[] particleFX; + //KSP 1.8 + //private Firespitter.FSparticleFX[] particleFX; + //KSP 1.8 private Texture2D particleTexture; private Vector3 finalThrust = new Vector3(0f, 0f, 0f); @@ -50,7 +52,9 @@ public override void OnStart(PartModule.StartState state) if (transformArray.Length > 0) { transformsFound = true; - particleFX = new Firespitter.FSparticleFX[transformArray.Length]; + //KSP 1.8 + //particleFX = new Firespitter.FSparticleFX[transformArray.Length]; + //KSP 1.8 } else { @@ -64,16 +68,18 @@ public override void OnStart(PartModule.StartState state) particleTexture = GameDatabase.Instance.GetTexture(particleTextureName, false); if (particleTexture != null) { - for (int i = 0; i < particleFX.Length; i++) - { - particleFX[i] = new Firespitter.FSparticleFX(transformArray[i].gameObject, particleTexture); - particleFX[i].EmitterLocalVelocity = EmitterLocalVelocity; - //Debug.Log("KTvelocityController: particle texture found: " + particleTextureName); - particleFX[i].setupFXValues(); - particleFX[i].pEmitter.minEmission = 0f; - particleFX[i].pEmitter.maxEmission = 0f; - particleFX[i].pEmitter.useWorldSpace = false; - } + //KSP 1.8 + //for (int i = 0; i < particleFX.Length; i++) + //{ + // particleFX[i] = new Firespitter.FSparticleFX(transformArray[i].gameObject, particleTexture); + // particleFX[i].EmitterLocalVelocity = EmitterLocalVelocity; + // //Debug.Log("KTvelocityController: particle texture found: " + particleTextureName); + // particleFX[i].setupFXValues(); + // particleFX[i].pEmitter.minEmission = 0f; + // particleFX[i].pEmitter.maxEmission = 0f; + // particleFX[i].pEmitter.useWorldSpace = false; + //} + //KSP 1.8 } else { @@ -111,11 +117,13 @@ public override void OnFixedUpdate() thrustUsed = 0f; if (thrustUsed > 0f) part.gameObject.GetComponent().AddForceAtPosition(finalThrust, t.transform.position); - if (useFX) - { - particleFX[i].pEmitter.minEmission = defaultEmitterMinEmission * thrustUsed; - particleFX[i].pEmitter.maxEmission = defaultEmitterMaxEmission * thrustUsed; - } + //KSP 1.8 + //if (useFX) + //{ + // particleFX[i].pEmitter.minEmission = defaultEmitterMinEmission * thrustUsed; + // particleFX[i].pEmitter.maxEmission = defaultEmitterMaxEmission * thrustUsed; + //} + //KSP 1.8 i++; } } diff --git a/Firespitter/wheel/FSwheel.cs b/Firespitter/wheel/FSwheel.cs index e1e70fd3..2d64da97 100644 --- a/Firespitter/wheel/FSwheel.cs +++ b/Firespitter/wheel/FSwheel.cs @@ -701,28 +701,30 @@ public override void OnStart(PartModule.StartState state) } else { - for (int i = 0; i < wheelList.wheels.Count; i++) - { - wheelList.wheels[i].smokeFX = new Firespitter.FSparticleFX(wheelList.wheels[i].fxLocation, smokeFXtexture); - wheelList.wheels[i].smokeFX.AnimatorColor0 = new Color(1.0f, 1.0f, 1.0f, 0.8f); - wheelList.wheels[i].smokeFX.AnimatorColor1 = new Color(1.0f, 1.0f, 1.0f, 0.5f); - wheelList.wheels[i].smokeFX.AnimatorColor2 = new Color(1.0f, 1.0f, 1.0f, 0.2f); - wheelList.wheels[i].smokeFX.AnimatorColor3 = new Color(1.0f, 1.0f, 1.0f, 0.1f); - wheelList.wheels[i].smokeFX.AnimatorColor4 = new Color(1.0f, 1.0f, 1.0f, 0.0f); - - wheelList.wheels[i].smokeFX.EmitterMinSize = 0.3f; - wheelList.wheels[i].smokeFX.EmitterMaxSize = 0.5f; - wheelList.wheels[i].smokeFX.EmitterMinEnergy = 0.1f; - wheelList.wheels[i].smokeFX.EmitterMaxEnergy = 0.3f; - wheelList.wheels[i].smokeFX.EmitterMinEmission = 0f; - wheelList.wheels[i].smokeFX.EmitterMaxEmission = 0f; - wheelList.wheels[i].smokeFX.AnimatorSizeGrow = 0.1f; + //for (int i = 0; i < wheelList.wheels.Count; i++) + //{ + //KSP 1.8 + //wheelList.wheels[i].smokeFX = new Firespitter.FSparticleFX(wheelList.wheels[i].fxLocation, smokeFXtexture); + //wheelList.wheels[i].smokeFX.AnimatorColor0 = new Color(1.0f, 1.0f, 1.0f, 0.8f); + //wheelList.wheels[i].smokeFX.AnimatorColor1 = new Color(1.0f, 1.0f, 1.0f, 0.5f); + //wheelList.wheels[i].smokeFX.AnimatorColor2 = new Color(1.0f, 1.0f, 1.0f, 0.2f); + //wheelList.wheels[i].smokeFX.AnimatorColor3 = new Color(1.0f, 1.0f, 1.0f, 0.1f); + //wheelList.wheels[i].smokeFX.AnimatorColor4 = new Color(1.0f, 1.0f, 1.0f, 0.0f); + + //wheelList.wheels[i].smokeFX.EmitterMinSize = 0.3f; + //wheelList.wheels[i].smokeFX.EmitterMaxSize = 0.5f; + //wheelList.wheels[i].smokeFX.EmitterMinEnergy = 0.1f; + //wheelList.wheels[i].smokeFX.EmitterMaxEnergy = 0.3f; + //wheelList.wheels[i].smokeFX.EmitterMinEmission = 0f; + //wheelList.wheels[i].smokeFX.EmitterMaxEmission = 0f; + //wheelList.wheels[i].smokeFX.AnimatorSizeGrow = 0.1f; - wheelList.wheels[i].smokeFX.setupFXValues(); + //wheelList.wheels[i].smokeFX.setupFXValues(); + //KSP 1.8 } + //} } } - } - + #endregion } @@ -1063,40 +1065,42 @@ private void fireScreechEffect(int wheelNumber, float deltaRPM) private void updateScreechEffect(int wheelNumber) { - if (wheelList.wheels[wheelNumber].screechCountdown > 0f) - { + //KSP 1.8 + //if (wheelList.wheels[wheelNumber].screechCountdown > 0f) + //{ // emit particles - if (wheelList.wheels[wheelNumber].wheelCollider.isGrounded) - { - if (useCustomParticleFX) - { - wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = particleEmissionRate * fxLevel; - wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = particleEmissionRate * fxLevel; - } - else - { - part.Effect("tireSmoke", fxLevel); - } - } - else - { - if (useCustomParticleFX) - { - wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = 0f; - wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = 0f; - } - } - //smokeFX - wheelList.wheels[wheelNumber].screechCountdown -= TimeWarp.deltaTime; - } - else - { - if (useCustomParticleFX) - { - wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = 0f; - wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = 0f; - } - } + //if (wheelList.wheels[wheelNumber].wheelCollider.isGrounded) + //{ + // if (useCustomParticleFX) + // { + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = particleEmissionRate * fxLevel; + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = particleEmissionRate * fxLevel; + // } + // else + // { + // part.Effect("tireSmoke", fxLevel); + // } + //} + //else + //{ + // if (useCustomParticleFX) + // { + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = 0f; + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = 0f; + // } + //} + ////smokeFX + //wheelList.wheels[wheelNumber].screechCountdown -= TimeWarp.deltaTime; + //} + //else + //{ + // if (useCustomParticleFX) + // { + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.minEmission = 0f; + // wheelList.wheels[wheelNumber].smokeFX.pEmitter.maxEmission = 0f; + // } + //} + //KSP 1.8 } public void OnGUI() diff --git a/For release/Firespitter/Firespitter.version b/For release/Firespitter/Firespitter.version index 3f78fab7..4bcb08d7 100644 --- a/For release/Firespitter/Firespitter.version +++ b/For release/Firespitter/Firespitter.version @@ -8,12 +8,12 @@ }, "KSP_VERSION":{ "MAJOR":1, - "MINOR":7, - "PATCH":4 + "MINOR":8, + "PATCH":0 }, "KSP_VERSION_MIN":{ "MAJOR":1, - "MINOR":6, + "MINOR":8, "PATCH":0 }, "KSP_VERSION_MAX":{ diff --git a/For release/Firespitter/Plugins/Firespitter.dll b/For release/Firespitter/Plugins/Firespitter.dll index a5ca1bb3..c5816b76 100644 Binary files a/For release/Firespitter/Plugins/Firespitter.dll and b/For release/Firespitter/Plugins/Firespitter.dll differ diff --git a/For release/Firespitter/Plugins/Firespitter.pdb b/For release/Firespitter/Plugins/Firespitter.pdb index bc3def1c..3413c6d1 100644 Binary files a/For release/Firespitter/Plugins/Firespitter.pdb and b/For release/Firespitter/Plugins/Firespitter.pdb differ