Module:Infobox interval: Difference between revisions

Plumtree (talk | contribs)
m Refactoring
Plumtree (talk | contribs)
mNo edit summary
Line 12: Line 12:


function p.infobox_interval(frame)
function p.infobox_interval(frame)
local debug_mode = frame.args['debug'] ~= nil
local debug_mode = frame.args['debug']
local rational = false
local rational = false
Line 277: Line 277:
'[[File:' .. sound .. '|270px]]<br/><small>[[:File:' .. sound .. '|[sound info]]]</small>'
'[[File:' .. sound .. '|270px]]<br/><small>[[:File:' .. sound .. '|[sound info]]]</small>'
})
})
elseif regular then
elseif debug_mode and debug_mode ~= 'hide' and regular then
local hz = 2 ^ (math.log(440)/math.log(2) + cents/1200)
local hz = 2 ^ (math.log(440)/math.log(2) + cents/1200)
-- is it within hearing range?
-- is it within hearing range?