//------------------------------------------------------------------------------
// テキスト音楽「サクラ」音楽データ (dSakura.dll Version.2.379)
//------------------------------------------------------------------------------
曲名{"いつもちがう波"}
作者{"furnotiz3n"}
// copyright: Hiroyasu Furukawa, 2019
//------------------------------------------------------------------------------
//
//再生ごとにオルガンパートが変わります。
//原則 休符の次:音符80%、休符20%
//   音符(頭・伸ばし)の次:音符の頭30%、その音符を伸ばす30%、休符40%の確率です。
//ランダムなので学習も上達もしませんが、もっとよく聴こえる設定を気長に考えます。
//

音源初期化
拍子4,4
テンポ(140)

Str Text0="";
Str Text1="";
Str Text25="";

Array AR1=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR2=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR3=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR4=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR5=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR6=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR7=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
Array AR8=(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);

Int j=1
[16
AR1(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR2(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR3(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR4(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR5(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR6(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR7(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
AR8(j)=RandomSelect(0,1,2,3,4,5,6,7,8,9);
j++]

//AR1:最初の2小節

Text0 = "o5q94l8" + "'ea>d'"
Text1 = ""
j=2
[15        
If(Text1 == "r"){
	If(AR1(j) <= 7){
	Text1 = "'<ea>d'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR1(j) <= 2){
  	Text1 = "'<ea>d'"
 	}Else{
  	If(AR1(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR2:続いて2小節
j=1
[16        
If(Text1 == "r"){
	If(AR2(j) <= 7){
	Text1 = "'<f#a>ce'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR2(j) <= 2){
  	Text1 = "'<f#a>ce'"
 	}Else{
  	If(AR2(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR3:以下同じ
j=1
[16        
If(Text1 == "r"){
	If(AR3(j) <= 7){
	Text1 = "'<fa>ce'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR3(j) <= 2){
  	Text1 = "'<fa>ce'"
 	}Else{
  	If(AR3(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR4
j=1
[16        
If(j <= 7){
	Text25 = "'<fg#b>d#'"
}Else{Text25 = "'<fb>d'"
}
If(Text1 == "r"){
	If(AR4(j) <= 7){
	Text1 = Text25
	}Else{
	Text1 = "r"}
}Else{
 	If(AR4(j) <= 2){
  	Text1 = Text25
 	}Else{
  	If(AR4(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR5
j=1
[16        
If(Text1 == "r"){
	If(AR5(j) <= 7){
	Text1 = "'<ea>d'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR5(j) <= 2){
  	Text1 = "'<ea>d'"
 	}Else{
  	If(AR5(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR6
j=1
[16        
If(Text1 == "r"){
	If(AR6(j) <= 7){
	Text1 = "'<f#a>ce'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR6(j) <= 2){
  	Text1 = "'<f#a>ce'"
 	}Else{
  	If(AR6(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]

//AR7
j=1
[15        
If(j <= 7){
	Text25 = "'<fa>ce'"
}Else{Text25 = "'<fg#>cd#'"
}
If(Text1 == "r"){
	If(AR7(j) <= 7){
	Text1 = Text25
	}Else{
	Text1 = "r"}
}Else{
 	If(AR7(j) <= 2){
  	Text1 = Text25
 	}Else{
  	If(AR7(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}

}
Text0 = Text0 + Text1
j = j+1
]

//AR8
j=1
[16        
If(Text1 == "r"){
	If(AR8(j) <= 7){
	Text1 = "'<ea>d'"
	}Else{
	Text1 = "r"}
}Else{
 	If(AR8(j) <= 2){
  	Text1 = "'<ea>d'"
 	}Else{
  	If(AR8(j) >= 6){
    	Text1 = "r"
    	}Else{
	    	Text1 = "^"
		}
	}
}
Text0 = Text0 + Text1
j = j+1
]
Text0 = Text0 + "l2'<ea>d'^^"

Track(2);
Channel(2);
音色(GrandPiano)
音量(116)
o5q94l8 rrrrreff#
l4g^^^^^l8rab>c<l4a^^^^^l8rf#gal4a^b^>c^^el8g^^^^^^f
d^^<greff#
l4g^l8>g^^<g^^^^r>cdel4a^l8e^^aaecar<ab>c
f^^frfrgre^^<g^^>c^^^^^^^^^

Track(5);
Channel(5);
音色(PercussiveOrgan);
音量(68)

r1
Text0

Track(8);
Channel(8);
音色(FingerBass);
音量(127)
r1
o4q98l2 c<g>c<g l2>d<a>d<a >d<a>d<a fg#gb
o4q98l2 c<g>c<g l2>d<a>d<a >ddc#c# c<g>c<g >c^

Track(10);
Channel(10);
音量(60);
r1
l8 [8 rrn(75)rn(75)rrr n(75)rrn(75)rrn(75)r]

Track(11);
Channel(10);
r1
l8 [8 n(37)rrn(37)rrn(37)r rrn(37)rrn(37)rr]

Track(12);
Channel(10);
r1
l8 [8 n(69)n(69)n(69)n(69)n(69)n(69)n(69)n(69) n(69)n(69)n(69)n(69)n(69)n(70)n(69)n(69)]