tiny.sdfii.runtime.ControllerComponent
Defined in runtime.
API (4)
Actions
Public operations.
Types and contracts
Public types and contracts.
Source
Source: fun/sdfii/src/engine/runtime.zig:19
zig
pub const ControllerComponent = runtime_controller_component;Source: fun/sdfii/src/engine/system/animation/controller.zig
zig
const std = @import("std");pub const Kind = enum(u8) { none = 0, client_input = 1,};pub const ComponentDesc = extern struct { kind: u8 = @backingInt(Kind.client_input), _pad0: [7]u8 = @as([7]u8, @splat(0)), session_id: u64 = 1, walk_speed: f32 = 3.2, strafe_speed: f32 = 2.4, ground_y: f32 = -0.35, vertical_settle: f32 = 0.08, pub fn fromBytes(bytes: []const u8) ?ComponentDesc { if (bytes.len < @sizeOf(ComponentDesc)) return null; var desc: ComponentDesc = undefined; @memcpy(std.mem.asBytes(&desc), bytes[0..@sizeOf(ComponentDesc)]); return desc; } pub fn kindTag(self: ComponentDesc) ?Kind { return std.enums.fromInt(Kind, self.kind); }};Audit
| Definitions | 5 |
|---|---|
| Public names | 8 |
| Members | 9 |
| Version | 26.7.0 |
| Revision | daab053ee433 |