local js = require("modules.json") local files = require("modules.files") local conductor = require("modules.conductor") local logging = require("modules.logging") local chartstr = files.read_file("charts/shucks/hard.json") local chart = js.parse(chartstr) local crochet = conductor:calculateCrochet(195) / 4 local vchart = { scrollSpeed = { hard = chart.speed }, notes = { hard = { } }, events = { { t = 0, e = "FocusCamera", v = { char = 0 } }, } } local musthit = false for index, strum in next, chart.strumLines do for index, note in next, strum.notes do if strum.position == "dad" or strum.position == "girlfriend" then note.id = note.id + 4 end vchart.notes.hard[#vchart.notes.hard + 1] = { t = note.time, d = note.id, l = note.sLen, c = strum.position } end end for index, event in next, chart.events do if event.name == "Camera Movement" then local char = event.params[1] == 1 and 0 or event.params[1] == 0 and 1 or 2 local e = { e = "FocusCamera", t = event.time, v = { char = char } } vchart.events[#vchart.events+1] = e elseif event.name == "CameraZoom" then local e = { e = "ZoomCamera", t = event.time, v = { zoom = tonumber(event.params[1]) } } vchart.events[#vchart.events+1] = e end end --[[{ "t": 30315.7894736842, "e": "ZoomCamera", "v": { "duration": 32, "ease": "expoOut", "mode": "stage", "zoom": 1.1 } },]] files.write_file("evil-hard.json", js.stringify(vchart))