| version 1.1 | | version 1.2 |
|---|
| | |
| # | | # |
| # author:Avion temitchell@sourceforge.net | | # author:Avion temitchell@sourceforge.net |
| | | |
| import CFPython | | import Crossfire |
| import CFGuilds | | import CFGuilds |
| import CFItemBroker | | import CFItemBroker |
| import random | | import random |
| import string | | import string |
| | | |
| activator=CFPython.WhoIsActivator() | | activator=Crossfire.WhoIsActivator() |
| activatorname=CFPython.GetName(activator) | | activatorname=activator.Name |
| whoami=CFPython.WhoAmI() | | whoami=whoami.WhoAmI() |
| | | |
| remarklist = ['Excellent','Thank You','Thank You','Thank You', 'Thank You', 'Great', 'OK', 'Wonderful', 'Swell', 'Dude', 'Big Spender'] | | remarklist = ['Excellent','Thank You','Thank You','Thank You', 'Thank You', 'Great', 'OK', 'Wonderful', 'Swell', 'Dude', 'Big Spender'] |
| exclaimlist = ['Hey','Hey','Hey','Hey', 'Now just a minute', 'AHEM', 'OK...Wait a minute', 'Look chowderhead'] | | exclaimlist = ['Hey','Hey','Hey','Hey', 'Now just a minute', 'AHEM', 'OK...Wait a minute', 'Look chowderhead'] |
| buddylist = ['buddy','buddy','buddy','buddy','pal','friend','friend','friend','friend','dude','chum', 'sweetie'] | | buddylist = ['buddy','buddy','buddy','buddy','pal','friend','friend','friend','friend','dude','chum', 'sweetie'] |
| | | |
| guildname=CFPython.GetEventOptions(whoami,6) # 6 is say event | | guildname=Crossfire.ScriptParameters() # 6 is say event |
| text = string.split(CFPython.WhatIsMessage()) | | text = string.split(Crossfire.WhatIsMessage()) |
| | | |
| if (guildname): | | if (guildname): |
| guild = CFGuilds.CFGuild(guildname) | | guild = CFGuilds.CFGuild(guildname) |
| cointype = "imperial" #What type of token are we using for guild dues? | | cointype = "imperial" #What type of token are we using for guild dues? |
| object = CFPython.CheckInventory(activator,cointype) | | object = activator.CheckInventory(cointype) |
| | | |
| if text[0] == 'help' or text[0] == 'yes': | | if text[0] == 'help' or text[0] == 'yes': |
| message='Let me know how many %s you want to pay. Say pay <amount>' %cointype | | message='Let me know how many %s you want to pay. Say pay <amount>' %cointype |
| | |
| message = "How much ya wanna pay %s?" %(random.choice(buddylist)) | | message = "How much ya wanna pay %s?" %(random.choice(buddylist)) |
| else: | | else: |
| message = "Howdy %s, paying some guild dues today?" %(random.choice(buddylist)) | | message = "Howdy %s, paying some guild dues today?" %(random.choice(buddylist)) |
| CFPython.Say(whoami, message) | | whoami.Say(message) |
| else: | | else: |
| CFPython.Write('Guildname Error, please notify a DM', activator) | | activator.Write('Guildname Error, please notify a DM') |