lyra-wasm-scripting-test/witguest/wit/world.wit

21 lines
474 B
Plaintext
Raw Normal View History

2024-04-11 19:03:39 -04:00
package component:witguest;
interface math {
record vec3 {
x: f32,
y: f32,
z: f32,
}
}
2024-04-11 19:03:39 -04:00
/// An example world for the component to target.
world example {
import math;
use lyra:api/ecs.{ecs-world, entity};
import host-print: func(msg: string);
export on-init: func(game-world: borrow<ecs-world>, owning-entity: entity) -> result;
export on-update: func(game-world: borrow<ecs-world>, owning-entity: entity) -> result;
2024-04-11 19:03:39 -04:00
}