[RenPy] 纯文本查看 复制代码
#笔记本类
class Noterecord:
def __init__(self,day,daynote,daytime):
self.day = day
self.daynote = defaultdict(int)
#增加笔记 notetime:小时:分钟 am/pm
def addnote(self,,day,notetime,intrduce=" "):
for note in daynote:
if notetime not in self.daynote:
self.daynote[notetime] = intrduce
else:
raise Exception('NOTE:note in daynote.')
#删除笔记
def remnote(self,day,notetime):
for note in daynote:
if notetime not in self.daynote:
raise Exception('NOTE:note not in daytime')
else:
self.daynote.pop(notetime)
class Noteitem:
NOTE_ITEM = [
]
@classmethod
def notefrash(cls,intrduce=" "):
if Time.getday() is not None:
default Time.getday() = Noterecord(day=Time.getday())
notename.addnote(day=Time.getday(),intrduce=intrduce,notetime=Time.gettime())
if Time.getday() not in NOTE_ITEM:
NOTE_ITEM.append(noteneme.daynote)
|