Skip to content

Commit

Permalink
Add modf implementation in classic
Browse files Browse the repository at this point in the history
  • Loading branch information
joelverhagen committed Jan 3, 2024
1 parent fa3314a commit 507f5eb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions CSharp.lua/CoreSystem.Lua/CoreSystem/Core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -743,6 +743,14 @@ else
return v
end
function System.modf(x, y)
local v = x % y
if v ~= 0 and x * y < 0 then
return v - y
end
return v
end
local function toUInt(v, max, mask, checked)
if v >= 0 and v <= max then
return v
Expand Down

0 comments on commit 507f5eb

Please sign in to comment.