Skip to content

Commit bc4041a

Browse files
committed
fix luau compile error
1 parent d7b9b16 commit bc4041a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

crates/languages/bevy_mod_scripting_lua/src/bindings/script_value.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@ impl FromLua for LuaScriptValue {
4141
Value::Nil => ScriptValue::Unit,
4242
Value::Boolean(b) => ScriptValue::Bool(b),
4343
// Value::LightUserData(light_user_data) => todo!(),
44+
#[cfg(not(feature = "luau"))]
4445
Value::Integer(i) => ScriptValue::Integer(i),
46+
#[cfg(feature = "luau")]
47+
Value::Integer(i) => ScriptValue::Integer(i as i64),
4548
Value::Number(n) => ScriptValue::Float(n),
4649
Value::String(s) => ScriptValue::String(s.to_str()?.to_owned().into()),
4750
Value::Table(table) => {

0 commit comments

Comments
 (0)