diff --git a/modules/color.lua b/modules/color.lua index a83157c..8ec815f 100644 --- a/modules/color.lua +++ b/modules/color.lua @@ -302,11 +302,8 @@ function color_mt.__newindex(t, k, v) if type(t) == "cdata" then if type(k) == "number" then t._c[k-1] = v - return end end - - rawset(color, k, v) end color_mt.__tostring = color.to_string diff --git a/modules/mat4.lua b/modules/mat4.lua index a1cff0d..ddbeef4 100644 --- a/modules/mat4.lua +++ b/modules/mat4.lua @@ -651,11 +651,8 @@ function mat4_mt.__newindex(t, k, v) if type(t) == "cdata" then if type(k) == "number" then t._m[k-1] = v - return end end - - rawset(mat4, k, v) end mat4_mt.__tostring = mat4.to_string @@ -673,7 +670,7 @@ function mat4_mt.__eq(a, b) assert(mat4.is_mat4(b), "__eq: Wrong argument type for right hand operant. ( expected)") for i = 1, 16 do - if not utils.tolerance(b[i] - a[i], constants.FLT_EPSILON) then + if not utils.tolerance(b[i]-a[i], constants.FLT_EPSILON) then return false end end