diff --git a/src/luau.rs b/src/luau.rs index 4aa0cae..1d85ee4 100644 --- a/src/luau.rs +++ b/src/luau.rs @@ -29,7 +29,7 @@ impl<'a> StrafeluaGlobals<'a> { } } -pub fn new_state() -> Result { +pub fn new_state() -> Result<()> { let vm = Luau::new(); vm.sandbox(true).unwrap(); //Prevent bad actors @@ -44,7 +44,6 @@ pub fn new_state() -> Result { vm.globals().set("Player", strafe_player).unwrap(); vm.globals().set("Vector3", strafe_vector3).unwrap(); - let gib = *strafe_globals.current_vm; let _ = vm.load(r#" type f64 = number type vec3 = (x: f64, y: f64, z: f64) -> {x: f64, y: f64, z: f64} @@ -54,5 +53,5 @@ local v3 = Vector3(-10, 30, 50) print((`{("\n"):rep(3)} x=%d,y=%d,z=%d {("\n"):rep(3)}`):format(v3.x, v3.y, v3.z)) "#).exec(); - Ok(gib) + Ok(()) } \ No newline at end of file