convert fnf bpm changes to ke bpm changes
This commit is contained in:
parent
7c3b2860fc
commit
ab948419c5
@ -86,9 +86,6 @@ class MusicBeatState extends FlxUIState
|
|||||||
var step = ((60 / data.bpm) * 1000) / 4;
|
var step = ((60 / data.bpm) * 1000) / 4;
|
||||||
var startInMS = (data.startTime * 1000);
|
var startInMS = (data.startTime * 1000);
|
||||||
|
|
||||||
|
|
||||||
var percent = (Conductor.songPosition - startInMS) / (data.length * 1000);
|
|
||||||
|
|
||||||
curDecimalBeat = data.startBeat + (((Conductor.songPosition/1000) - data.startTime) * (data.bpm / 60));
|
curDecimalBeat = data.startBeat + (((Conductor.songPosition/1000) - data.startTime) * (data.bpm / 60));
|
||||||
var ste:Int = Math.floor(data.startStep + ((Conductor.songPosition - startInMS) / step));
|
var ste:Int = Math.floor(data.startStep + ((Conductor.songPosition - startInMS) / step));
|
||||||
if (ste >= 0)
|
if (ste >= 0)
|
||||||
|
@ -456,6 +456,34 @@ class PlayState extends MusicBeatState
|
|||||||
|
|
||||||
SONG.eventObjects = convertedStuff;
|
SONG.eventObjects = convertedStuff;
|
||||||
|
|
||||||
|
var ba = SONG.bpm;
|
||||||
|
|
||||||
|
var index = 0;
|
||||||
|
|
||||||
|
trace("conversion stuff " + SONG.song + " " + SONG.notes.length);
|
||||||
|
|
||||||
|
for(i in SONG.notes)
|
||||||
|
{
|
||||||
|
var currentBeat = 4 * index;
|
||||||
|
|
||||||
|
var currentSeg = TimingStruct.getTimingAtBeat(currentBeat);
|
||||||
|
|
||||||
|
if (currentSeg == null)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
var beat:Float = currentSeg.startBeat + (currentBeat - currentSeg.startBeat);
|
||||||
|
|
||||||
|
if (i.changeBPM && i.bpm != ba)
|
||||||
|
{
|
||||||
|
trace("converting changebpm for section " + index);
|
||||||
|
ba = i.bpm;
|
||||||
|
SONG.eventObjects.push(new Song.Event("FNF BPM Change " + index,beat,i.bpm,"BPM Change"));
|
||||||
|
}
|
||||||
|
|
||||||
|
index++;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
trace('INFORMATION ABOUT WHAT U PLAYIN WIT:\nFRAMES: ' + PlayStateChangeables.safeFrames + '\nZONE: ' + Conductor.safeZoneOffset + '\nTS: '
|
trace('INFORMATION ABOUT WHAT U PLAYIN WIT:\nFRAMES: ' + PlayStateChangeables.safeFrames + '\nZONE: ' + Conductor.safeZoneOffset + '\nTS: '
|
||||||
+ Conductor.timeScale + '\nBotPlay : ' + PlayStateChangeables.botPlay);
|
+ Conductor.timeScale + '\nBotPlay : ' + PlayStateChangeables.botPlay);
|
||||||
|
|
||||||
@ -3748,8 +3776,8 @@ class PlayState extends MusicBeatState
|
|||||||
{
|
{
|
||||||
if (!visibleCombos.contains(numScore))
|
if (!visibleCombos.contains(numScore))
|
||||||
{
|
{
|
||||||
numScore.destroy();
|
|
||||||
tween.cancel();
|
tween.cancel();
|
||||||
|
numScore.destroy();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
startDelay: Conductor.crochet * 0.002
|
startDelay: Conductor.crochet * 0.002
|
||||||
|
@ -18,6 +18,8 @@ class Section
|
|||||||
public var startTime:Float = 0;
|
public var startTime:Float = 0;
|
||||||
public var endTime:Float = 0;
|
public var endTime:Float = 0;
|
||||||
public var sectionNotes:Array<Array<Dynamic>> = [];
|
public var sectionNotes:Array<Array<Dynamic>> = [];
|
||||||
|
public var changeBPM:Bool = false;
|
||||||
|
public var bpm:Float = 0;
|
||||||
|
|
||||||
public var lengthInSteps:Int = 16;
|
public var lengthInSteps:Int = 16;
|
||||||
public var typeOfSection:Int = 0;
|
public var typeOfSection:Int = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user