Add propeller spin direction

This commit is contained in:
Alex Selimov 2026-08-12 20:16:48 -04:00
parent 6862712551
commit 78f5db1a9e
4 changed files with 11 additions and 1 deletions

View file

@ -1,6 +1,7 @@
const drone = @import("./drone.zig");
const vec3 = @import("./vec3.zig");
const forces = @import("./forces.zig");
const constants = @import("constants.zig");
const std = @import("std");
pub fn timestep(dt: f64, d: drone.Drone, props: []const drone.Propeller, s: *drone.State) void {
@ -62,6 +63,7 @@ test "Validate timesteps" {
.cg_to_prop = .init(1, 0, 0),
.moment_coefficient = 0.1,
.thrust_coefficient = 0.5,
.direction = constants.PropSpinDirection.cw,
};
const props: [1]drone.Propeller = .{prop};