def run():
	print '--> mission The Hidden Stash'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.openMissionDetail():
		return False

	if not space.lockTarget('img/warehouse.bmp'):
		return False

	if not space.openAfterBurn():
		return False

	if not space.approach():
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.dronesEngage():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	# there are two cargos
	if not space.pickMissionItem():
		return False

	if not space.pickMissionItem():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission The Hidden Stash\n'
	return True
def run():
    print "--> mission Customs lnterdictian (1 of 2)"

    if not station.undock():
        return False

    pilot.autopilot()

    space.warpToMissionLocation()

    # this mission don't have a acceleration gate
    # and will pop up a dialog
    time.sleep(10)
    if space.findClose():
        mouse.leftClick()

    if not space.enableAllLowSlot():
        return False

    if not space.openMissionDetail():
        return False

    time.sleep(10)

    if not space.lockBig():
        return False

    if not space.approach():
        return False

    if not space.openAfterBurn():
        return False

    if not space.launchDrones():
        return False

    if not space.fireOne():
        return False

    if not space.dronesEngage():
        return False

    if not space.missionObjectiveComplete():
        return False

    if not space.dronesReturn():
        return False

    if not space.pickMissionItem():
        return False

    if not space.setMissionWaypoint():
        return False

    pilot.autopilot()

    print "<-- mission Customs lnterdictian (1 of 2)\n"
    return True
def run():
	print '--> mission The Damsel In Distress'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.lockTarget('img/pleasure_hub.bmp'):
		return False

	if not space.approach():
		return False

	if not space.openAfterBurn():
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.dronesEngage():
		return False

	#there are two cargos
	mouse.move(-200, 0)
	if not space.pickMissionItem():
		return False
	if not space.pickMissionItem():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission The Damsel In Distress\n'
	return True
def run():
	print '--> mission Avenge a Fallen Comrade'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.openMissionDetail():
		return False

	if not space.lockTarget('img/habitat.bmp'):
		return False

	if not space.openAfterBurn():
		return False

	if not space.approachFor(60):
		return False

	if not space.lockTarget('img/habitat.bmp'):
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.dronesEngage():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Avenge a Fallen Comrade\n'
	return True
def run():
	print '--> mission Customs lnterdictian (2 of 2)'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.lockBig():
		return False

	if not space.approach():
		return False

	if not space.openAfterBurn():
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.dronesEngage():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if not space.pickMissionItem():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Customs lnterdictian (2 of 2)\n'
	return True
def run():
	print '--> mission The Seven\'s Brothel'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	print 'wait for message'
	time.sleep(10)
	if space.findClose():
		mouse.leftClick()

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.openAfterBurn():
		return False

	if not space.launchDrones():
		return False

	while space.findEnemy():
		mouse.leftClick()
		key.keyPressEx(sc.Lock)
		time.sleep(8)
		space.fireOne()
		time.sleep(15)
		mouse.move(-200, 0)

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission The Seven\'s Brothel\n'
	return True
def run():
	print '--> mission The Sansha Spies'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.openAfterBurn():
		return False

	if not space.launchDrones():
		return False

	while space.findEnemy():
		mouse.leftClick()
		space.approach()
		key.keyPressEx(sc.Lock)
		time.sleep(8)
		space.fireOne()
		time.sleep(15)
		mouse.move(-200, 0)

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission The Sansha Spies\n'
	return True
def run():
	print '--> mission Eliminate the Score'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.launchDrones():
		return False

	while not space.findV():
		if space.findEnemy():
			mouse.leftClick()
			key.keyPressEx(sc.Lock)
			time.sleep(10)
			space.fireOne()
			time.sleep(10)

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Eliminate the Score\n'
	return True
