typemap for luau analyzer, rename "tests" to "luau" and move tests into it

This commit is contained in:
unittensor 2024-01-21 17:39:32 -05:00
parent f21ec098db
commit 2f4e1d64dc
2 changed files with 17 additions and 0 deletions

17
luau/typemap.lua Normal file
View File

@ -0,0 +1,17 @@
--A type map for the luau analyzer
type f64 = number
type Vector2 = {x: f64, y: f64}
type Vector3 = Vector2 & {z: f64}
type Vector4 = Vector3 & {w: f64}
type fn_Vector3 = (x: f64, y: f64, z: f64) -> Vector3
local Vector3: fn_Vector3 = Vector3
type fn_Vector3add = (v1: Vector3, v2: Vector3) -> Vector3
local Vector3add: fn_Vector3add = Vector3add
return {
Vector3 = Vector3,
Vector3add = Vector3add
}