Skip to content

Commit

Permalink
Merge pull request #16 from ChrisAdderley/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
ChrisAdderley authored Aug 22, 2020
2 parents d536761 + 825213f commit cff080d
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 6 deletions.
2 changes: 1 addition & 1 deletion GameData/Waterfall/Patches/Squad/liquidEngineSwivel.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
TEMPLATE
{
// This is the name of the template to use
templateName = waterfall-kerlox-sustainer-1
templateName = waterfall-kerolox-sustainer-1
// This field allows you to override the parentTransform name in the EFFECTS contained in the template
overrideParentTransform = thrustTransform
position = 0,0,0
Expand Down
Binary file modified GameData/Waterfall/Plugins/Waterfall.dll
Binary file not shown.
2 changes: 1 addition & 1 deletion GameData/Waterfall/Versioning/Waterfall.version
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{
"MAJOR":0,
"MINOR":1,
"PATCH":1,
"PATCH":2,
"BUILD":0
},
"KSP_VERSION":
Expand Down
1 change: 1 addition & 0 deletions Source/Waterfall/Effects/WaterfallEffect.cs
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ public void AddModifier(EffectModifier mod)

public void SetEnabled(bool state)
{
if (effectTransforms != null)
foreach (Transform t in effectTransforms)
{
if (state)
Expand Down
9 changes: 7 additions & 2 deletions Source/Waterfall/Modules/ModuleWaterfallFX.cs
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,19 @@ public override void OnLoad(ConfigNode node)
allFX = new List<WaterfallEffect>();
} else
{
allFX.Clear();
if (effectNodes.Length > 0 && allFX.Count > 0 || allFX.Count > 0 && templateNodes.Length >0)
{
CleanupEffects();
allFX.Clear();
}
}

foreach (ConfigNode fxDataNode in effectNodes)
{
allFX.Add(new WaterfallEffect(fxDataNode));
}


Utils.Log(String.Format("[ModuleWaterfallFX]: Loading Template effects on moduleID {0}", moduleID), LogType.Modules);
foreach (ConfigNode templateNode in templateNodes)
{
Expand All @@ -160,7 +165,7 @@ public override void OnLoad(ConfigNode node)
{
allFX.Add(new WaterfallEffect(fx, positionOffset, rotationOffset, scaleOffset, overrideTransformName));
}
Utils.Log($"[ModuleWaterfallFX]: Loaded effect template {template}", LogType.Modules);
Utils.Log($"[ModuleWaterfallFX]: Loaded effect template {template.templateName}", LogType.Modules);
}

Utils.Log($"[ModuleWaterfallFX]: Finished loading {allFX.Count} effects", LogType.Modules);
Expand Down
2 changes: 1 addition & 1 deletion Source/Waterfall/WaterfallData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace Waterfall
/// <summary>
/// Class to load shaders and config level data for the mod.
/// </summary>
[KSPAddon(KSPAddon.Startup.AllGameScenes, false)]
[KSPAddon(KSPAddon.Startup.Instantly, false)]
public class WaterfallData: MonoBehaviour
{

Expand Down
4 changes: 4 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v0.1.2
------
- Bugfixes

v0.1.1
------
- Fixed parsing of plume rotation in templates
Expand Down
2 changes: 1 addition & 1 deletion readme.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
===============
Waterfall 0.1.1
Waterfall 0.1.2
===============

TBW
Expand Down

0 comments on commit cff080d

Please sign in to comment.