Hello i am vid and i have built a piano game it has a few flaws like every time you press a key and play a note you have to hit leftkey to stop it teh white notes are on a,s,d,f,j,k,l,; and teh black notes are e,r,t,y,u but i dont know if it will let anybody else play teh notes because they're only saved on my computer. unless they're programmed into the game (i'm new to darkbasic) try this code out and tell me what i need to work on and how to make it better. peace
load music "C:/p.mid",1
load music "C:/2.mid",2
load music "C:/3.mid",3
load music "C:/4.mid",4
load music "C:/5.mid",5
load music "C:/6.mid",6
load music "C:/7.mid",7
load music "C:/8.mid",8
load music "C:/9.mid",9
load music "C:/10.mid",10
load music "C:/11.mid",11
load music "C:/12.mid",12
load music "C:/13.mid",13
Do
If keystate(30) = 1 then play music 1
If keystate(31) = 1 then play music 2
If keystate(18) = 1 then play music 3
If keystate(32) = 1 then play music 4
If keystate(19) = 1 then play music 5
If keystate(33) = 1 then play music 6
If keystate(20) = 1 then play music 7
If keystate(36) = 1 then play music 8
If keystate(37) = 1 then play music 9
If keystate(21) = 1 then play music 10
If keystate(38) = 1 then play music 11
If keystate(22) = 1 then play music 12
If keystate(39) = 1 then play music 13
if leftkey()=1 then stop music 1
if leftkey()=1 then stop music 2
if leftkey()=1 then stop music 3
if leftkey()=1 then stop music 4
if leftkey()=1 then stop music 5
if leftkey()=1 then stop music 6
if leftkey()=1 then stop music 7
if leftkey()=1 then stop music 8
if leftkey()=1 then stop music 9
if leftkey()=1 then stop music 10
if leftkey()=1 then stop music 11
if leftkey()=1 then stop music 12
if leftkey()=1 then stop music 13
Loop
Vid