-
-
Save careo/2505fbf0176c0073f8ff to your computer and use it in GitHub Desktop.
Fixup B9 ControlSurfaces
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@PART[B9_Aero_Wing_ControlSurface_SE_1m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 1.15 | |
deflectionLiftCoeff = 0.19 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_ControlSurface_SE_2m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.67 | |
deflectionLiftCoeff = 0.65 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_ControlSurface_SE_4m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.47 | |
deflectionLiftCoeff = 1.87 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_ControlSurface_SH_1m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 1.15 | |
deflectionLiftCoeff = 0.19 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_ControlSurface_SH_2m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.67 | |
deflectionLiftCoeff = 0.65 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_ControlSurface_SH_4m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.47 | |
deflectionLiftCoeff = 1.87 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.95 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Canard_2-3x1-6m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.9 | |
deflectionLiftCoeff = 0.49 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.856 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Canard_3x2-2m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.84 | |
deflectionLiftCoeff = 0.9 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.8932 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Canard_5x3-5m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.79 | |
deflectionLiftCoeff = 2.15 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.89 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Canard_6x5m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.78 | |
deflectionLiftCoeff = 4.39 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.735 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_2-3x1-6m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.9 | |
deflectionLiftCoeff = 0.49 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.275 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_3x2-2m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.84 | |
deflectionLiftCoeff = 0.9 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.23 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_3x2-75m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.81 | |
deflectionLiftCoeff = 1.35 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.2225 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_4x2-75m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 1.01 | |
deflectionLiftCoeff = 1.46 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.16 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_5x4-5m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.74 | |
deflectionLiftCoeff = 3.46 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.16 | |
} | |
} | |
@PART[B9_Aero_Wing_SW_Winglet_6x5m] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = 0.78 | |
deflectionLiftCoeff = 4.39 | |
ctrlSurfaceRange = 20 | |
ctrlSurfaceArea = 0.14 | |
} | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'erb' | |
b9_fix = File.open 'GameData/ExsurgentEngineering/B9CtrlSurfaceFix.cfg','w' | |
erb = ERB.new DATA.read | |
Dir['GameData/B9_Aerospace/**/*.cfg'].each do |file| | |
next unless %r{ | |
\s+name\s+=\s+(?<name>[\w|-]*)\S* | |
\s+module\s+=\s+ControlSurface\S* | |
.* | |
\s+dragCoeff\s+=\s+(?<dragCoeff>\S*) | |
\s+deflectionLiftCoeff\s+=\s+(?<deflectionLiftCoeff>\S*) | |
\s+ctrlSurfaceRange\s+=\s+(?<ctrlSurfaceRange>\S*) | |
\s+ctrlSurfaceArea\s+=\s+(?<ctrlSurfaceArea>\S*) | |
}mx =~ File.read(file) | |
p name | |
b9_fix.puts erb.result(binding) | |
end | |
__END__ | |
@PART[<%=name %>] | |
{ | |
@module = Part | |
MODULE | |
{ | |
name = ModuleControlSurface | |
dragCoeff = <%= dragCoeff %> | |
deflectionLiftCoeff = <%= deflectionLiftCoeff %> | |
ctrlSurfaceRange = <%= ctrlSurfaceRange %> | |
ctrlSurfaceArea = <%= ctrlSurfaceArea %> | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment