You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
686 B
Python
23 lines
686 B
Python
3 weeks ago
|
import datetime,os
|
||
|
import log,skel,tcgcore
|
||
|
|
||
|
def tradegen():
|
||
|
if not os.path.isdir("build/trade"):
|
||
|
os.mkdir("build/trade")
|
||
|
if os.path.exists("build/trade/index.html"):
|
||
|
os.remove("build/trade/index.html")
|
||
|
thefile = "build/trade/index.html"
|
||
|
skel.headerwrite(thefile,"trade")
|
||
|
content = open(thefile,"a")
|
||
|
content.write("<h1>available for trade</h1>\n<p>")
|
||
|
for card in tcgcore.ownedcards():
|
||
|
if card[0:4] != "sig_":
|
||
|
if not tcgcore.collecting(card[:-2]):
|
||
|
content.write(tcgcore.printcard(card))
|
||
|
content.write("</p>\n")
|
||
|
content.close()
|
||
|
skel.footerwrite(thefile)
|
||
|
|
||
|
if __name__ == "__main__":
|
||
|
tradegen()
|