def run():
    print "--> mission Saving A Mans Career"

    if not station.undock():
        return False

    pilot.autopilot()

    if not space.warpToMissionLocation():
        return False

    if not space.enableAllLowSlot():
        return False

    if space.findClose():
        mouse.leftClick()

    if not space.lockTarget("img/sangrel_minn.bmp"):
        return False

    space.openAfterBurn()

    space.approachFor(30)

    if not space.launchDrones():
        return False

    space.fireOne()

    space.dronesEngage()

    if not space.pickMissionItem():
        return False

    if not space.dronesReturn():
        return False

    if space.setMissionWaypoint():
        pilot.autopilot()
    else:
        mouse.leftClick()
        space.exitStartMap()
        space.backToAgentStation()

    print "<-- mission Saving A Mans Career\n"
    return True
def run():
	print '--> mission Technological Secrets (2 of 3)'

	# this is a transport mission
	if not (station.openInventory() \
		and station.loadItem('img/dna_sample.bmp') \
		and station.closeInventory()):
		return False

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.setMissionWaypoint():
		return False
		
	print '<-- mission Technological Secrets (2 of 3)\n'
	return True
def run():
    print "--> mission Eliminate the Pirate Campers"

    if not station.undock():
        return False

    pilot.autopilot()

    if not space.warpToMissionLocation():
        return False

    if not space.enableAllLowSlot():
        return False

    if not space.launchDrones():
        return False

    if not space.openMissionDetail():
        return False

    x = -1
    while x < 0:
        x, y = image.findImgR(panel.Full, "img/close.bmp")
        time.sleep(0.1)
    mouse.moveTo(x, y)
    mouse.leftClick()

    if not space.missionObjectiveComplete():
        return False

    if not space.dronesReturn():
        return False

    if space.setMissionWaypoint():
        pilot.autopilot()
    else:
        mouse.leftClick()
        space.exitStartMap()
        space.backToAgentStation()

    print "<-- mission Eliminate the Pirate Campers\n"
    return True
def run():
	print '--> mission Vigilance'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openAfterBurn():
		return False

	while not space.lockTarget('img/suspicious.bmp'):
		time.sleep(5)

	if not space.launchDrones():
		return False

	if not space.dronesEngage():
		return False

	if not space.pickMissionItem():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Vigilance\n'
	return True
def run():
    print "--> mission Trimming the Fat"

    if not station.undock():
        return False

    pilot.autopilot()

    if not space.warpToMissionLocation():
        return False

    print "wait for message show up"
    time.sleep(8)
    if space.findClose():
        mouse.leftClick()

    if not space.enableAllLowSlot():
        return False

    if not space.launchDrones():
        return False

    if not space.openMissionDetail():
        return False

    if not space.missionObjectiveComplete():
        return False

    if not space.dronesReturn():
        return False

    if space.setMissionWaypoint():
        pilot.autopilot()
    else:
        mouse.leftClick()
        space.exitStartMap()
        space.backToAgentStation()

    print "<-- mission Trimming the Fat\n"
    return True
def run():
	print '--> mission Technological Secrets (3 of 3)'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.launchDrones():
		return False

	if not space.openMissionDetail():
		return False

	while not space.findV():
		# collect
		space.pickWreck()

	if not space.missionObjectiveComplete():
		return False	

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()
		
	print '<-- mission Technological Secrets (3 of 3)\n'
	return True
def run():
	print '--> mission Technological Secrets (1 of 3)'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.launchDrones():
		return False

	if not space.openAfterBurn():
		return False

	if not space.pickMissionItem():
		return False

	if not space.dronesReturn():
		return False

	if not space.setMissionWaypoint():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Technological Secrets (1 of 3)\n'
	return True
def run():
	print '--> mission Gone Berserk'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.launchDrones():
		return False

	if not space.openMissionDetail():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Gone Berserk\n'
	return True
