Skip to content

Commit

Permalink
refactor the VehicleTransmissionSettings class
Browse files Browse the repository at this point in the history
  • Loading branch information
stephengold committed Oct 15, 2024
1 parent 9339890 commit 8ae2e81
Showing 1 changed file with 2 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,29 +30,20 @@ of this software and associated documentation files (the "Software"), to deal
* @author Stephen Gold [email protected]
*/
public class VehicleTransmissionSettings extends JoltPhysicsObject {
// *************************************************************************
// fields

/**
* prevent premature garbage collection of the underlying
* {@code WheeledVehicleControllerSettings}
*/
final private WheeledVehicleControllerSettings vehicle;
// *************************************************************************
// constructors

/**
* Instantiate a settings with the specified native object assigned but not
* owned.
*
* @param vehicle the underlying {@code WheeledVehicleControllerSettings}
* @param vehicle the containing object, or {@code null} if none
* @param settingsVa the virtual address of the native object to assign (not
* zero)
*/
VehicleTransmissionSettings(
WheeledVehicleControllerSettings vehicle, long settingsVa) {
this.vehicle = vehicle;
setVirtualAddress(settingsVa, null);
super(vehicle, settingsVa);
}
// *************************************************************************
// new methods exposed
Expand Down

0 comments on commit 8ae2e81

Please sign in to comment.