From 5b3e69b1b42fd7608822b4b96672202d8402c712 Mon Sep 17 00:00:00 2001 From: Jason Le Long Date: Wed, 7 Mar 2018 17:24:52 +0000 Subject: Alpha 1 --- sassbot/modules/artifact2.py | 54 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 sassbot/modules/artifact2.py (limited to 'sassbot/modules/artifact2.py') diff --git a/sassbot/modules/artifact2.py b/sassbot/modules/artifact2.py new file mode 100644 index 0000000..bddd968 --- /dev/null +++ b/sassbot/modules/artifact2.py @@ -0,0 +1,54 @@ +import sys +import MySQLdb +import random +import math +import re + +sys.path.insert(0, '/home/bouncer/sassbot/modules/artifact2-0/') +import EquipmentCreate + + +def adventurersinc(phenny, input): + #Variables + if input.sender.lower() == "#fromsteamland": + strInputGroup = input.group().split(" ") + try: + strCmd1 = strInputGroup[1] + except: + strCmd1 = "" + try: + strCmd2 = strInputGroup[2] + except: + strCmd2 = "" + + strPlayerState="debug" + parameters = {} + parameters['LiveDB'] = 'Artifact2.0' + parameters['LiveVersion'] = '2.0' + parameters['Nick'] = input.nick + + + #Actions based on player state + if strPlayerState == "newchar": + phenny.say("New Character") + + elif strPlayerState == "rest": + phenny.say("Resting") + + elif strPlayerState == "adventuring": + phenny.say("Exploring") + + elif strPlayerState == "combat": + phenny.say("Combat") + + elif strPlayerState == "debug": + itemCode = input.group(2).split(':') + #phenny.say(str(input.group(2))) + NewItem = EquipmentCreate.GenerateItem(phenny, parameters, itemCode) + phenny.say(NewItem["EquipmentName"]) + +adventurersinc.commands = ['a'] +adventurersinc.priority = 'high' + + +#https://stackoverflow.com/questions/4340793/how-to-find-gaps-in-sequential-numbering-in-mysql \ No newline at end of file -- cgit v1.2.3