def TerminalATK(flag, quest=False): if not quest: if useSI: Terminal.SetCheckBox("Skill Injection", flag) else: Terminal.SetCheckBox("Auto Attack", flag) else: Terminal.SetCheckBox("Skill Injection", False) Terminal.SetCheckBox("General FMA", False) Terminal.SetCheckBox("Full Map Attack", False) Terminal.SetCheckBox("Melee No Delay", False) Terminal.SetCheckBox("Auto Attack", flag) if useKami: Terminal.SetCheckBox("Kami Vac", flag) elif useFallLegit: Terminal.SetCheckBox("Legit Vac", flag) Terminal.SetCheckBox("Mob Falldown", flag) if flag: _left = Field.GetRect().left _right = Field.GetRect().right _mid = (_left + _right) / 2 if not (_mid - 10 < Character.GetPos().x < _mid + 10): Character.AMoveX(int(_mid)) time.sleep(walkTime)
def toRope(self): pos = Character.GetPos() while pos.x not in range(self.x - 75, self.x + 75): Character.AMoveX(self.x) pos = Character.GetPos() storedY = pos.y Character.StopMove() time.sleep(0.4) Character.AMoveX(self.x) Character.Jump() time.sleep(0.1) #NOT SURE IF NEEDED while pos.y > self.platform.y: Character.StopMove() Character.AMoveY(self.platform.y) pos = Character.GetPos() if pos.y == storedY: self.toRope() return Character.StopMove()
def Mine(vein): pos = Character.GetPos() while pos.x < (vein.x - 50) or pos.x > (vein.x + 50): Character.AMoveX(vein.x) pos = Character.GetPos() Character.StopMove() print("Pressing mining key") time.sleep(.25) Key.Press(0x20) time.sleep(.1) Key.Press(0x20) time.sleep(.1) Key.Press(0x20) time.sleep(4)
def KillHorntail(bossDifficulty): SCLib.PersistVar("HasSpawned", False) SCLib.PersistVar("NowLockedVar", False) HasSpawned = SCLib.GetVar("HasSpawned") NowLockedVar = SCLib.GetVar("NowLockedVar") SCLib.StartVars() if bossDifficulty == 0: HorntailEasy = True HorntailNormal = False HorntailChaos = False elif bossDifficulty == 1: HorntailEasy = False HorntailNormal = True HorntailChaos = False else: HorntailEasy = False HorntailNormal = False HorntailChaos = True HorntailPreQuest = Quest.GetQuestState(7313) if HorntailPreQuest == 0: print( "Horntail Prequest not started or done, Starting quest before entery" ) if Field.GetID() != CaveOfLifeEntrance1: Terminal.Rush(CaveOfLifeEntrance1) else: Quest.StartQuest(7313, 2081006) print("Horntail Prequest started") else: #ToggleKami(False) print("Doing Horntail") if HorntailEasy: print("Easy") if Field.GetID() != HorntailsCaveEasy: if Field.GetID() != TheCaveOfTrialEasy2: if Field.GetID() != TheCaveOfTrialEasy1: if Field.GetID() != EntranceToHorntailsCave: GotoHorntail() else: if not NowLockedVar: Npc.ClearSelection() Npc.RegisterSelection( "Easy Mode (Level 130 or above)") time.sleep(1) Character.TalkToNpc(2083004) time.sleep(1) else: print( "Seems like you diddnt finish your last attempt and are locked. Continueing other bosses" ) SCLib.UpdateVar("KillHorntail", False) ResetNowLockedFunction() else: NowLockedFunction() boss = Field.FindMob(HorntailsLeftHeadEasy) if boss.valid: ToggleKami(False) if Character.GetPos().x != 522: Character.Teleport(522, -40) print("Horntails left head still alive standby") else: ToggleFaceLeft(True) ToggleKami(False) if Character.GetPos().x != 840: Character.Teleport(840, -165) else: Character.EnterPortal() else: boss = Field.FindMob(HorntailsRightHeadEasy) if boss.valid: ToggleKami(False) ToggleAttack(True) if Character.GetPos().x != 9: Character.Teleport(9, -40) print("Horntails right head still alive standby") else: ToggleFaceLeft(False) ToggleKami(False) if Character.GetPos().x != -307: Character.Teleport(-307, -165) else: Character.EnterPortal() else: boss = Field.FindMob(EasyHorntail) if boss.valid: ToggleAttack(True) DidSpawn() ToggleKami(True) print("Horntail still alive Standby") else: if HasSpawned: ToggleKami(False) ToggleLoot(True) print( "Horntail Easy Is dead waiting 10 sec before continueing" ) time.sleep(10) Character.TalkToNpc(2083002) time.sleep(1) SCLib.UpdateVar("KillHorntail", False) ToggleLoot(False) ResetSpawn() ResetNowLockedFunction() else: ToggleKami(False) ToggleAttack(False) crystal = Field.FindReactor(2401300) if crystal.valid: if Character.GetPos().x != 540: Character.Teleport(540, 15) else: Character.BasicAttack() time.sleep(2) elif HorntailNormal: print("Normal") if Field.GetID() not in HorntailsCaveNormal: if Field.GetID() not in TheCaveOfTrialNormal2: if Field.GetID() not in TheCaveOfTrialNormal1: if Field.GetID() != EntranceToHorntailsCave: GotoHorntail() else: if not NowLockedVar: Npc.ClearSelection() Npc.RegisterSelection( "Normal Mode (Level 130 or above)") time.sleep(1) Character.TalkToNpc(2083004) time.sleep(1) else: print( "Seems like you diddnt finish your last attempt and are locked. Continueing other bosses" ) SCLib.UpdateVar("KillHorntail", False) ResetNowLockedFunction() else: NowLockedFunction() boss = Field.FindMob(HorntailsLeftHeadNormal) if boss.valid: ToggleKami(False) ToggleAttack(True) if Character.GetPos().x != 522: Character.Teleport(522, -40) print("Horntails left head still alive standby") else: ToggleFaceLeft(True) ToggleKami(False) if Character.GetPos().x != 840: Character.Teleport(840, -165) else: Character.EnterPortal() else: boss = Field.FindMob(HorntailsRightHeadNormal) if boss.valid: ToggleKami(False) if Character.GetPos().x != 9: Character.Teleport(9, -40) print("Horntails right head still alive standby") else: ToggleFaceLeft(False) ToggleKami(False) if Character.GetPos().x != -307: Character.Teleport(-307, -165) else: Character.EnterPortal() else: boss = Field.FindMob(NormalHorntail) if boss.valid: ToggleAttack(True) ToggleKami(True) DidSpawn() print("Horntail Normal still alive Standby") else: if HasSpawned: ToggleKami(False) ToggleLoot(True) print( "Horntail Normal Is dead waiting 10 sec before continueing" ) time.sleep(10) Character.TalkToNpc(2083002) time.sleep(1) ToggleLoot(False) SCLib.UpdateVar("KillHorntail", False) ResetSpawn() ResetNowLockedFunction() else: ToggleAttack(False) ToggleKami(False) crystal = Field.FindReactor(2401000) if crystal.valid: if Character.GetPos().x != 540: Character.Teleport(540, 15) else: Character.BasicAttack() time.sleep(2) elif HorntailChaos: print("Chaos") if Field.GetID() not in ChaosHorntailsCave: if Field.GetID() not in TheCaveOfTrialChaos2: if Field.GetID() not in TheCaveOfTrialChaos1: if Field.GetID() != EntranceToHorntailsCave: GotoHorntail() else: if not NowLockedVar: Npc.ClearSelection() Npc.RegisterSelection( "Chaos Mode (Level 135 or above)") time.sleep(1) Character.TalkToNpc(2083004) time.sleep(1) else: print( "Seems like you diddnt finish your last attempt and are locked. Continueing other bosses" ) SCLib.UpdateVar("KillHorntail", False) ResetNowLockedFunction() else: NowLockedFunction() boss = Field.FindMob(ChaosHorntailsLeftHead) if boss.valid: ToggleKami(False) ToggleAttack(True) while Character.GetPos().x not in range(500, 570): Character.AMoveX(522) print("Horntails left head still alive standby") else: ToggleFaceLeft(True) ToggleKami(False) if Character.GetPos().x != 840: Character.Teleport(840, -165) else: Character.EnterPortal() else: boss = Field.FindMob(ChaosHorntailsRightHead) if boss.valid: ToggleKami(False) ToggleAttack(True) while Character.GetPos().x not in range(-40, 40): Character.AMoveX(9) print("Horntails right head still alive standby") else: ToggleFaceLeft(False) ToggleKami(False) if Character.GetPos().x != -307: Character.Teleport(-307, -165) else: Character.EnterPortal() else: boss = Field.FindMob(ChaosHorntail) boss1 = Field.FindMob(ChaosHorntail1) boss2 = Field.FindMob(ChaosHorntail2) boss3 = Field.FindMob(ChaosHorntail3) boss4 = Field.FindMob(ChaosHorntail4) if boss.valid or boss1.valid or boss2.valid or boss3.valid or boss4.valid: ToggleAttack(True) #ToggleKami(True) DidSpawn() while Character.GetPos().x not in range(140, 220): Character.AMoveX(183) print("Horntail still alive, Standby") else: if HasSpawned: ToggleKami(False) ToggleLoot(False) #print("Horntail Is dead waiting 10 sec before continueing") print("Looting") Terminal.SetCheckBox("Auto Loot", True) MoveToXLocation(Field.GetRect().left) time.sleep(1.5) MoveToXLocation(Field.GetRect().right) time.sleep(1.5) MoveToXLocation(Field.GetRect().left) time.sleep(1.5) MoveToXLocation(Field.GetRect().right) time.sleep(1.5) MoveToXLocation(Field.GetRect().left) time.sleep(1.5) #time.sleep(10) Character.TalkToNpc(2083002) time.sleep(1) SCLib.UpdateVar("KillHorntail", False) ToggleLoot(False) ResetSpawn() ResetNowLockedFunction() else: ToggleAttack(False) ToggleKami(False) crystal = Field.FindReactor(2401100) if crystal.valid: if Character.GetPos().x != 540: Character.Teleport(540, 15) else: Character.BasicAttack() time.sleep(2)
def MoveToXLocation(xPos): while Character.GetPos().x not in range(xPos - 60, xPos + 60): Character.AMoveX(xPos)
MovementSend = 0x00D5 delay = 0.01 def grabObjectID(): iPacket = Packet.WaitForRecv(ReactorRecv, 10000) if iPacket.GetRemaining() > 0: objectID = iPacket.ReadLong(4) Terminal.SetProperty(str(GameState.GetChannel()), objectID) def blubBlub(): oPacket = Packet.COutPacket(ReactorSend) oPacket.Encode4(Terminal.GetProperty(str(GameState.GetChannel()), 0)) oPacket.Encode4(2) oPacket.Encode2(0x106) oPacket.Encode4(0) Packet.SendPacket(oPacket) while GameState.IsInGame(): if Field.GetID() == 230040420: if Terminal.GetProperty(str(GameState.GetChannel()), 0) == 0: Terminal.SetCheckBox("Jump Down Anywhere", True) if Character.GetPos().y <= 78: Character.JumpDown() time.sleep(2) Character.JumpDown() grabObjectID() else: blubBlub() time.sleep(delay) Character.AMoveX(-491)
if fieldID != 865010200: Terminal.Rush(865010200) else: Quest.StartQuest(17613, 9390201) elif quest9 == 1: if Quest.CheckCompleteDemand(17613, 9390241) == 0: if fieldID not in [865010200, 865090001]: Terminal.Rush(865010200) else: Quest.CompleteQuest(17613, 9390241) else: if fieldID not in [865010200, 865090001]: Terminal.Rush(865010200) else: if fieldID == 865010200: Character.AMoveX(851) # Completing [Commerci Republic] Ciao, Until Next Time elif quest10 != 2: if quest10 == 0: if fieldID != 865010200: Terminal.Rush(865010200) else: Quest.StartQuest(17614, 9390241) elif quest10 == 1: if fieldID != 865000000: Terminal.Rush(865000000) # Completing [Commerci] Get Rich Quick elif quest11 != 2: if quest11 == 0:
# magnus lobby room Party.CreateParty() Character.Teleport(1801, -1450) time.sleep(2) Npc.ClearSelection() Npc.RegisterSelection("Enter the Tyrant's Throne") Character.EnterPortal() time.sleep(2) elif currentMap >= 401060300 and currentMap <= 401060398: # tyrant's room print("in tyrant's room") #Terminal.SetCheckBox("Kami Vac",True) while Character.GetPos().x not in range( 1400, 1600): Character.AMoveX(1525) else: if currentMap != 401000002: Terminal.Rush(401000002) print("Using return scroll") Inventory.UseItem(2030000) time.sleep(2) Terminal.Rush(401000000) elif Quest.CheckCompleteDemand(1463, 1540943) == 0: if currentMap >= 401060300 and currentMap <= 401060398: print("teleporting out of tyrant's room") Terminal.SetCheckBox("Kami Vac", False) Character.Teleport(592, -1347) time.sleep(2)