这个数据包 + 资源包让你可以直接在 Minecraft 中观看来自 YouTube 的任何视频
使用方法:
上传并创建资源包:
下载数据包并将其放入你的数据包文件夹(Datapack Folder),然后打开生成器,输入资源包名称、视频名称以及视频的 YouTube 链接。你可以输入任意数量的“视频”,但当你想要结束时,只需在“视频名称”处不输入任何内容直接点击回车,它就会将生成的资源包放入名为“Output”的文件夹中。
此外,除了生成新的资源包外,你还可以将你现有的资源包放入 Output 文件夹中,它只会对其进行编辑。
资源包生成后,它会告诉你帧数,请务必记住或复制帧数,在游戏中会用到它们。如果你忘记复制了,可以前往
在游戏中使用:
一旦你安装了资源包和数据包,就有两个命令可用:
/function video_player:video_player/use/play {name:"(名称)",frames:"(帧数)"}
此命令开始播放你下载的视频,需要两个输入参数:名称和帧数。
- 名称:你输入的视频名称
- 帧数:视频拥有的帧数,PY 文件会在生成资源包后发送该信息。如果你忘记复制帧数,可以前往 resourcepacks(资源包名称)\assets\minecraft\textures\misc(视频名称) 找到最后一帧,复制其编号,这就是最后一帧。
/function video_player:video_player/use/stop
不需要任何输入,当玩家运行此命令时,它会停止当前正在观看的视频。
工作原理:
生成器以 20 fps 的速度下载视频(因为 Minecraft 的运行速度为每秒 20 刻),然后将帧提取到资源包中,并下载视频音频。接着,使用数据包通过计分板每刻添加计数,并根据计分板使用物品组件 "camera_overlay" 显示 misc/frame-$(帧) 处的图片并播放声音。因此看起来就像是在播放视频。
This Datapack + Resource Pack lets You Watch Any Video from Youtube Directly throw minecraft
How to Use it:
Upload and Create the Resource Pack:
Download the Datapack and insert it into your Datapack Folder, then open the generator, enter the Resourse Pack name, a name of the video and link from youtube to the video, You can enter as many "Videos" as you want but then when you want to finish just click enter without inserting anything to the "video name" and it would generate the Resourse pack into a folder called "Output".
Also instead of Generating a new resourcepack you can put your exisiting resource pack inside the Output folder and it would just edit it.
after the resource pack has been generated, it will send you the amount of frames, MAKE SURE TO REMEMBER OR COPY THE FRAMES, YOU WILL NEED THEM IN GAME, if you did forgot to copy you can go to
How to Use it in Game:
once you have the resource pack and the datapack installed there are two commands:
/function video_player:video_player/use/play {name:"(NAME)",frames:"(FRAMES)"}
This Commands start a video You downloaded, in requires two inputs name and frames.
- Name: the name of the video you entered
- Frames: the amount of frames the video has, THE PY FILE SENDS IT AFTER IT GENERATES THE RESOURCE PACK if you did forgot to copy the amount of frames you can go to resourcepacks(Resource Pack Name)\assets\minecraft\textures\misc(Video Name) and find the last frame, copy its number and this is the last frame
/function video_player:video_player/use/stop
Doesnt requires any inputs, when a player runs it, it just stops the video he is watching.
How it Works:
The generator downloads the video at 20 fps (because minecraft runs on 20 ticks) and then it extracts the frames to the resource pack and downloads the audio of the video, then using the datapack it uses scoreboard to add each tick, and based on the scoreboard it shows you using the item compounent "camera_overlay" the picture at misc/frame-$(frame) and plays the sound. so it looks like a video
评论 0
登录后参与评分
还没有评论,来抢沙发吧