修改协议

This commit is contained in:
EillesWan 2024-07-18 16:21:10 +08:00
parent f6b884e38f
commit 932b9a34e0
32 changed files with 194 additions and 450 deletions

View File

@ -1,218 +1,123 @@
**注意以下条款或版权声明应当且必须是高于此项目中任何其他声明的**
# 汉钰律许可协议
1. ·创的全部开发者享有其完整版权其开发者可以在任一时刻终止以后音·创源代码开放若经由其开发者授予特殊权利则授权对象可以将源代码进行特定的被特殊授权的操作
2. ·创或其代码允许在 Apache2.0 协议的条款与说明下进行非商业使用
3. 除部分代码特殊声明外·创允许对其或其代码进行商业化使用但是需要经过音·创主要开发者诸葛亮与八卦阵金羿的一致授权同时授权对象在商业化授权的使用过程中必须依照 Apache2.0 协议的条款与说明
4. 若存在对于音·创包含的部分代码的特殊开源声明则此部分代码依照其特定的开源方式授权但若此部分代码经由此部分代码的主要开发者一致特殊授权后商用则授权对象在商用时依照此部分的开发者所准许的方式或条款进行商用
5. Apache2.0 协议的英文原文副本可见下文
**总第一版 · 二〇二四年七月七日编**
> The English Translation of the TERMS AND CONDITIONS above is listed below
>
> This translated version is for reference only and has no legal effect.
>
> The version with legal effect is the Chinese version above.
## 一、重要须知
**Note, The TERMS AND CONDITIONS below should and must be above all others in this project**
1. 为保护采用本协议的作品在开源过程中其著作权人所应有的权益根据**中华人民共和国著作权法和相关法律法规**制定本协议
1. *Musicreater* is fully copyrighted by all its developers, the developers have the right to make *Musicreater* close sourced at any time. Operations are permitted under specific terms instructed by its developer(s).
2. Non-commercial use of *Musicreater* and(or) its source code is permitted under Apache License 2.0.
3. Commercial use of *Musicreater* is permitted under Apache License 2.0 with the unanimous permission of the steering developers of *Musicreater* (*bgArray*诸葛亮与八卦阵 and *Eilles*金羿).
4. *Musicreater* is open sourced under priority given:
1. License granted by the core developer(s) of a section after negotiation.
2. Explicitly stated license.
3. Apache 2.0 License.
5. A copy of the original Apache Lisence 2.0 can be found below.
2. 本协议履行过程中请注意本协议中**免除或限制**民事主体**责任或权利**的条款法律适用和争议解决条款尤其是加有特殊标记的条款这些条款应在中国法律所允许的范围内最大程度地适用
```text
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
3. 若本协议所涉及的自然人**未满 18 周岁**该自然人应在监护人的陪同下阅读本协议及有关本协议的条款内容并在取得其监护人同意后开始或继续应用本协议所授权的行为
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
4. 由于互联网服务互联网内容的特殊性若本协议以电子协议形式分发并签订其依然有效您一旦开始对本协议所授权之作品进行本协议所授权的行为即视为您已经阅读理解并同意并已经接受本协议的全部条款
1. Definitions.
5. 本协议的订立履行解释及争议的解决均**适用中华人民共和国法律并排除其他一切冲突法的适用**_本协议订立于许可证最初的颁发者的地址若其为自然人则订立于该自然人户籍所在地若为法人或非法人组织则订立于其注册地_本协议的订立各方应友好协商解决于协议所规定之行为的履行相关的争议如协商不成任何一方均可向合同签订地有管辖权的人民法院提起诉讼
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
6. 本协议的原本仅为现代汉语书写于简体中文若存在其他语言的翻译或其他同等语言但非简体中文文本的版本应当无法律效力
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
## 二、术语定义
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
1. **许可证****协议**后文称本协议是指根据本文档中所列举的全部术语定义条款限制等文本是本合同的简称称谓本合同全称是汉钰律许可协议
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
2. **协议颁发者**后文称颁发者是将条款或协议应用于其拥有著作财产权的作品的民事主体或由其指定从而拥有颁发者身份的民事主体
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
3. ****形式是指对包括但不限于 软件硬件文档配置项 等种类的作品进行修改编辑的首选形式若不存在首选形式则初次编辑该作品所需的形式即为源形式
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
4. **目标**形式是指对源形式进行机械转换翻译打印制造加工等同类型活动后形成的结果形式包括但不限于源代码编译后的目标软件生成的文件转换出的媒体制造出的机械打印出的实体文本加工后的零件
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
5. **采用本协议的作品**后文称此作品是指经颁发者授权而使用本协议进行授权的任何作品该作品应在自然人可见处明确附加一个自然人可读的版权通知可以参考文末附录中提供的示例若在一个可分割的作品中部分地采用本协议进行授权则该部分应当视为一个独立的采用本协议的作品该作品应当在自然人可见处明确附加一个自然人可读的范围限定和版权通知同样可以参考文末附录中提供的示例
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
6. **贡献**是指对作品进行的意在提交给此作品颁发者以让著作权人包含在其作品中的任何修订或补充该修订或补充同样属于一种作品依据此定义提交一词表示经由此作品颁发者所指定的形式将其所进行的修改发送给此作品颁发者该形式应当包括在此作品颁发者指定的平台内发送易于编辑的修改信息在此作品颁发者指定的电子邮箱中发送易于编辑的修改信息在此作品颁发者指定的源码控制系统或发布跟踪系统上提交的易于编辑的修改信息但由著作权人以明显标注或指定为非贡献的活动除外颁发者自己对作品进行的修改同样视作对作品的贡献
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
7. **贡献者**是指此作品颁发者接受的贡献的提交者或包含在作品的贡献清单中的民事主体贡献者在提交贡献并经此作品颁发者通过且该贡献已经被应用于此作品中后该贡献者应当视为此作品的著作权人之一但不应视为此作品非其贡献的部分的著作权人一个作品的颁发者同样属于其贡献者**请注意**针对贡献者提交的贡献该贡献者应被视为该贡献的协议颁发者但不应视作本作品的颁发者
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
8. **用户****使用者**是指行使本协议所授权之行为的民事主体据此贡献者亦属于用户
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
9. **商业性使用****商用**是指任何以谋取利益为目的的使用包括但不限于以贩卖出租的形式对作品进行使用但若将该牟利活动明确指示为捐赠且在牟利者进行本协议所授权的活动时不以捐赠数额为标准则此种的获取利益的捐赠行为不属于商业性使用
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
## 三、权利授予
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
1. 任何由颁发者所进行的特殊声明特别注意等此类内容应当在法律效力上高于本协议的条款或声明这些声明若与本协议冲突本协议的该冲突部分无效本协议与这些声明共同构成颁发者与用户之间的合同
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
2. 此作品的贡献者享有其贡献的完整著作权
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
3. 此作品的贡献者将自己的贡献的全部著作财产权免费公开不可撤销无限期非专有地授予此作品的全部著作权人并准许其在全世界范围内使用上述权利若无明确的标识贡献者允许此作品的颁发者对其贡献进行免费公开不可撤销无限期非专有世界范围内的商业性使用
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
4. 此作品的著作权人及贡献者授予用户**免费公开不可撤销非专有非商用**地以任意形式**复制发行展览表演放映广播信息网络传播摄制改编翻译汇编二次授权**的权利准许其在此作品颁发者所指定的区域与时间内行使上述权利若此作品颁发者未特别指定的则视作在全世界范围内无限期地授权若此作品颁发者特别指定在特定情况下可以商用则应当按照其所指定的条件进行商业性使用商用的过程中应当明确标识此作品的著作权人
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
5. 一旦此作品有任意由非贡献形式而产生的更改更改的部分将不视为此作品的一部分除非该部分不可离开此作品单独存在若该部分必须依赖此作品而不可与此作品分离从而单独存在则更改后的作品不视作此作品在这种情况下除非此更改后的作品已获得此作品颁发者的特殊许可或更改者即为此作品颁发者本人否则对该作品进行的任何活动都应当遵守本协议
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
6. 经贡献而产生的对此作品的更改属于此作品的一部分在此情况下更改后的作品依旧视作此作品
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
7. 依据本款的第 4 若用户在本协议的授权下将此作品授予他人进行任何形式的活动二次授权二次分发则应确保其使用的协议或授权内容与本协议的条款不冲突当存在与本协议条款的冲突时则该冲突内容无效被授权的第三方应依照本协议的条款进行活动除非该用户获得了此作品颁发者的特殊许可或该用户即为此作品颁发者本人
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
8. 依据本款的第 5 若由非贡献形式而产生更改的部分是可分割而不需依赖此作品即可单独存在的若该部分明确注明不使用本协议进行授权或明确声明了其他授权条款则该部分不视作采用本协议但未更改的部分仍应视作原此作品的一部分需要采用本协议进行授权除非此更改后的作品已获得此作品颁发者的特殊许可或更改者即为此作品颁发者本人
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
9. 若此作品或所提交的贡献包含其著作权人的专利则该专利所有人即此作品的著作权人应准许此作品全体著作权人**免费公开不可撤销非专有无版权费的专利许可**以便贡献者对作品进行本协议所授权进行的活动
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
10. 上述专利许可的授予仅适用于在所提交的贡献中可由专利所有者授予的且在对此作品进行本协议所授权的活动中必须使用的专利
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
11. 如果用户对任何民事主体因其在进行本协议所授权进行的活动中侵犯该用户的专利而提起诉讼那么根据本协议授予该用户的所有关于此作品的任何其他专利许可将在提起上述诉讼之日起终止
END OF TERMS AND CONDITIONS
12. 如果本作品作为用户的其他作品的不可分割的一部分进行任何民事活动本协议依旧对本作品即该用户的其他作品的一部分生效若本作品完全融入该用户的其他作品之中而不可独立存在则该用户需要保证其作品存在与本协议冲突的条款除非该作品已获得此作品颁发者的特殊许可或该用户即为此作品颁发者本人
## 四、使用条件
Copyright 2023 TriM-Organization 金羿("Eilles Wan") & 诸葛亮与八卦阵("bgArray") & all the developers of Musicreater
在对此作品进行本协议所授权的民事活动中应当同时满足以下条款
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
1. 用户必须为此作品的任何其他接收者提供本协议的副本在不得已无法提供副本的情况下也应明确指示其他接收者可查阅本协议的位置
http://www.apache.org/licenses/LICENSE-2.0
2. 用户必须在修改后的作品中附带明显的通知声明用户已更改文件并注明更改位置
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
3. 若用户二次分发此作品可以选择向此作品的接收者提供无偿或有偿的担保维修支持服务或其他责任义务但是该用户只可以其自己的名义提供上述内容不得以任何其他贡献者的名义且该用户必须明确表明任何此类责任或义务是由其个人独立提供且其同意并应当承担赔偿此作品的全体贡献者因其个人承担上述责任义务而产生的任何赔偿责任
4. 用户不得删除或更改此作品中包含的任何许可声明包括版权声明专利声明免责声明或赔偿责任限制除非该更改是对已知事实错误的修补或其已获得此作品颁发者的特殊许可或更改者即为此作品颁发者本人
5. 若此作品将权益的声明通知作为一部分那么由用户分发的任何版本的作品中须至少在下列三处之一包含该声明通知的自然人可读副本
- 该作品的权益声明通知中
- 在源形式的文件中当且仅当该作品开放源代码
- 在惯例中作为第三方通知出现之处当且仅当该作品会产生画面且该画面可被自然人详细观察
该通知的内容仅供信息提供不应对许可证进行任何文字上的修改用户可在其分发的作品中在不构成修改本协议的前提下在作品自身的声明通知或属性描述后或作为附录添加
6. 依据本款第3条若用户二次分发此作品时选择向作品的接收者提供收费的担保服务则必须明确告知该接收者本协议全部内容与此作品原出处并确保其知悉上述内容但若用户在二次分发此作品是不选择提供任何服务则该用户不允许向作品的接收者收取任何费用除非该用户获得了此作品颁发者的特殊许可或该用户即为此作品颁发者本人
## 五、提交贡献
除非贡献者明确声明在本作品中由该贡献者向颁发者的提供的提交必须符合本协议的条款并与本协议的条款不存在冲突除非此贡献中与本协议冲突的附加条款已获得颁发者的特殊许可或贡献者即为此作品颁发者本人
## 六、商标相关
本协议并未授予用户将颁发者的商标专属标记或特定产品名称用于合理的或惯例性的描述或此类声明之外其他任何位置的权利
## 七、免责声明
1. 若非因法律要求或经过了特殊准许此作品在根据本协议原样提供的基础上**不予提供任何形式的担保任何明示任何暗示或类似承诺**此类包括但不限于担保此作品毫无缺陷担保此作品适于贩卖担保此作品适于特定目的担保使用此作品绝不侵权用户将自行承担因此作品的质量或性能问题而产生的全部风险若此作品在任何方面欠妥将由用户而非任何贡献者而非任何颁发者承担所有必要的服务维修或除错的任何成本本免责声明本许可的重要组成部分当且仅当遵守本免责声明时本协议的其他条款中对本作品的使用授权方可生效
2. 无论是因何种原因如果不是在法律规定的特殊情况确为贡献者的故意或重大过失下或者经过了特殊准许即使贡献者事先已知发生损害的可能在使用本作品时用户产生的任何直接间接特殊偶然或必然造成的损失包括但不限于商誉损失工作延误计算机系统故障等**均不由任一贡献者承担**
**以上是本许可协议的全部条款**
---
附录
**如何在自己的作品中应用 汉钰律许可协议**
若要在自己源形式的作品应用本协议请在其中附加下面的通知模板并将六角括号中的字段替换成自身的实际信息来替换不包括括号本身这些文本必须以对应文件格式适当的注释句法包含在其中可以是实体的纸质文档也可以是网络公告或者计算机文件或者脱离该源之外另起一个新的文件使之指向要应用本协议的那个作品同时也建议将作品名或类别名以及目的说明之类的声明囊括在同一个可被打印的页面上作为版权通知的整体这样更加容易的区分出第三方内容
若需要在自己以目标形式存在的作品中应用本协议同样需要附加下面的通知模板并更改六角括号中的字样但是这些文本可以是位于作品的标签上位于作品的用户可见且能被自然人详细观察的画面之中或者按照惯例中许可协议应该出现的位置同时这些文本的所处位置应当能够明确指示到本协议应用的那个作品另外建议将作品名或类别名以及目的说明之类的声明囊括在同一个可被打印的位置上作为版权通知的整体这样更加容易的区分出第三方内容
**通知模板**
```
版权所有 © 年份 著作权人
或者版权所有 (C) 年份 著作权人
该作品根据 第一版 汉钰律许可协议本协议授权
任何人皆可从以下地址获得本协议副本本协议副本所在地址
若非因法律要求或经过了特殊准许此作品在根据本协议原样提供的基础上不予提供任何形式的担保任何明示任何暗示或类似承诺也就是说用户将自行承担因此作品的质量或性能问题而产生的全部风险
详细的准许和限制条款请见原协议文本
```

View File

@ -5,11 +5,16 @@
Musicreater(·)
A free open source library used for convert midi file into formats that is suitable for **Minecraft**.
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory
·本项目的协议颁发者为 金羿诸葛亮与八卦阵
The Licensor of Musicreater("this project") is Eilles Wan, bgArray.
本项目根据 第一版 汉钰律许可协议本协议授权
任何人皆可从以下地址获得本协议副本https://gitee.com/EillesWan/YulvLicenses
若非因法律要求或经过了特殊准许此作品在根据本协议原样提供的基础上不予提供任何形式的担保任何明示任何暗示或类似承诺也就是说用户将自行承担因此作品的质量或性能问题而产生的全部风险
详细的准许和限制条款请见原协议文本
"""
# 睿乐组织 开发交流群 861684859

View File

@ -5,8 +5,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory
@ -1041,7 +1041,7 @@ MM_DISLINK_PERCUSSION_INSTRUMENT_TABLE: Dict[int, str] = {
# 金羿ELS 音符方块对照表
MN_EILLES_NOTE_TABLE: Dict[int, str] = {
MN_EILLES_NOTE_BLOCK_TABLE: Dict[int, str] = {
0: "C",
1: "C#",
2: "D",

View File

@ -5,8 +5,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -5,8 +5,8 @@
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -22,8 +22,8 @@
Musicreater (·)
A free open source library used for convert midi file into formats that is suitable for **Minecraft**.
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 ../License.md
Terms & Conditions: ../License.md

View File

@ -7,11 +7,16 @@
Musicreater (·)
A free open source library used for **Minecraft** musics.
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory
·本项目的协议颁发者为 金羿诸葛亮与八卦阵
The Licensor of Musicreater("this project") is Eilles Wan, bgArray.
本项目根据 第一版 汉钰律许可协议本协议授权
任何人皆可从以下地址获得本协议副本https://gitee.com/EillesWan/YulvLicenses
若非因法律要求或经过了特殊准许此作品在根据本协议原样提供的基础上不予提供任何形式的担保任何明示任何暗示或类似承诺也就是说用户将自行承担因此作品的质量或性能问题而产生的全部风险
详细的准许和限制条款请见原协议文本
"""
# 音·创 开发交流群 861684859
@ -368,53 +373,6 @@ class MusicSequence:
if is_sort:
self.channels[channel_no].sort(key=lambda note: note.start_tick)
@staticmethod
def guess_deviation_wasted(
total_note_count: int,
total_instrument_count: int,
note_count_per_instrument: Optional[Dict[str, int]] = None,
qualified_note_count_per_instrument: Optional[Dict[str, int]] = None,
music_channels: Optional[MineNoteChannelType] = None,
) -> float:
"""已废弃"""
if (
note_count_per_instrument is None
or qualified_note_count_per_instrument is None
):
if music_channels is None:
raise ValueError("参数不足,算逑!")
note_count_per_instrument = {}
qualified_note_count_per_instrument = {}
for this_note in [k for j in music_channels.values() for k in j]:
if this_note.sound_name in note_count_per_instrument.keys():
note_count_per_instrument[this_note.sound_name] += 1
qualified_note_count_per_instrument[
this_note.sound_name
] += is_note_in_diapason(this_note)
else:
note_count_per_instrument[this_note.sound_name] = 1
qualified_note_count_per_instrument[this_note.sound_name] = int(
is_note_in_diapason(this_note)
)
return (
sum(
[
(
(
MM_INSTRUMENT_RANGE_TABLE[inst][-1]
* note_count
/ total_note_count
- MM_INSTRUMENT_RANGE_TABLE[inst][-1]
)
* (note_count - qualified_note_count_per_instrument[inst])
)
for inst, note_count in note_count_per_instrument.items()
]
)
/ total_instrument_count
/ total_note_count
)
@staticmethod
def to_music_note_channels(
midi: mido.MidiFile,
@ -999,6 +957,34 @@ class MidiConvert(MusicSequence):
self.progress_bar_command = result
return result
def redefine_execute_format(self, is_old_exe_cmd_using: bool = False):
"""
根据是否使用旧版执行命令格式重新定义执行命令的起始格式
此方法用于处理 Minecraft 中的执行命令的格式差异 Minecraft 的命令系统中
"execute" 命令的用法在不同版本间有所变化此方法允许动态选择使用旧版还是新版
的命令格式以便适应不同的 Minecraft 版本
Parameters
----------
is_old_exe_cmd_using: bool
是否使用旧版执行命令格式
Returns
-------
MidiConvert修改后的实例允许链式调用
"""
# 根据 is_old_exe_cmd_using 的值选择合适的执行命令头格式
self.execute_cmd_head = (
"execute {} ~ ~ ~ " # 旧版执行命令格式
if is_old_exe_cmd_using
else "execute as {} at @s positioned ~ ~ ~ run " # 新版执行命令格式
)
# 返回修改后的实例,支持链式调用
return self
def to_command_list_in_score(
self,
scoreboard_name: str = "mscplay",

View File

@ -2,8 +2,8 @@
"""
存放非音·创本体的附加功能件
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -2,8 +2,8 @@
"""
用以生成附加包的附加功能
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -5,8 +5,8 @@
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -2,8 +2,8 @@
"""
用以生成BDX结构文件的附加功能
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -2,8 +2,8 @@
"""
用以生成单个mcstructure文件的附加功能
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -2,8 +2,8 @@
"""
用以生成Schematic结构的附加功能
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -2,8 +2,8 @@
"""
用以启动WebSocket服务器播放的附加功能
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -5,8 +5,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory
@ -353,152 +353,6 @@ class MineNote:
return self.tuplize() == other.tuplize()
# @dataclass(init=False)
# class SingleNote:
# """存储单个音符的类"""
# instrument: int
# """乐器编号"""
# note: int
# """音符编号"""
# velocity: int
# """力度/响度"""
# start_time: int
# """开始之时 ms"""
# duration: int
# """音符持续时间 ms"""
# track_no: int
# """音符所处的音轨"""
# percussive: bool
# """是否为打击乐器"""
# extra_info: Any
# """你觉得放什么好?"""
# def __init__(
# self,
# instrument: int,
# pitch: int,
# velocity: int,
# startime: int,
# lastime: int,
# is_percussion: bool,
# track_number: int = 0,
# extra_information: Any = None,
# ):
# """用于存储单个音符的类
# :param instrument 乐器编号
# :param pitch 音符编号
# :param velocity 力度/响度
# :param startTime 开始之时(ms)
# 注:此处的时间是用从乐曲开始到当前的毫秒数
# :param lastTime 音符延续时间(ms)"""
# self.instrument: int = instrument
# """乐器编号"""
# self.note: int = pitch
# """音符编号"""
# self.velocity: int = velocity
# """力度/响度"""
# self.start_time: int = startime
# """开始之时 ms"""
# self.duration: int = lastime
# """音符持续时间 ms"""
# self.track_no: int = track_number
# """音符所处的音轨"""
# self.percussive: bool = is_percussion
# """是否为打击乐器"""
# self.extra_info = extra_information
# @property
# def inst(self) -> int:
# """乐器编号"""
# return self.instrument
# @inst.setter
# def inst(self, inst_: int):
# self.instrument = inst_
# @property
# def pitch(self) -> int:
# """音符编号"""
# return self.note
# # @property
# # def get_mc_pitch(self,table: Dict[int, Tuple[str, int]]) -> float:
# # self.mc_sound_ID, _X = inst_to_sould_with_deviation(self.inst,table,"note.bd" if self.percussive else "note.flute",)
# # return -1 if self.percussive else 2 ** ((self.note - 60 - _X) / 12)
# def set_info(self, sth: Any):
# """设置附加信息"""
# self.extra_info = sth
# def __str__(self, is_track: bool = False):
# return "{}Note(Instrument = {}, {}Velocity = {}, StartTime = {}, Duration = {}{})".format(
# "Percussive" if self.percussive else "",
# self.inst,
# "" if self.percussive else "Pitch = {}, ".format(self.pitch),
# self.start_time,
# self.duration,
# ", Track = {}".format(self.track_no) if is_track else "",
# )
# def __tuple__(self):
# return (
# (
# self.percussive,
# self.inst,
# self.velocity,
# self.start_time,
# self.duration,
# self.track_no,
# )
# if self.percussive
# else (
# self.percussive,
# self.inst,
# self.note,
# self.velocity,
# self.start_time,
# self.duration,
# self.track_no,
# )
# )
# def __dict__(self):
# return (
# {
# "Percussive": self.percussive,
# "Instrument": self.inst,
# "Velocity": self.velocity,
# "StartTime": self.start_time,
# "Duration": self.duration,
# "Track": self.track_no,
# }
# if self.percussive
# else {
# "Percussive": self.percussive,
# "Instrument": self.inst,
# "Pitch": self.note,
# "Velocity": self.velocity,
# "StartTime": self.start_time,
# "Duration": self.duration,
# "Track": self.track_no,
# }
# )
# def __eq__(self, other) -> bool:
# if not isinstance(other, self.__class__):
# return False
# return self.__str__() == other.__str__()
@dataclass(init=False)
class MineCommand:
"""存储单个指令的类"""
@ -784,16 +638,6 @@ DEFAULT_PROGRESSBAR_STYLE = ProgressBarStyle(
默认的进度条样式
"""
# NoteChannelType = Mapping[
# int,
# List[SingleNote,],
# ]
# """
# 频道信息类型
# Dict[int,Dict[int,List[SingleNote,],],]
# """
MineNoteChannelType = Mapping[
int,

View File

@ -5,8 +5,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -4,8 +4,8 @@
"""
"""
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 仓库根目录下的 License.md
Terms & Conditions: License.md in the root directory

View File

@ -12,8 +12,8 @@
**_使用时请遵循协议规定_**
- 版权所有 © 2024 · 开发者
- Copyright © 2024 all the developers of Musicreater
- 版权所有 © 2024 金羿 & 诸葛亮与八卦阵
- Copyright © 2024 EillesWan & bgArray
* 开源相关声明请见 仓库根目录下的 License.md
* Terms & Conditions: License.md in the root directory

View File

@ -9,8 +9,8 @@
Musicreater (·)
A free open source library used for convert midi file into formats that is suitable for **Minecraft**.
版权所有 © 2024 · 开发者
Copyright © 2024 all the developers of Musicreater
版权所有 © 2024 金羿 & 诸葛亮与八卦阵
Copyright © 2024 EillesWan & bgArray
开源相关声明请见 ./License.md
Terms & Conditions: ./License.md

View File

@ -13,7 +13,7 @@ with open("README_EN.md", "r", encoding="utf-8") as fh:
setuptools.setup(
name="Musicreater",
version=Musicreater.__version__,
author="Eilles Wan, bgArray",
author="金羿Eilles, bgArray, 鱼旧梦ElapsingDreams",
author_email="TriM-Organization@hotmail.com",
description="一款免费开源的针对《我的世界》音乐的支持库\n"
"A free open-source python library used to convert midi into Minecraft.",

View File

@ -1,3 +1,7 @@
python setup.py sdist bdist_wheel
python -m twine upload dist/*
python -m build
python -m twine check dist/*
pause
python -m twine upload dist/* --verbose
pause
python clean_update.py
pause