Cleaned up DrMundo's R.lua