Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions core/resources/l10n/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -1482,6 +1482,17 @@ FuelTank.tab.General = Fuel Tank
FuelTank.tab.ttip.General = Fuel settings
! Engine Nozzle
Nozzle.Nozzle = Engine Nozzle
EngineNozzle.lbl.shape = Nozzle Shape
EngineNozzle.lbl.Clipped = Clipped
EngineNozzle.lbl.Shapeparam = Shape parameter
EngineNozzle.lbl.length = Length
EngineNozzle.lbl.foreDiam = Fore Diameter
EngineNozzle.lbl.aftdiam = Aft Diameter
EngineNozzle.lbl.automatic = Automatic
EngineNozzle.lbl.wallthick = Wall thickness
EngineNozzle.tab.General = General
EngineNozzle.lbl.Generalproperties = General Properties
compaddbuttons.Enginenozzle = Engine Nozzle
! Parachute
Parachute.Parachute = Parachute
! ShockCord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,7 @@
import net.sf.openrocket.aerodynamics.FlightConditions;
import net.sf.openrocket.aerodynamics.Warning;
import net.sf.openrocket.aerodynamics.WarningSet;
import net.sf.openrocket.rocketcomponent.BodyTube;
import net.sf.openrocket.rocketcomponent.RocketComponent;
import net.sf.openrocket.rocketcomponent.SymmetricComponent;
import net.sf.openrocket.rocketcomponent.Transition;
import net.sf.openrocket.rocketcomponent.*;
import net.sf.openrocket.util.BugException;
import net.sf.openrocket.util.Coordinate;
import net.sf.openrocket.util.LinearInterpolator;
Expand Down Expand Up @@ -69,7 +66,7 @@ public SymmetricComponentCalc(RocketComponent c) {
shape = ((Transition) component).getType();
param = ((Transition) component).getShapeParameter();
frontalArea = Math.abs(Math.PI * (foreRadius * foreRadius - aftRadius * aftRadius));

double r = component.getRadius(0.99 * length);
sinphi = (aftRadius - r) / MathUtil.hypot(aftRadius - r, 0.01 * length);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ class DocumentConfig {
constructors.put("tubefinset", TubeFinSet.class.getConstructor(new Class<?>[0]));
constructors.put("launchlug", LaunchLug.class.getConstructor(new Class<?>[0]));
constructors.put("railbutton", RailButton.class.getConstructor(new Class<?>[0]));
constructors.put("enginenozzle", EngineNozzle.class.getConstructor(new Class<?>[0]));

// Internal components
constructors.put("engineblock", EngineBlock.class.getConstructor(new Class<?>[0]));
Expand Down Expand Up @@ -201,6 +202,9 @@ class DocumentConfig {
setters.put("NoseCone:foreshoulderlength", null);
setters.put("NoseCone:foreshoulderthickness", null);
setters.put("NoseCone:foreshouldercapped", null);

// Engine Nozzle -- pretty much just transition?
// Is anything needed here??

// FinSet
setters.put("FinSet:fincount", new IntSetter(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package net.sf.openrocket.file.openrocket.savers;

import java.util.ArrayList;
import java.util.List;

public class EngineNozzleSaver extends TransitionSaver {

private static final EngineNozzleSaver instance = new EngineNozzleSaver();

public ArrayList<String> getElements(net.sf.openrocket.rocketcomponent.EngineNozzle c) {
ArrayList<String> list = new ArrayList<String>();

list.add("<enginenozzle>");
instance.addParams(c, list);
list.add("</enginenozzle>");

return list;
}

@Override
protected void addParams(net.sf.openrocket.rocketcomponent.RocketComponent c, List<String> elements) {
super.addParams(c, elements);

}

}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
import net.sf.openrocket.rocketcomponent.Transition;


public class TransitionSaver extends SymmetricComponentSaver {
public class
TransitionSaver extends SymmetricComponentSaver {

private static final TransitionSaver instance = new TransitionSaver();

Expand Down
Loading