Enjoy programming more!
Kidspod is a post site which supports young programmers.
First step to join us.
Register as a member
For members

2022/12/31 21:58:17

MixJuice GET URL : kidspod.club/mj/2160

ピアノ

MMLで作りました。
S D F G H J K
Z X C V B N M

C D E F G A B

このような配列となっています。

  • 1
  • 1

SOURCE CODE

1 CLS:POKE#a40,0,0,152,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,151,145,145,153,0,0
2 POKE#a60,0,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,0,146,0,0
3 POKE#a80,0,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,0,146,0,0
4 POKE#aa0,0,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,0,146,0,0
5 POKE#ac0,0,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,146,0,0,146,0,0
6 POKE#ae0,0,0,146,0,154,151,155,0,154,151,155,0,154,151,155,0,154,151,155,0,154,151,155,0,154,151,155,0,0,146,0,0
7 POKE#b00,0,0,146,0,0,146,0,0,0,146,0,0,0,146,0,0,0,146,0,0,0,146,0,0,0,146,0,0,0,146,0,0
8 POKE#b20,0,0,146,0,67,146,0,68,0,146,0,69,0,146,0,70,0,146,0,71,0,146,0,65,0,146,0,66,0,146,0,0
9 POKE#b40,0,0,154,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,155,0,0
10 LRUN1
SAVE0

10 K=INKEY()
20 IFK=90 PLAY"C15"
30 IFK=83 PLAY"C+15"
40 IFK=88 PLAY"D15"
50 IFK=68 PLAY"D+15" 
60 IFK=67 PLAY"E15"
70 IFK=70 PLAY"E+15"
80 IFK=86 PLAY"F15"
90 IFK=71 PLAY"F+15"
100 IFK=66 PLAY"G15"
110 IFK=72 PLAY"G+15"
120 IFK=78 PLAY"A15"
130 IFK=74 PLAY"A+15"
140 IFK=77 PLAY"B15"
150 IFK=75 PLAY"B+15"
160 GOTO10
SAVE1

COMMENT

Kidspod運営チーム
Kidspod運営チーム2023/01/06 18:06:58

グラフィックだけじゃなく、本当に音がなるのが素敵です。80行目にエラーがありました。ダブルクォーテーションの位置がズレてしまってますね。