Music: Difference between revisions

From Kaboom Wiki
Create the page, this is kinda a draft, and as such should be expanded in the future.
 
No edit summary
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
'''Music''' is the arrangement of sound to create some rhythm, harmony or melody.<ref>https://en.wikipedia.org/wiki/Music</ref>
{{Other wiki|https://en.wikipedia.org/wiki/Music}}
As it is found everywhere in human life, and as such culturally universal<ref>https://books.google.com/books?id=eWhBAQAAQBAJ</ref>, it has also gained it's place on [[Kaboom]]


Music can be defined as either a [https://en.wikipedia.org/wiki/MIDI list of notes] or a sound file.  
'''Music''' is the arrangement of sound to create some rhythm, harmony or melody.
As it is found everywhere in human life, and as such is culturally universal<ref>https://books.google.com/books?id=eWhBAQAAQBAJ</ref>, it has also gained its place on [[Kaboom]].


==On Kaboom==


== On Kaboom ==
On Kaboom, music is usually contained in either [https://noteblock.studio/nbs .nbs (Note Block Studio) files] or [[Wikipedia:MIDI|MIDI files]]. MIDI file support enables the playback of a larger collection of media, as MIDI transcriptions are much more abundant [[Wikipedia:Internet|online]] than their NBS counterparts.
On Kaboom, most music is formatted as a list of notes<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$IjbVzGbojyoPjwalASK0-25lmhVVPNCx1XZDte8c7RA</ref>.


Playing music in the format of a list of notes is acomplished by having a tick loop, and each tick collecting all notes to be played and playing them using /playsound.<ref>https://github.com/hhhzzzsss/HBot-Release</ref>
Music playback is seen as a rite of passage on the server, so many larger bots implement it. Some notable examples include [[ChomeNS Bot]], [[SBot]], [[HBot]], [[RecycleBot]] and [[mewo]]. [[obd]] also had an experimental music player branch, but it was abandoned due to annoyance and abuse concerns.


Most larger bots, such as [[ChomeNS Bot]]<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$zSKupSWyCfm17P_WWP4nxdx0N3A43yPqK4eZ1SnleNk</ref>, [[HBot]]<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$DkCNHGcSuTho0CLyfXTaj0IXCLO8BkthvlZBBYDjzlU</ref>, [[mewo]]<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$r8HkCgNyFy5JZPv9eR1caKTGgWnF33c1s6GQYNBX4Z4</ref>, and more have a type of music plugin.
===Implementation===


== Annoyances ==
It is usually accomplished through [[Command cores|command cores]] and the <code>[https://minecraft.wiki/w/Commands/playsound /playsound]</code> command, but playback is notably also possible through the use of [https://minecraft.wiki/w/Note_Block Note Blocks] and [https://minecraft.wiki/w/Item items] with [https://minecraft.wiki/w/Data_component_format#Item_format custom item data components].
As the music is played on the Kaboom server or a clone, the music will be played to those who the bot selects.


During coding, if you have your own music playing, during general playing or if you cannot have loud souds, in-game music can be annoying or distracting<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$51w0goIlVpWYPuboQr0towtknvPzY_C5-IIz4FC2yi4</ref>.
====Newbies====


This means that bots have to add measures to make the players not be annoyed by the music.
Music can seem to newbies like an insurmountable goal, but once you parse the file format and figure out how to time and execute the playback, it is surprisingly easy.


There are 2 main types of how to handle music consent.
==Playback target selection==


<ul>
Besides the quality of playback being incredibly variable (i.e. due to music player implementation, transcription quality, Note-to-minecraft sound accuracy and timing-to-tick accuracy), players are also often listening to their own music or simply do not want to hear Minecraft music.
<li>Opt-out - Music is listened by all players by default, using something like a nomusic tag to stop it. Currently mainly only used by [[mewo]]</li>
<li>Opt-in - To listen to music, you must first add a tag (eg. chomens_music) or execute a bot command. This is used by most bots<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$xq07Rd6ODddFqIee9Aa0ZLSdFO-tLDQ69upOgEeA7LA</ref><ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$1jKfvNJppSDCB_m8hCA-P4Cd79bajR7pJLk1YZJBDcY</ref>, and initially popularized by [[sbot]].
</ul>


As of right now, it is preferred to implement the opt-in strategy, although there are still bots that do not, like [[mewo]]<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$z9s4qANQN0kg_KoATyt1kgxubmuqkNdCiw1INltkmPA</ref>, and this is because cxvqo is a raper and does not need consent<ref>https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$ektPOEMmB3dsOc2uazcEqrmmsTxuVAmPc8Tjc-REzBk</ref>.
For this reason, most music player functions implement either an opt-in or opt-out option. Opt-out music playback (through the use of the <code>nomusic</code> tag) was the first option conceived, but has largely fallen out of favor due to daily server resets, (previously) player data not persisting and hostile design concerns.


== Skidding ==
Opt-in music playback was popularized by SBot, and soon ChomeNS would follow suit.
Music is a relatively hard concept for newbies, and because most newbies are skids, the code for music is often copied from one bot onto another.


Unnotable examples of this are:
Notably, bots like HBot and mewo still use the opt-out system. Whereas HBot is currently in maintenance mode and does not receive many updates, [[cxvqo]] has refused to switch over to the newer system, and has occasionally removed the opt-out tag from players (sometimes repeatedly) to force music playback even on players who have explicitly withdrawn consent.
<ul>
<li>ArtieWar figuring out [[Cxvqo|the great pedo]] [https://matrix.to/#/!CLjEvLBxzXyEDwOfXG:global.stork-brill.ts.net/$tK1rr-7ZhZdjdzcsTFcmodo0nWOyqBLRhQ99WkmXHpg cannot write good code.]</li>
</ul>


Even though playing music seems like a complex concept, it generally isn't<ref>i know</ref>. If you are reading this page and planning on copying another bot's music code, genuinely try making your own.
==References==
 
<references />

Latest revision as of 03:39, 25 August 2026

Music is the arrangement of sound to create some rhythm, harmony or melody. As it is found everywhere in human life, and as such is culturally universal[1], it has also gained its place on Kaboom.

On Kaboom[edit]

On Kaboom, music is usually contained in either .nbs (Note Block Studio) files or MIDI files. MIDI file support enables the playback of a larger collection of media, as MIDI transcriptions are much more abundant online than their NBS counterparts.

Music playback is seen as a rite of passage on the server, so many larger bots implement it. Some notable examples include ChomeNS Bot, SBot, HBot, RecycleBot and mewo. obd also had an experimental music player branch, but it was abandoned due to annoyance and abuse concerns.

Implementation[edit]

It is usually accomplished through command cores and the /playsound command, but playback is notably also possible through the use of Note Blocks and items with custom item data components.

Newbies[edit]

Music can seem to newbies like an insurmountable goal, but once you parse the file format and figure out how to time and execute the playback, it is surprisingly easy.

Playback target selection[edit]

Besides the quality of playback being incredibly variable (i.e. due to music player implementation, transcription quality, Note-to-minecraft sound accuracy and timing-to-tick accuracy), players are also often listening to their own music or simply do not want to hear Minecraft music.

For this reason, most music player functions implement either an opt-in or opt-out option. Opt-out music playback (through the use of the nomusic tag) was the first option conceived, but has largely fallen out of favor due to daily server resets, (previously) player data not persisting and hostile design concerns.

Opt-in music playback was popularized by SBot, and soon ChomeNS would follow suit.

Notably, bots like HBot and mewo still use the opt-out system. Whereas HBot is currently in maintenance mode and does not receive many updates, cxvqo has refused to switch over to the newer system, and has occasionally removed the opt-out tag from players (sometimes repeatedly) to force music playback even on players who have explicitly withdrawn consent.

References[edit]