diff options
author | s_alexander <s_alexander@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-04-07 15:11:27 +0000 |
---|---|---|
committer | s_alexander <s_alexander@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-04-07 15:11:27 +0000 |
commit | de19222a6fc53d455a91a8e5c8c99c080408392b (patch) | |
tree | dca01fcb4dfb37062354d6759ce279b853bca5f7 /Game/Code/Classes/USong.pas | |
parent | 9a89664288cf5bbdcf4892cf721268a820e64c5b (diff) | |
download | usdx-de19222a6fc53d455a91a8e5c8c99c080408392b.tar.gz usdx-de19222a6fc53d455a91a8e5c8c99c080408392b.tar.xz usdx-de19222a6fc53d455a91a8e5c8c99c080408392b.zip |
make BPM changes during song possible
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1016 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'Game/Code/Classes/USong.pas')
-rw-r--r-- | Game/Code/Classes/USong.pas | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Game/Code/Classes/USong.pas b/Game/Code/Classes/USong.pas index 9e55671e..d878132a 100644 --- a/Game/Code/Classes/USong.pas +++ b/Game/Code/Classes/USong.pas @@ -141,6 +141,7 @@ type Procedure AddLyricLine(const PlayerID: Integer; const StartBeat: Integer; const RelativeBeat: Integer = -1); Procedure AddNote(const PlayerID: Integer; const NoteType: Char; const NoteStart, NoteLength, NoteTone: Integer; const NoteText: WideString); Function SolmizatLyrics(const NoteTone: Integer; const NoteText: WideString): WideString; + Procedure AddBPM(const StartBeat: Integer; const NewBeat: Extended); public //Required Information Title: widestring; @@ -465,6 +466,14 @@ begin end; // case Ini.Solmization end; +Procedure TSong.AddBPM(const StartBeat: Integer; const NewBeat: Extended); +begin + SetLength(BPM, Length(BPM) + 1); + BPM[High(BPM)].StartBeat := StartBeat; + BPM[High(BPM)].StartBeat := BPM[High(BPM)].StartBeat + RelativPosition[0]; + + BPM[High(BPM)].BPM := NewBeat * Mult * MultBPM; +end; {constructor TSong.create( const aFileName : WideString ); begin |