trnaslte this lua code into c#. "-- Bounce Race
-- Constants
local LevelNames = { 'L1', 'L2','L3' }
local SpawnPos = { NewPoint( 48, 448 ), NewPoint( 48, 616 ) ,NewPoint( 128, 27*8 )}
local BackgroundColors = { 11, 0 , 6}
-- Semi Constants
local PlayerSpeedX, JumpHeight, GravityPower, Timescale = 0.25, 3, 0.156912  , 1
-- Full Vars
local Frames,Time, DashCool = 0, 0,0
local PlayerPos, PlayerVel = { 0, 0 }, { 0, 0 }
local  RenderOffset = NewPoint( 256, 240 )
local Gamestate, ButtonCool, Name, LID = 0, 0, "", 1

-- HitScans
local LScan,RScan = -1,-1
-- Animations
local Anim = {
  Idle = {1,2},
  Run = {3,4},
  InAir = 1
}
-- InputState, This is for external input, probably useless
local XAxis, YAxis, Start, Select, A, B = 0, 0, false, false, false, false
-- Player data. Yeah. I hate it.
-- Called on load
function Init()
  PlaySong( 0, true)
  TileSize = TilemapSize()
end
-- Useful Functions
function IsInTable(value, tbl) for _, v in ipairs(tbl) do if v == value then return true end end return false end
function RoundBy(input,by) return math.floor(input/by+0.5)*by end
function RPT1(val,NAME_1) if val > NAME_1 then return 1 elseif val < 1 then return NAME_1 else return val end end
function BYN(val) if val > 0 then return 1 elseif val < 0 then return -1 else return 0 end end
function Clamp2(val,min,NAME_1) if val > NAME_1 then return NAME_1 elseif val < min then return min else return val end end

-- For External Controls
function GetInput()
  Start,Select = Button( Buttons.Start, InputState.Down, 0 ),Button( Buttons.Select, InputSta Provide response in all capital letters, no lowercase letters allowed.
user