diff --git a/sel.wav b/sel.wav new file mode 100644 index 0000000..d7d32f3 Binary files /dev/null and b/sel.wav differ diff --git a/点名器.pyw b/点名器.pyw index 95b4542..f758f82 100644 --- a/点名器.pyw +++ b/点名器.pyw @@ -4,6 +4,7 @@ import tkinter.messagebox as msgbox import random import sys import win32con, win32api +import winsound gui_size = "620x200" @@ -31,6 +32,7 @@ up_percent = 30 down_persent = 40 filename = "names.xls" configname = "config.data" +selname = "sel.wav" elim_rows = 1 percent_override = True @@ -173,6 +175,7 @@ def choose(): class_label.config(text = choice.class_name) subject_label.config(text = choice.subject) last_choice = choice.name + winsound.PlaySound(selname, winsound.SND_ASYNC | winsound.SND_FILENAME) startrandom = Button(gui, text = "立刻摇人!", font = ("宋体", 17, "bold"), height = 2, fg = "red", command = choose, bg = "white")