这是由 hhhzzzsss 制作的 SongPlayer 模组的分支版本,新增了对 26.1/26.2 的支持以及与新版铜管乐器的兼容性。
免责声明:我与 SongPlayer 的开发者没有任何关联,请勿就本模组向 hhhzzzsss 寻求支持!!!
该模组的原始 README 如下(由于此分支与原版 SongPlayer 模组无关,已移除支持链接;寻求本模组支持的玩家不应前往原版模组的支持页面):
SongPlayer
一款用于 Minecraft 的 Fabric 模组,可使用音符盒播放歌曲。
安装方法
你可以从发布页面下载模组 jar 文件。
此模组需要 Fabric API。
添加歌曲
你可以将 MIDI 或 NoteBlockStudio 文件放入 .minecraft/songs 文件夹中。
SongPlayer 支持所有有效的 MIDI 文件和几乎所有版本的 NBS 文件(该模组目前尚不支持 NBS 文件中的铜管乐器)。
使用客户端
要开始使用,请将一些 MIDI 或 NBS 文件添加到你的歌曲文件夹中,并在空旷区域使用 $play <文件名>。
不支持在文件名或文件路径中使用空格。
如果你提供了有效的 MIDI 或 NBS 文件,它将尝试将你的游戏模式设置为创造模式,放置歌曲所需的音符盒,尝试将你切换回生存模式,然后开始播放。
你还可以在 songs 文件夹中将歌曲组织到子目录中。Tab 补全功能将使导航变得轻松。同时也支持符号链接(symlinked)目录。
命令
所有命令均不区分大小写。
$help
$help <command>
如果未提供参数,将列出所有 SongPlayer 命令。
否则,将解释指定的命令并显示其语法。
$setPrefix <prefix>
别名:$prefix
设置用于所有 SongPlayer 命令的前缀(默认为:$)。
$play <filename or url>
播放 .minecraft/songs 文件夹中的特定 MIDI 文件;或者,如果指定了 URL,则下载该 URL 处的歌曲并尝试播放它。
如果已有歌曲正在播放,新歌曲将被添加到队列中。
$stop
停止播放/构建并清空队列。
$skip
跳过当前歌曲并播放下一首。
$goto <mm:ss>
跳转到歌曲的特定时间点。
$loop
切换歌曲循环模式。
$status
别名:$current
获取当前正在播放的歌曲的状态。
$queue
别名:$showqueue
显示队列中的所有歌曲。
$songs
$songs <subdirectory>
别名:$list
如果未提供参数,将列出 songs 文件夹中的歌曲。否则,将列出指定子目录中的歌曲。
$playlist 播放 <播放列表>
$playlist 创建 <播放列表>
$playlist 列表 [<播放列表>]
$playlist 删除 <播放列表> <歌曲>
$playlist 添加歌曲 <播放列表> <歌曲>
$playlist 移除歌曲 <播放列表> <歌曲>
$playlist 重命名歌曲 <播放列表> <旧名称> <新名称>
$playlist 循环
$playlist 随机
创建、编辑、删除或播放播放列表。您还可以切换循环或随机播放模式。
$setCreativeCommand <command>
别名:$sc
默认情况下,客户端使用 /gamemode creative 进入创造模式。
但是,并非所有服务器都支持 /gamemode creative。
如果创造模式的命令不同,请使用此命令进行设置。
例如,如果服务器使用的是原版命令,请执行 $setCreativeCommand /gamemode creative。
$setSurvivalCommand <command>
别名:$ss
默认情况下,客户端使用 /gamemode survival 进入生存模式。
但是,并非所有服务器都支持 /gamemode survival。
如果生存模式的命令不同,请使用此命令进行设置。
例如,如果服务器使用的是原版命令,请执行 $setSurvivalCommand /gamemode survival。
$useEssentialsCommands
别名:$essentials, $useEssentials, $essentialsCommands
切换到使用 Essentials 插件的 gamemode 命令。
等效于 $setCreativeCommand /gmc 和 $setSurvivalCommand /gms
$useVanillaCommands
别名:$vanilla, $useVanilla, $vanillaCommands
切换到使用原版 gamemode 命令。
等效于 $setCreativeCommand /gamemode creative 和 $setSurvivalCommand /gamemode survival
$toggleFakePlayer
别名:$fakePlayer, $fp
切换是否在播放歌曲时显示一个假玩家来代表你的真实位置。在播放歌曲时,由于会自动启用自由视角(freecam),你的真实位置会与视觉上的位置不同。假玩家会显示你实际所在的位置。默认情况下,此功能处于禁用状态。
$setStageType <DEFAULT | WIDE | SPHERICAL>
别名:$setStage, $stageType
设置要构建的音符盒舞台类型。感谢 Sk8kman 和 Lizard16 提供的球形舞台设计!
- 默认(Default):方形舞台,最多包含 300 个音符盒
- 宽幅(Wide):圆柱形舞台,最多包含 360 个音符盒
- 球形(Spherical):密集排列的球形舞台,可容纳全部 400 个可能的音符盒
$breakSpeed set <speed>
$breakSpeed reset
设置方块破坏速度(单位:方块/秒)。
$placeSpeed set <speed>
$placeSpeed reset
设置方块放置速度(单位:方块/秒)。
$toggleMovement <swing | rotate>
别名:$movement
切换在敲击音符盒时是否挥动手臂并旋转视角以注视被敲击的音符盒。
$setVelocityThreshold <threshold>
别名:$velocityThreshold, $threshold
设置低于该阈值的速度将不会触发音符播放(适用于 midi 和 nbs 文件)。该值必须为 0 到 100 之间的数字。对于物品形式的歌曲,阈值在物品创建时已固化。
$toggleAutoCleanup
别名:$autoCleanup
切换是否在播放结束后自动清理舞台并将原始方块恢复原状。
$cleanupLastStage
清理最近创建的舞台,并尽力将方块恢复到其原始状态。
如果你停止游玩并重新开始,已记录的修改将被重置。
不会替换流体或门等双层方块,也不会替换实体方块数据。
可能也无法正确处理放置在其它方块上的方块(例如火把)。
$announcement <enable | disable | getMessage>
$announcement setMessage
设置播放歌曲时发送的公告消息。
使用 setMessage 时,在应显示歌曲名称的位置写入 [name]。
示例:$announcement setMessage &6正在播放:&3[name]
$toggleSurvivalOnly
别名:$survivalOnly
启用或禁用仅生存模式。在此模式下,自动放置音符盒功能将被禁用,调音需通过右键点击完成。
在此模式下,你必须自行放置所需的乐器。
如果尝试播放歌曲但条件不满足,它会告知你需要每种类型的乐器数量。
$toggleFlightNoclip
别名:$flightNoclip
切换飞行穿墙模式。启用后,你在播放歌曲时可以穿过方块,但仅限在飞行状态下。
$songItem create <song or url>
$songItem setSongName <name>
别名:$item
将歌曲数据编码到物品中。右键点击此类物品时,SongPlayer 会自动检测到这是歌曲物品并询问你是否要播放它。这些物品一旦创建,任何使用必要版本 SongPlayer 的玩家都可以使用。
它会自动生成自定义的物品名称和描述文本,但这些可以被修改或删除而不影响歌曲数据,因此你可以随意编辑物品。SongPlayer 仅查看 SongItemData 标签。
$testSong
我在开发期间用于测试的命令。
它按顺序播放所有 400 种可能的音符盒声音。
机制
SongPlayer 会放置已包含 NBT 和乐器数据的音符盒,因此无需单独调音。
客户端会自动检测所需音符盒并在每首歌曲播放前自动放置它们,这使得播放歌曲变得相当容易。唯一的缺点是你需要能够在创造模式和生存模式之间切换,我的客户端会尝试自动执行此操作。
播放歌曲时,自由视角(freecam)将启用。你可以自由移动,但实际上你只是在移动摄像机,而你的玩家角色保持在音符盒的中心。这是因为只有在你与音符盒的距离范围内才能播放它们,所以你必须站在音符盒中心来播放,但在歌曲播放时能够四处移动仍然很好。
致谢
Ayunami2000:提出了直接放置带有 NBT 数据的音符盒而非手动调音的概念。
Sk8kman:Songplayer 3.0 的许多更改都受到其 SongPlayer 分支版本的启发。最显著的是他们的替代舞台设计,这也激励我实现了播放列表和可切换的移动功能。
Lizard16:被 Sk8kman 引用为制作球形舞台设计的人。
hhhzzzsss:本模组所基于的 SongPlayer 模组的主要开发者
This is a fork of the SongPlayer mod by hhhzzzsss with added 26.1/26.2 support and compatibility with the new brass instruments.
DISCLAIMER: I AM IN NO WAY ASSOCIATED WITH THE DEVELOPER OF SONGPLAYER, DO NOT GO TO HHHZZZSSS FOR SUPPORT FOR THIS MOD!!!
The original readme for the mod is as follows (with support links removed as this fork is not associated with the original SongPlayer mod, and people seeking support for this mod should NOT go to the support page for the original mod):
SongPlayer
A Fabric mod for Minecraft that plays songs with noteblocks.
How to install
You can grab the mod jar from releases section.
This mod requires fabric api.
Adding songs
You can put midis or NoteBlockStudio files in the .minecraft/songs folder.
SongPlayer supports any valid midi and almost all versions of NBS files (the mod does not support brass instruments on NBS files yet).
Using the client
To get started, add some midis or nbs files to your songs folder, and use $play <filename> in an open area.
Spaces are not supported in filenames or filepaths.
If you have provided it a valid midi or nbs file, it will try to set your gamemode to creative, place the required noteblocks for the song, try to switch you to survival, then start playing.
You can also organize songs into subdirectories in your songs folder. Tab completion will make it easy to navigate. Symlinked directories are supported too.
Commands
All the commands are case insensitive.
$help
$help <command>
If no arguments are given, lists all SongPlayer commands.
Otherwise, explains the specified command and shows its syntax.
$setPrefix <prefix>
aliases: $prefix
Sets the prefix used for all SongPlayer commands (by default: $)
$play <filename or url>
Plays a particular midi from the .minecraft/songs folder, or, if a url is specified, downloads the song at that url and tries to play it.
If there is a song already playing, the new song will be added to the queue.
$stop
Stops playing/building and clears the queue.
$skip
Skips the current song and goes to the next one.
$goto <mm:ss>
Goes to a specific time in the song.
$loop
Toggles song looping.
$status
aliases: $current
Gets the status of the current song that is playing.
$queue
aliases: $showqueue
Shows all the songs in the queue.
$songs
$songs <subdirectory>
aliases: $list
If no arguments are given, lists songs in the songs folder. Otherwise, lists songs in the specified subdirectory.
$playlist play <playlist>
$playlist create <playlist>
$playlist list [<playlist>]
$playlist delete <playlist> <song>
$playlist addSong <playlist> <song>
$playlist removeSong <playlist> <song>
$playlist renameSong <playlist> <old name> <new name>
$playlist loop
$playlist shuffle
Create, edit, delete, or play playlists. You can also toggle looping or shuffling.
$setCreativeCommand <command>
aliases: $sc
By default, the client uses /gamemode creative to go into creative mode.
However, /gamemode creative does not work on all servers.
If the creative command is different, set it with this command.
For example, if the server uses vanilla commands, do $setCreativeCommand /gamemode creative.
$setSurvivalCommand <command>
aliases: $ss
By default, the client uses /gamemode survival to go into survival mode.
However, /gamemode survival does not work on all servers.
If the survival command is different, set it with this command.
For example, if the server uses vanilla commands, do $setSurvivalCommand /gamemode survival.
$useEssentialsCommands
aliases: $essentials, $useEssentials, $essentialsCommands
Switch to using Essentials gamemode commands.
Equivalent to $setCreativeCommand /gmc and $setSurvivalCommand /gms
$useVanillaCommands
$aliases: $vanilla, $useVanilla, $vanillaCommands
Switch to using vanilla gamemode commands.
Equivalent to $setCreativeCommand /gamemode creative and $setSurvivalCommand /gamemode survival
$toggleFakePlayer
aliases: $fakePlayer, $fp
Toggles whether a fake player will show up to represent your true position while playing a song. When playing a song, since it automatically enables freecam, your true position will be different from your apparent position. The fake player will show where you actually are. By default, this is disabled.
$setStageType <DEFAULT | WIDE | SPHERICAL>
aliases: $setStage, $stageType
Sets the type of noteblock stage to build. Thanks Sk8kman and Lizard16 for the spherical stage design!
- Default: A square shaped stage with a maximum of 300 noteblocks
- Wide: A cylindrical stage with a maximum of 360 noteblocks
- Spherical: A densely packed spherical stage that can contain all 400 possible noteblocks
$breakSpeed set <speed>
$breakSpeed reset
Sets the block breaking speed in blocks/sec.
$placeSpeed set <speed>
$placeSpeed reset
Sets the block placement speed in blocks/sec.
$toggleMovement <swing | rotate>
aliases: $movement
Toggles whether you swing your arm when hitting a noteblock and rotate to look at the noteblocks you are hitting.
$setVelocityThreshold <threshold>
aliases: $velocityThreshold $threshold
Sets the minimum velocity below which notes won't be played (applies to midi and nbs). This must be a number from 0 to 100. For song items, the threshold is baked in upon item creation.
$toggleAutoCleanup
aliases: $autoCleanup
Toggles whether you automatically clean up your stage and restore the original blocks after playing.
$cleanupLastStage
Cleans up the most recent stage that you made and does its best to restore the blocks to their original state.
If you stop playing and start playing again, the recorded modifications gets reset.
Will not replace fluids or double blocks such as doors, and does not replace tile entity data.
May not properly handle blocks that rest on other blocks such as torches, either.
$announcement <enable | disable | getMessage>
$announcement setMessage
Set an announcement message that is sent when you start playing a song.
With setMessage, write [name] where the song name should go.
Example: $announcement setMessage &6Now playing: &3[name]
$toggleSurvivalOnly
aliases: $survivalOnly
Enables or disables survival-only mode, in which automatic noteblock placement is disabled and automatic tuning is done by right-clicking.
In this mode, you must place the necessary instruments yourself.
If you try to play a song and the requirements are not met, it will tell you how many instruments of each type you need.
$toggleFlightNoclip
aliases: $flightNoclip
Toggles flight noclip. When enabled, your local player can clip through blocks when playing a song, but only while flying.
$songItem create <song or url>
$songItem setSongName <name>
aliases: $item
Encodes song data into an item. When you right click on such an item, SongPlayer will automatically detect that it is a song item and ask if you want to play it. These items, once created, can be used by anyone that is using the necessary version of SongPlayer.
It will automatically generate custom item names and lore, but these can be modified or deleted without affecting the song data, so feel free to edit the items as you wish. SongPlayer only looks at the SongItemData tag.
$testSong
A command I used for testing during development.
It plays all 400 possible noteblock sounds in order.
Mechanism
SongPlayer places noteblocks with nbt and instrument data already in them, so the noteblocks do not need to be individually tuned.
The client will automatically detect what noteblocks are needed and place them automatically before each song is played, which makes playing songs quite easy. The only drawback is that you need to be able to switch between creative and survival mode, which my client will attempt to do automatically.
When playing a song, freecam is enabled. You will be able to move around freely, but in reality you are only moving your camera while your player stays at the center of the noteblocks. This is because noteblocks can only be played if you're within reach distance of them, so you have to stand at the center of the noteblocks to play them, but it's still nice to be able to move around while your song is playing.
Acknowledgements
Ayunami2000: Came up with the concept of directly placing noteblocks with nbt data instead of manually tuning them.
Sk8kman: Several of Songplayer 3.0's changes were inspired by their fork of SongPlayer. Most notably was their alternate stage designs, but it also motivated me to implement playlists and togglable movements.
Lizard16: Cited by Sk8kman as the person who made the spherical stage design.
hhhzzzsss: Main developer of the SongPlayer mod, on which this mod is based upon
评论 0
登录后参与评分
还没有评论,来抢沙发吧