Exemple #17
0
def run():
    # if not inStation():
    #     print 'Error: Must begin at station.'
    #     return False

    print 'mission bot begin. \n'
    while True:

        if not station.startConversation(agent):
            print 'Error: Could not find target agent.'
            return False

        mission = image.extractTextR(panel.MissionName).strip()
        if mission not in bots:
            print 'Skip mission \'' + mission + '\''
            station.declineMission()
            continue
            # if mission in skips:
            #     print 'Skip mission \'' + mission + '\''
            #     station.declineMission()
            #     continue
            # else:
            #     print 'Error: Cant find bot for mission \'' + mission + '\'.'
            #     return False

        bot = bots[mission]

        print 'Mission - ' + mission
        if not station.acceptMission():
            print 'Error: Accept mission failed.'
            return False

        if not space.setMissionWaypoint():
            print 'Error: Cant set mission waypoint.'
            return False

        # # TODO:test
        # bot = saving_a_mans_career

        # # TODO:test
        # mouse.moveToP(panel.middle(panel.Full))
        # mouse.leftClick()

        if not bot.run():
            print 'Error: Mission abort.'
            return False

        if not station.startConversation(agent):
            print 'Error: Could not find target agent.'
            return False

        if not station.completeMission():
            print 'Error: Complete mission failed'
            return False

        if bot == bots['Tenhnalaginal Secrets (2 of 3)']:
            station.undock()
            pilot.autopilot()

        if not space.repair():
            return False

        # TODO
        # break
    return False
def run():
	print '--> mission Unauthorized Military Presence'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.openMissionDetail():
		return False

	if not space.lockTarget('img/blood_raider_personnel.bmp'):
		return False

	if not space.openAfterBurn():
		return False

	if not space.approachFor(90):
		return False

	if not space.lockTarget('img/blood_raider_personnel.bmp'):
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.dronesEngage():
		return False

	# mission item is in wreck
	while not space.findV():
		if space.findEnemy():
			mouse.leftClick()
			space.approach()
			key.keyPressEx(sc.Lock)
			time.sleep(8)
			space.fireOne()
			time.sleep(15)
			mouse.move(-200, 0)
		# collect
		space.pickWreck()

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Unauthorized Military Presence\n'
	return True
def run():
	print '--> mission Mission of Mercy'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	if not space.openMissionDetail():
		return False

	if not space.activateAccelerationGate():
		return False

	if not space.openAfterBurn():
		return False

	# wait for enemy to warp in
	time.sleep(60)

	# establish hate
	if space.findEnemy():
		mouse.leftClick()
		key.keyPressEx(sc.Lock)
		key.keyPressEx(sc.Keep)
		time.sleep(10)
		space.fireOne()
		time.sleep(5)

	if not space.launchDrones():
		return False

	while not space.findV() and space.findEnemy():
		mouse.leftClick()
		key.keyPressEx(sc.Keep)
		key.keyPressEx(sc.Lock)
		time.sleep(10)
		space.fireOne()
		time.sleep(50)
		mouse.move(-200, 0)
		mouse.leftClick()

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Mission of Mercy\n'
	return True
def run():
	print '--> mission Foreign Investment'

	if not station.undock():
		return False

	pilot.autopilot()

	if not space.warpToMissionLocation():
		return False

	if not space.enableAllLowSlot():
		return False

	# there are guards
	if not space.launchDrones():
		return False

	if not space.openMissionDetail():
		return False

	if not space.openAfterBurn():
		return False

	while space.findEnemy():
		mouse.leftClick()
		key.keyPressEx(sc.Lock)
		time.sleep(8)
		space.fireOne()
		time.sleep(15)
		mouse.move(-200, 0)

	if not space.dronesReturn():
		return False

	if not space.activateAccelerationGate():
		return False

	# pocket 1
	mouse.move(-200, 0)
	if not space.lockTarget("img/gallente_company_hq.bmp"):
		return False

	if not space.approach():
		return False

	if not space.launchDrones():
		return False

	if not space.fireOne():
		return False

	if not space.missionObjectiveComplete():
		return False

	if not space.dronesReturn():
		return False

	if space.setMissionWaypoint():
		pilot.autopilot()
	else:
		mouse.leftClick()
		space.exitStartMap()
		space.backToAgentStation()

	print '<-- mission Foreign Investment\n'
	return True