Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
textTransform/setting.py
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
37 lines (33 sloc)
1.01 KB
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!C:\pythonCode | |
# -*- coding: utf-8 -*- | |
# @Time : 2023/2/17 01:49 | |
# @Author : Lertoon Wang | |
# @File : setting.py | |
# @Software: PyCharm | |
# Constants | |
import os | |
docxPath = "/Users/kangdiwang/Desktop/脚本样例/序章台本test.docx" | |
fileName = os.path.basename(docxPath).split(".")[0] | |
savePath = os.path.dirname(docxPath) + "/" + fileName + ".txt" | |
headingInfo = "@<|\n" +\ | |
"label(" + "\'" + fileName + "\'" + ", " + "\'" + fileName + "\'" ")\n" +\ | |
"is_start()\n" +\ | |
"|>\n" | |
mediaInfo = "<|\n" +\ | |
"stop(bgm)\n" +\ | |
"set_box()\n" +\ | |
"|>\n" | |
# factor dict for Chinese name reflection | |
GlobalFactorDict = { | |
"立绘左": "pic_left", | |
"立绘中": "pic_center", | |
"立绘右": "pic_right", | |
"立绘左特效": "pic_left_animation", | |
"立绘中特效": "pic_center_animation", | |
"立绘右特效": "pic_right_animation", | |
"场景": "scene", | |
"环境音": "music", | |
"音效": "sound" | |
} | |
if __name__ == '__main__': | |
print(headingInfo + mediaInfo) |