module: write components using a struct pattern
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
17db5498ee
commit
2115f5832a
8 changed files with 45 additions and 62 deletions
|
|
@ -21,9 +21,9 @@ pub const name = .renderer;
|
|||
pub const Mod = mach.Mod(@This());
|
||||
|
||||
pub const components = .{
|
||||
.{ .name = .location, .type = Vec3 },
|
||||
.{ .name = .rotation, .type = Vec3 },
|
||||
.{ .name = .scale, .type = f32 },
|
||||
.location = .{ .type = Vec3 },
|
||||
.rotation = .{ .type = Vec3 },
|
||||
.scale = .{ .type = f32 },
|
||||
};
|
||||
|
||||
pub const global_events = .{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue