async def checkPrice(ctx): msg = ctx.message.content data = fetchSheetsData(MARKET_SPREADSHEET_ID, EVE_ECHOES_MARKET_DUMP_RANGE) query = msg.split(" ", 1) for row in data: if row[1].lower() == query[1].lower(): response = '{}\n Sell: {}\n Buy: {}'.format(row[1], row[3], row[4]) break else: response = "Queried item not found." await ctx.send(response)
async def prices(ctx): data = fetchSheetsData(MARKET_SPREADSHEET_ID, ORE_RANGE) response = 'Purchasing all ore at following prices. Contract any amount to **Lena Forsworn** at the listed price in the following locations: \n **Sakhti VIII - Moon 5 - Ardishapur Family Bureau \n Ziriert VIII - Moon 3 - Zoar and Sons Factory**\n\nOre Prices:\n' for row in data: response = response + '{} {} \n'.format(row[0], row[3]) # data = fetchSheetsData(MARKET_SPREADSHEET_ID, PLANETARY_RANGE) # response = response + '\nAnd the following Planetary Products at the following prices:\n' # for row in data: # response = response + '{} {} \n'.format(row[0], row[2]) await ctx.send(response)
async def checkReprocess(ctx): msg = ctx.message.content data = fetchSheetsData(MARKET_SPREADSHEET_ID, ORE_REPROCESSING_RANGE) ore = msg.split(" ", 2) amount = int(math.floor(float(ore[1]) / 100)) for row in data: if row[0].lower() == ore[2].lower(): response = "Reprocessing {} {} yields:\n".format( amount * 100, row[0]) if len(row) >= 3: if row[2] != "": response = response + "Tritanium: {}\n".format( amount * float(row[2])) if len(row) >= 4: if row[3] != "": response = response + "Pyerite: {}\n".format( amount * float(row[3])) if len(row) >= 5: if row[4] != "": response = response + "Mexallon: {}\n".format( amount * float(row[4])) if len(row) >= 6: if row[5] != "": response = response + "Isogen: {}\n".format( amount * float(row[5])) if len(row) >= 7: if row[6] != "": response = response + "Nocxium: {}\n".format( amount * float(row[6])) if len(row) >= 8: if row[7] != "": response = response + "Zydrine: {}\n".format( amount * float(row[7])) if len(row) >= 9: if row[8] != "": response = response + "Megacyte: {}\n".format( amount * float(row[8])) if len(row) >= 10: if row[9] != "": response = response + "Morphite: {}\n".format( amount * float(row[9])) break else: response = "Queried item not found." await ctx.send(response)
async def salvageMarketPrices(ctx): data = fetchSheetsData(MARKET_SPREADSHEET_ID, SALVAGE_MARKET_RANGE) response = 'List of current market prices for salvaged materials.\n' for row in data: response = response + '{} {} \n'.format(row[0], row[1]) await ctx.send(response)
async def planetaryMarketPrices(ctx): data = fetchSheetsData(MARKET_SPREADSHEET_ID, PLANETARY_MARKET_RANGE) response = 'List of current market prices for planetary products.\n' for row in data: response = response + '{} {} \n'.format(row[0], row[1]) await ctx.send(response)
async def mineralMarketPrices(ctx): data = fetchSheetsData(MARKET_SPREADSHEET_ID, MINERAL_MARKET_RANGE) response = 'List of current market prices for minerals.\n' for row in data: response = response + '{} {} \n'.format(row[0], row[1]) await ctx.send(response)