Muy buenas!
Hace unas semanas me entró la gusa de picar algo de código y probar a convertir mi msx en un organillo.
El problema lo tengo con inkey$ al mantener sostenida la tecla, la primera pulsación la pilla bien y luego hace una pausa y entonces vuelve a pillar la tecla del tirón...
Mi pregunta es hay alguna manera de evitar la pausa?
Esto es lo que tengo de momento:
10 tron 20 screen 0,,0 30 play"a" 40 Z = 10 'maximo de intentos hasta que detecta silencio 50 c = 0 'Contador 60 k$ = inkey$ 'lee teclado 70 if c = z then sound 8,0:goto 50 'para el sonido i resetea el contador 80 if k$ = "" then c = c+1:goto 60 else goto 100 90 'NOTAS OCTAVA 4 100 if k$ = "a" then sound 0,&HAC:SOUND 1,&H1:sound 8,12:c = 0 110 if k$ = "s" then sound 0,&h7D:sound 1,&h1:Sound 8,12:c = 0 120 if k$ = "d" then sound 0,&h53:sound 1,&h1:Sound 8,12:c = 0 130 if k$ = "f" then sound 0,&h40:sound 1,&h1:Sound 8,12:c = 0 140 if k$ = "g" then sound 0,&h1D:sound 1,&h1:Sound 8,12:c = 0 150 if k$ = "h" then sound 0,&hfe:sound 1,&h0:Sound 8,12:c = 0 160 if k$ = "j" then sound 0,&he3:sound 1,&h0:Sound 8,12:c = 0 170 if k$ = "k" then sound 0,&hd6:sound 1,&h0:Sound 8,12:c = 0 180 goto 60
Saludos!!
Login sesión o register para postear comentarios