Discuss Scratch

Dro7615
Scratcher
20 posts

Creating a Music Player

Hi, I'm Dro7615, I'm looking on how to make a working music player and i really need some help. I got inspired from this project someone made: https://scratch.mit.edu/projects/2332236/. Which is a music player. After finding this, I wanted to know how to make something like this.

You probably think to just See Inside and put the scripts in the backpack. But, I don't feel like copying them. Maybe i just find some ways to make music player. Thank you

- Dro7615

Last edited by Dro7615 (Dec. 6, 2025 04:26:30)

cool_username_right
Scratcher
100+ posts

Creating a Music Player

Dro7615 wrote:

Hi, I'm Dro7615, I'm looking on how to make a working music player and i really need some help. I got inspired from this project someone made: https://scratch.mit.edu/projects/2332236/. Which is a music player. After finding this, I wanted to know how to make something like this.

You probably think to just See Inside and put the scripts in the backpack. But, I don't feel like copying them. Maybe i just find some ways to make music player. Thank you

- Dro7615
well I'm not sure what there is to change about the code since it's super simple but like you could so something along the lines of this for the play button
when this sprite clicked
if <(status) = [pause]> then
play sound (song number)
set [status v] to [play]
end
if <(status) = [play]> then
stop all sounds
set [status v] to [pause]
end
and this for the next/last song button
when this sprite clicked
change [song nuber v] by (1 or -1)
play sound (song number)
when green flag clicked
forever
set [song number v] to ((song number) mod [number of songs])
end
the only thing i dont know how to do is pause a song then continue it from where it was paused since the sound blocks are very limited

Last edited by cool_username_right (Dec. 7, 2025 04:15:40)

Dro7615
Scratcher
20 posts

Creating a Music Player

cool_username_right wrote:

Dro7615 wrote:

Hi, I'm Dro7615, I'm looking on how to make a working music player and i really need some help. I got inspired from this project someone made: https://scratch.mit.edu/projects/2332236/. Which is a music player. After finding this, I wanted to know how to make something like this.

You probably think to just See Inside and put the scripts in the backpack. But, I don't feel like copying them. Maybe i just find some ways to make music player. Thank you

- Dro7615
well I'm not sure what there is to change about the code since it's super simple but like you could so something along the lines of this for the play button
when this sprite clicked
if <(status) = [pause]> then
play sound (song number)
set [status v] to [play]
end
if <(status) = [play]> then
stop all sounds
set [status v] to [pause]
end
and this for the next/last song button
when this sprite clicked
change [song nuber v] by (1 or -1)
play sound (song number)
when green flag clicked
forever
set [song number v] to ((song number) mod [number of songs])
end
the only thing i dont know how to do is pause a song then continue it from where it was paused since the sound blocks are very limited

Thank you! I'll try that
cool_username_right
Scratcher
100+ posts

Creating a Music Player

Dro7615 wrote:

Thank you! I'll try that
did it work?
Dro7615
Scratcher
20 posts

Creating a Music Player

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

I'm still working on it. Its taking a while because i have other things to do.
Dro7615
Scratcher
20 posts

Creating a Music Player

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

I think you made a mistake with the status = pause and status = play. its ok
Dro7615
Scratcher
20 posts

Creating a Music Player

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

Kinda. It shared the project: https://scratch.mit.edu/projects/1253360073/editor/
cool_username_right
Scratcher
100+ posts

Creating a Music Player

Dro7615 wrote:

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

I think you made a mistake with the status = pause and status = play. its ok
ugh i keep doing that it's so annoying sorry about that
cool_username_right
Scratcher
100+ posts

Creating a Music Player

Dro7615 wrote:

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

Kinda. It shared the project: https://scratch.mit.edu/projects/1253360073/editor/
the link doesnt work did you share it?
Dro7615
Scratcher
20 posts

Creating a Music Player

cool_username_right wrote:

Dro7615 wrote:

cool_username_right wrote:

Dro7615 wrote:

Thank you! I'll try that
did it work?

Kinda. It shared the project: https://scratch.mit.edu/projects/1253360073/editor/
the link doesnt work did you share it?
Sorry for the inactivity! I think i accidentally unshared it. I'll shared again.
-ThatOneGuitarist-
Scratcher
500+ posts

Creating a Music Player

https://scratch.mit.edu/projects/968917011/

I made this a while back, and scratch has a 10 MB data limit per project so prob not possible

Powered by DjangoBB