mirror of
https://github.com/TriM-Organization/Musicreater.git
synced 2024-11-11 01:27:35 +08:00
基础版本-δ-0.1.0,本地0.5.1
This commit is contained in:
parent
79a2dfb5b1
commit
d3e0f78d2c
3
.idea/.gitignore
vendored
Normal file
3
.idea/.gitignore
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
12
.idea/Musicreater.iml
Normal file
12
.idea/Musicreater.iml
Normal file
@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="PYTHON_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
<component name="PyDocumentationSettings">
|
||||
<option name="format" value="PLAIN" />
|
||||
<option name="myDocStringFormat" value="Plain" />
|
||||
</component>
|
||||
</module>
|
46
.idea/inspectionProfiles/Project_Default.xml
Normal file
46
.idea/inspectionProfiles/Project_Default.xml
Normal file
@ -0,0 +1,46 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<profile version="1.0">
|
||||
<option name="myName" value="Project Default" />
|
||||
<inspection_tool class="LongLine" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyArgumentEqualDefaultInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyAugmentAssignmentInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyClassicStyleClassInspection" enabled="true" level="WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyCompatibilityInspection" enabled="false" level="WARNING" enabled_by_default="false">
|
||||
<option name="ourVersions">
|
||||
<value>
|
||||
<list size="1">
|
||||
<item index="0" class="java.lang.String" itemvalue="3.10" />
|
||||
</list>
|
||||
</value>
|
||||
</option>
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PyMandatoryEncodingInspection" enabled="true" level="WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyMissingTypeHintsInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="PyPep8Inspection" enabled="true" level="WEAK WARNING" enabled_by_default="true">
|
||||
<option name="ignoredErrors">
|
||||
<list>
|
||||
<option value="E501" />
|
||||
</list>
|
||||
</option>
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PyPep8NamingInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true">
|
||||
<option name="ignoredErrors">
|
||||
<list>
|
||||
<option value="N802" />
|
||||
<option value="N803" />
|
||||
<option value="N806" />
|
||||
<option value="N813" />
|
||||
<option value="N801" />
|
||||
</list>
|
||||
</option>
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PyUnresolvedReferencesInspection" enabled="true" level="WARNING" enabled_by_default="true">
|
||||
<option name="ignoredIdentifiers">
|
||||
<list>
|
||||
<option value="list.__getitem__" />
|
||||
<option value="list.split" />
|
||||
</list>
|
||||
</option>
|
||||
</inspection_tool>
|
||||
</profile>
|
||||
</component>
|
6
.idea/inspectionProfiles/profiles_settings.xml
Normal file
6
.idea/inspectionProfiles/profiles_settings.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<settings>
|
||||
<option name="USE_PROJECT_PROFILE" value="false" />
|
||||
<version value="1.0" />
|
||||
</settings>
|
||||
</component>
|
4
.idea/misc.xml
Normal file
4
.idea/misc.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.9" project-jdk-type="Python SDK" />
|
||||
</project>
|
8
.idea/modules.xml
Normal file
8
.idea/modules.xml
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/Musicreater.iml" filepath="$PROJECT_DIR$/.idea/Musicreater.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
6
.idea/vcs.xml
Normal file
6
.idea/vcs.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||
</component>
|
||||
</project>
|
@ -225,15 +225,15 @@ def __main__():
|
||||
print('加载菜单命令...')
|
||||
|
||||
def exitapp():
|
||||
if os.path.isfile("1.pkl"):
|
||||
# os.remove("1.pkl")
|
||||
pass
|
||||
global is_save
|
||||
if is_save is not True:
|
||||
if tkinter.messagebox.askyesno(title=READABLETEXT[1], message=READABLETEXT[106]):
|
||||
SaveProject()
|
||||
log('程序正常退出')
|
||||
|
||||
if os.path.isfile("1.pkl"):
|
||||
os.remove("1.pkl")
|
||||
|
||||
try:
|
||||
global dataset
|
||||
del dataset
|
||||
@ -294,8 +294,14 @@ def __main__():
|
||||
SaveAsNewProject()
|
||||
return
|
||||
else:
|
||||
save_list = [dataset]
|
||||
try:
|
||||
with open("1.pkl", 'rb') as r:
|
||||
save_list.append(pickle.load(r))
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
with open(ProjectName, 'wb') as f:
|
||||
pickle.dump(dataset, f)
|
||||
pickle.dump(save_list, f)
|
||||
tkinter.messagebox.showinfo(title=READABLETEXT[4], message=READABLETEXT[107].format(ProjectName))
|
||||
global is_save
|
||||
is_save = True
|
||||
@ -330,8 +336,15 @@ def __main__():
|
||||
if fn is None or fn == '':
|
||||
return
|
||||
Project_Name = fn
|
||||
save_list = [dataset]
|
||||
try:
|
||||
with open("1.pkl", 'rb') as r:
|
||||
save_list.append(pickle.load(r))
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
print(save_list)
|
||||
with open(Project_Name, 'wb') as f:
|
||||
pickle.dump(dataset[0], f)
|
||||
pickle.dump(save_list, f)
|
||||
tkinter.messagebox.showinfo(title=READABLETEXT[4], message=READABLETEXT[107].format(Project_Name))
|
||||
global is_save
|
||||
is_save = True
|
||||
@ -398,15 +411,28 @@ def __main__():
|
||||
if fn is None or fn == '':
|
||||
return
|
||||
else:
|
||||
# print(fn)
|
||||
fn = fn[0]
|
||||
# print(fn)
|
||||
log("尝试打开:" + fn)
|
||||
try:
|
||||
try:
|
||||
with open(fn, 'rb') as C:
|
||||
dataset[0] = pickle.load(C)
|
||||
except IndexError:
|
||||
global dataset
|
||||
# print(pickle.load(C))
|
||||
read = pickle.load(C) # 重要的事情说三遍!!!pickle.load只能load一次,所以多load几次就有bug,要一次读完!
|
||||
# 重要的事情说三遍!!!pickle.load只能load一次,所以多load几次就有bug,要一次读完!
|
||||
# 重要的事情说三遍!!!pickle.load只能load一次,所以多load几次就有bug,要一次读完!
|
||||
# print(read)
|
||||
dataset = read[0]
|
||||
pkl1 = read[1]
|
||||
log("读取新文件成功")
|
||||
with open("1.pkl", 'wb') as w:
|
||||
pickle.dump(pkl1, w)
|
||||
except KeyError:
|
||||
with open(fn, 'rb') as C:
|
||||
dataset[0] = pickle.load(C)[0]
|
||||
|
||||
dataset[0] = pickle.load(C)
|
||||
log("读取新文件成功")
|
||||
except pickle.UnpicklingError: # 程序规范修改:根据新的语法标准:except后面不能没有错误类型,测试后改为:
|
||||
# pickle.UnpicklingError
|
||||
print(READABLETEXT[8].format(fn))
|
||||
@ -721,8 +747,17 @@ def __main__():
|
||||
if file is None or file == '':
|
||||
log('取消')
|
||||
return
|
||||
from bgArrayLib.sy_resourcesPacker import scatteredPack
|
||||
scatteredPack(file)
|
||||
from bgArrayLib.sy_resourcesPacker import resources_pathSetting
|
||||
result = resources_pathSetting(file)
|
||||
print(result)
|
||||
if result[0] is False:
|
||||
if result[1] == 1:
|
||||
tkinter.messagebox.showerror(title=READABLETEXT[0], message=READABLETEXT[157])
|
||||
if result[1] == 2:
|
||||
tkinter.messagebox.showerror(title=READABLETEXT[0], message=READABLETEXT[158])
|
||||
else:
|
||||
from bgArrayLib.sy_resourcesPacker import scatteredPack
|
||||
scatteredPack(file)
|
||||
import zipfile
|
||||
|
||||
from msctspt.funcOpera import makeNewFunDir
|
||||
@ -745,6 +780,21 @@ def __main__():
|
||||
shutil.move('./manifest.json', './temp/')
|
||||
shutil.rmtree('./temp/')
|
||||
|
||||
def changeResourcesPath():
|
||||
file = tkinter.filedialog.askdirectory(title=READABLETEXT[27], initialdir=r'./')
|
||||
if file is None or file == '':
|
||||
log('取消')
|
||||
return
|
||||
from bgArrayLib.sy_resourcesPacker import resources_pathSetting
|
||||
result = resources_pathSetting(file)
|
||||
print(result)
|
||||
if result[0] is False:
|
||||
if result[1] == 1:
|
||||
tkinter.messagebox.showerror(title=READABLETEXT[0], message=READABLETEXT[157])
|
||||
if result[1] == 2:
|
||||
tkinter.messagebox.showerror(title=READABLETEXT[0], message=READABLETEXT[158])
|
||||
else:
|
||||
tkinter.messagebox.showinfo(title=READABLETEXT[1], message=READABLETEXT[159])
|
||||
|
||||
# 转为空方块世界
|
||||
def ToBlockWorldEpt():
|
||||
@ -1178,8 +1228,9 @@ def __main__():
|
||||
# 窗口部分
|
||||
print('增加窗口元素...')
|
||||
global root
|
||||
global __version__
|
||||
|
||||
root.title(READABLETEXT[41].format(VER[1] + VER[0]))
|
||||
root.title(READABLETEXT[41].format(__version__))
|
||||
root.geometry('900x900') # 像素
|
||||
|
||||
print('完成!')
|
||||
@ -1432,6 +1483,7 @@ def __main__():
|
||||
helpmenu.add_command(label=READABLETEXT[85], command=ClearLog)
|
||||
helpmenu.add_command(label=READABLETEXT[86], command=resetver)
|
||||
helpmenu.add_command(label=READABLETEXT[152], command=end)
|
||||
helpmenu.add_command(label=READABLETEXT[156], command=changeResourcesPath)
|
||||
|
||||
helpmenu.add_separator() # 分隔符
|
||||
|
||||
|
28
README.md
28
README.md
@ -9,7 +9,7 @@
|
||||
|
||||
金羿 (Eilles):主要作者,开发了音·创主体机器前身“函数音乐生成器”、“世界音创”。
|
||||
|
||||
bgArray “诸葛亮与八卦阵”:修复bug,改进代码美观度等。
|
||||
bgArray “诸葛亮与八卦阵”:修复bug,改进代码美观度,增加新功能,更改数据格式等。
|
||||
|
||||
### 软件架构
|
||||
|
||||
@ -64,13 +64,31 @@ python3 Musicreater.py
|
||||
2. 看得懂简体中文字的不一定全会用
|
||||
3. 最好要懂一点点英文
|
||||
|
||||
|
||||
### 诸葛亮与八卦阵的说明(不必要)
|
||||
|
||||
1. 首先!这里的提示是给想使用多音色资源包的人的,如果你想请下载 神羽资源包(神羽自己的链接):https://pan.baidu.com/s/11uoq5zwN7c3rX-98DqVpJg
|
||||
提取码:ek3t
|
||||
2. 下载到你自己电脑上某个位置,注意并不需要放置于本项目下。音色资源包较大,可以选取只下载:
|
||||
`神羽资源包_乐器、音源的资源包\羽音缭绕-midiout_25.0` 这个文件夹。
|
||||
3. 也可以只下载其中的:
|
||||
`神羽资源包_乐器\音源的资源包\羽音缭绕-midiout_25.0\mcpack(国际版推荐)格式_25.0` 或者:
|
||||
`神羽资源包_乐器\音源的资源包\羽音缭绕-midiout_25.0\zip格式_25.0`
|
||||
4. 接下来就是关键了:在音创中绑定资源包
|
||||
5. 首先,先打开音创->帮助与疑问->[神羽资源包位置选择]:选择文件夹... 这时候,
|
||||
会跳出选择框,关键来了,选择:***你的mcpack(国际版推荐)_25.0文件夹或zip格式_25.0文件夹,外面的!文件夹!注意是外面的文件夹!!***
|
||||
举个例子:我的文件路径是这样的:
|
||||
`L:\shenyu\音源的资源包\羽音缭绕-midiout_25.0`这里面有:`神羽资源包_25.0_使用方法.xls`、
|
||||
`mcpack(国际版推荐)格式_25.0`、`zip格式_25.0`两个文件夹和一个.xls文件,而你在音创中
|
||||
也应该选择这个文件夹:**L:\shenyu\音源的资源包\羽音缭绕-midiout_25.0**
|
||||
|
||||
### 致谢
|
||||
|
||||
1. 感谢由 [Fuckcraft](https://github.com/fuckcraft) “鸣凤鸽子”等 带来的我的世界websocket服务器功能
|
||||
2. 感谢 昀梦\<QQ1515399885\> 找出指令生成错误bug并指正
|
||||
3. 感谢由 Charlie_Ping “查理平” 带来的bdx转换功能
|
||||
4. 感谢由 CMA_2401PT 带来的 BDXWorkShop 供本程序对于bdx操作的指导
|
||||
5.
|
||||
5. 感谢由 Miracle Plume “神羽” \<QQshenyu40403\>带来的基岩版资源包
|
||||
6. 感谢广大群友为此程序提供的测试等支持
|
||||
7. 若您对我们有所贡献但您的名字没有显示在此列表中,请联系我!
|
||||
|
||||
@ -79,4 +97,8 @@ python3 Musicreater.py
|
||||
|
||||
1. QQ 2647547478
|
||||
2. 电邮 EillesWan2006@163.com W-YI_DoctorYI@outlook.com EillesWan@outlook.com
|
||||
3. 微信 WYI_DoctorYI
|
||||
3. 微信 WYI_DoctorYI
|
||||
|
||||
### 作者 诸葛亮与八卦阵 联系方式
|
||||
|
||||
1. QQ 4740437765
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
1
bgArrayLib/resourcesPath.rpposi
Normal file
1
bgArrayLib/resourcesPath.rpposi
Normal file
@ -0,0 +1 @@
|
||||
L:/shenyu/音源的资源包/羽音缭绕-midiout_25.0
|
@ -30,10 +30,11 @@ manifest = {
|
||||
def resources_pathSetting(newPath: str = ""):
|
||||
if not os.path.isfile("./bgArrayLib/resourcesPath.rpposi") and newPath == "":
|
||||
return [False, 1] # 1:没有路径文件
|
||||
elif not os.path.isfile("./bgArrayLib/resourcesPath.rpposi") and newPath != "":
|
||||
elif newPath != "": # not os.path.isfile("./bgArrayLib/resourcesPath.rpposi") and
|
||||
path = newPath
|
||||
print(path)
|
||||
with open("./bgArrayLib/resourcesPath.rpposi", 'w') as w:
|
||||
path = w.write(path)
|
||||
w.write(path)
|
||||
if "mcpack(国际版推荐)格式_25.0" in os.listdir(path) and "zip格式_25.0" in os.listdir(path):
|
||||
return [True, path, 1] # 1:都有
|
||||
elif "mcpack(国际版推荐)格式_25.0" in os.listdir(path) and "zip格式_25.0" not in os.listdir(path):
|
||||
@ -42,7 +43,7 @@ def resources_pathSetting(newPath: str = ""):
|
||||
return [True, path, 3] # 3:有zip
|
||||
else:
|
||||
return [False, 2] # 2:路径文件指示错误
|
||||
if os.path.isfile("./bgArrayLib/resourcesPath.rpposi"):
|
||||
if os.path.isfile("./bgArrayLib/resourcesPath.rpposi" and newPath == ""):
|
||||
with open("./bgArrayLib/resourcesPath.rpposi", 'r') as f:
|
||||
path = f.read()
|
||||
if "mcpack(国际版推荐)格式_25.0" in os.listdir(path) and "zip格式_25.0" in os.listdir(path):
|
||||
|
BIN
languages/__pycache__/__init__.cpython-39.pyc
Normal file
BIN
languages/__pycache__/__init__.cpython-39.pyc
Normal file
Binary file not shown.
BIN
languages/__pycache__/lang.cpython-39.pyc
Normal file
BIN
languages/__pycache__/lang.cpython-39.pyc
Normal file
Binary file not shown.
BIN
languages/__pycache__/zhCN.cpython-39.pyc
Normal file
BIN
languages/__pycache__/zhCN.cpython-39.pyc
Normal file
Binary file not shown.
@ -168,5 +168,9 @@ READABLETEXT = {
|
||||
153: "生成新函数包至...",
|
||||
154: "生成新函数附加包文件至...",
|
||||
155: "生成新函数附加包文件,并将神羽资源包以散包形式放置至...",
|
||||
156: "[神羽资源包位置选择]:选择文件夹...",
|
||||
157: "没有路径文件(.rpposi文件),请仔细阅读Readme或先试用:帮助与疑问->[神羽资源包位置选择]:选择文件夹... 方法添加路径文件吧!",
|
||||
158: "有路径文件(.rpposi文件),但路径指示错误,请仔细阅读Readme或先用:帮助与疑问->[神羽资源包位置选择]:选择文件夹... 更改路径!",
|
||||
159: "更改路径文件(.rpposi文件)成功!!"
|
||||
|
||||
}
|
||||
|
BIN
msctspt/__pycache__/__init__.cpython-39.pyc
Normal file
BIN
msctspt/__pycache__/__init__.cpython-39.pyc
Normal file
Binary file not shown.
BIN
msctspt/__pycache__/bugReporter.cpython-39.pyc
Normal file
BIN
msctspt/__pycache__/bugReporter.cpython-39.pyc
Normal file
Binary file not shown.
BIN
msctspt/__pycache__/threadOpera.cpython-39.pyc
Normal file
BIN
msctspt/__pycache__/threadOpera.cpython-39.pyc
Normal file
Binary file not shown.
@ -97,7 +97,7 @@ class version:
|
||||
)
|
||||
"""当前所需库,有一些是开发用的,用户不需要安装"""
|
||||
|
||||
version = ('0.0.1', 'Delta',)
|
||||
version = ('0.1.0', 'Delta',)
|
||||
"""当前版本"""
|
||||
|
||||
def __init__(self) -> None:
|
||||
|
BIN
nmcsup/__pycache__/__init__.cpython-39.pyc
Normal file
BIN
nmcsup/__pycache__/__init__.cpython-39.pyc
Normal file
Binary file not shown.
BIN
nmcsup/__pycache__/const.cpython-39.pyc
Normal file
BIN
nmcsup/__pycache__/const.cpython-39.pyc
Normal file
Binary file not shown.
BIN
nmcsup/__pycache__/log.cpython-39.pyc
Normal file
BIN
nmcsup/__pycache__/log.cpython-39.pyc
Normal file
Binary file not shown.
BIN
nmcsup/__pycache__/nmcreader.cpython-39.pyc
Normal file
BIN
nmcsup/__pycache__/nmcreader.cpython-39.pyc
Normal file
Binary file not shown.
BIN
nmcsup/__pycache__/vers.cpython-39.pyc
Normal file
BIN
nmcsup/__pycache__/vers.cpython-39.pyc
Normal file
Binary file not shown.
@ -30,9 +30,16 @@ Copyright © W-YI 2022
|
||||
|
||||
|
||||
新更新日志
|
||||
Delta 0.1.0
|
||||
2022 1 27
|
||||
1.完成了多音色的支持,但仍需修改
|
||||
|
||||
Delta 0.0.2
|
||||
2022 1 19
|
||||
1.纠正几乎所有语法
|
||||
|
||||
Delta 0.0.1
|
||||
2021 1 3
|
||||
2022 1 3
|
||||
1.新增对翻译字符串的支持
|
||||
2.把所有需要翻译的字符串用双引号字符串表示,其余全是单引号字符串
|
||||
2.2.累死我了,我错了我错了,饶了我吧,以后一定遵守代码规范
|
||||
|
Loading…
Reference in New Issue
Block a user