Module:Byte

From Wiki of ZZT
Revision as of 07:50, 18 January 2021 by Quantum (talk | contribs) (Module for displaying an unsigned byte value in decimal and hex)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Documentation for this module may be created at Module:Byte/doc

local p = {}

function p.byte(frame)
	local i = tonumber(frame.args[1])
	return string.format("%d (0x%02X)", i, i)
end

return p