Adventure bot improvements

Adjusted max pulse count for bots from 50 -> 75
Adjusted max skill baseline by +4 for adventure bots to 69
Added 500 lines of unique
Added 45000 bot names
Added recovery methods for bots that get stuck
Added multiple random number functions to help add more variance
Added function to handle checking if a bot is near/in a Bank
Added function to handle getting a new city
Added function to add variability to locations given to bots
Added function to check if other players/bots are nearby
Added function to handle bots banking their inventories if a bank booth is nearby
Improved random number parameters
Improved how bots are spawned & added variance to spawn location
Improved how bots interact & handle the Grand Exchange location
Improved how bots handle starting in Lumbridge
Fixed bots referencing themselves in dialogue
Fixed bots talking when they are by themselves
Fixed multiple cases where bots would get stuck in a state
Fixed multiple logic errors
Fixed issues with bots banking but not switching states
This commit is contained in:
Player Name 2024-10-10 07:08:57 +00:00 committed by Ryan
parent 034c05f512
commit 59075798ea
7 changed files with 33854 additions and 270 deletions

View file

@ -301,7 +301,7 @@
"Always check announcments",
"We thrivin",
"Ship @name",
"Dont forget to vote 2009Scape!",
"Dont forget to vote 2009scape!",
"Kermit is too legit 2 quit",
"Out here on the range we are having fun",
"I am hank steel",
@ -367,33 +367,16 @@
"May Guthix bring you balance.",
"May Guthix bring you balance.",
"May Guthix bring you balance.",
"Thy death was not in vain, for it brought some balance to the world. May Guthix bring you rest.",
"May you walk the path, and never fall, for Guthix walks beside thee on thy journey. May Guthix bring you peace.",
"All things must end, as all begin; Only Guthix knows the role thou must play. May Guthix bring you balance.",
"In life, in death, in joy, in sorrow: May thine experience show thee balance. May Guthix bring you balance.",
"Thou must do as thou must, no matter what. Thine actions bring balance to this world. May Guthix bring you balance.",
"The river flows, the sun ignites, May you stand with Guthix in thy fights. May Guthix bring you balance.",
"A journey of a single step, May take thee over a thousand miles. May Guthix bring you balance.",
"Zamorak give me strength!",
"Zamorak give me strength!",
"Zamorak give me strength!",
"May your bloodthirst never be sated, and may all your battles be glorious. Zamorak bring you strength.",
"There is no opinion that cannot be proven true...by crushing those who choose to disagree with it. Zamorak give me strength!",
"Battles are not lost and won; They simply remove the weak from the equation. Zamorak give me strength!",
"Those who fight, then run away, shame Zamorak with their cowardice. Zamorak give me strength!",
"Battle is by those who choose to disagree with it. Zamorak give me strength!",
"Strike fast, strike hard, strike true: The strength of Zamorak will be with you. Zamorak give me strength!",
"The weak deserve to die, so the strong may flourish. This is the creed of Zamorak.",
"This is Saradomin's wisdom.",
"This is Saradomin's wisdom.",
"This is Saradomin's wisdom.",
"Go in peace in the name of Saradomin; may his glory shine upon you like the sun.",
"Thy cause was false, thy skills did lack; See you in Lumbridge when you get back.",
"Protect your self, protect your friends. Mine is the glory that never ends. This is Saradomin's wisdom.",
"The darkness in life may be avoided, by the light of wisdom shining. This is Saradomin's wisdom.",
"Show love to your friends, and mercy to your enemies, and know that the wisdom of Saradomin will follow. This is Saradomin's wisdom.",
"A fight begun, when the cause is just, will prevail over all others. This is Saradomin's wisdom.",
"The currency of goodness is honour; It retains its value through scarcity. This is Saradomin's wisdom.",
"For Camelot!",
"Firmly grasp it!",
"My legs!",
@ -496,21 +479,525 @@
"Shlisshalpshlaap",
"Somebody call for an exterminator?",
"Decisive action. Should work.",
"R E A D Y T O R A I S E S O M E H E L L",
"Darkness overpowering.",
"Got any questions about propane? Or propane accessories?",
"When someone asks me if I am a god, I say Y E S!!!",
"You run out of Marines?",
"Goliath Online",
"I'm escaping to the one place that hasn't been corrupted by Capitalism. Lunar Isle!",
"Selling wildy protection, 100k gp",
"Can't we get you on Mastermind, @name? Next contestant - @name from Lumbridge. Special subject - the bleedin' obvious.",
"Oh, you're German! I'm sorry, I thought there was something wrong with you.",
"Can't we get you on Mastermind, @name?",
"Listen, don't mention the war! I mentioned it once, but I think I got away with it all right.",
"Cunnilingus and psychiatry brought us to this.",
"Oh, poor baby. What do you want, a Brimstail's Sampler?",
"There's an old TzHarrian saying, you fuck up once, you lose two teeth.",
"The lineup consisted simply of six hydrocoptic marzelvanes so fitted to the ambifacient lunar waneshaft that sidefumbling was prevented."
"Ah, the Wilderness... where dreams of riches meet a swift demise.",
"Who needs a quest guide? I've got the whole wiki memorized.",
"Buying GF 10k coins. Must have at least 70 Agility.",
"I swear, the goblins in Goblin Village have it out for me.",
"Why do wizards always hang out in towers? Is it a zoning thing?",
"I'm training my Construction skill. My house is gonna be lit!",
"The GE is like the stock market, but with dragon bones.",
"Why do we need a cabbage patch in Draynor? Seriously.",
"I've been mining rune essence for hours. My pickaxe hates me.",
"@name hit 99 Cooking. Time to open a gourmet restaurant in Varrock.",
"I'm convinced the @name is actually a time-traveling wizard.",
"Anyone up for a Castle Wars match? I need that decorative armor.",
"Accidentally clicked Attack on a guard. Now I'm a wanted criminal.",
"Why do we even have a Duel Arena? It's just a fancy boxing ring.",
"I've got a stack of burnt lobsters. Anyone want to buy them?",
"Greetings, @name! Looking for a quest?",
"Just got a rare drop! The RNG gods are smiling upon me!",
"Anyone need help with a boss fight? I've got my dragon dagger ready.",
"Buying feathers! Will pay top price!",
"The Lumbridge cows are my favorite training spot.",
"Who needs a teleport? I've got my magic runes stocked.",
"@name hit 99 Woodcutting. Time to chop some yews!",
"Anyone seen the Wise Old Man lately? I owe him a visit.",
"Selling lobsters! Freshly caught from Catherby.",
"Swear, the Wilderness is scarier than my nightmares.",
"Looking for a clan to join. Any takers?",
"I'm an ironman, so no trading for me!",
"Anyone up for a Castle Wars match?",
"The Grand Exchange prices are crashing. Panic sell!",
"Who else remembers the Falador Massacre?",
"I'm saving up for a party hat. Wish me luck!",
"Barrows runs are my addiction. Those crypts are spooky.",
"I'm convinced the Wise Old Man is secretly Zamorak.",
"I'm a completionist, so I'm grinding out all the achievements.",
"The music in this game is surprisingly epic.",
"Tried to trade with a tree... It didn't go well.",
"My bank is like a black hole. Items disappear forever.",
"I'm convinced the Wise Old Man is just a confused tourist.",
"My character's fashion sense? Let's just say it's 'unique.'",
"Challenged a cow to a dance-off. It won.",
"Why does the Lumbridge Guide always look so lost?",
"I'm training Agility, but my real-life agility is zero.",
"Tried to fish in the desert. Sandfish are elusive.",
"The Grand Exchange is like a chaotic stock market.",
"I'm a master at clicking 'Continue' during quests.",
"I'm convinced the chickens are plotting world domination.",
"I'm a woodcutter, but I've never seen a talking tree.",
"I'm a vegetarian, except when it comes to killing dragons.",
"Why do wizards wear pointy hats? Is it a fashion statement?",
"Challenged a guard to a staring contest. He won.",
"I'm collecting cabbage. It's a noble pursuit.",
"Accidentally set my cat on fire. It's now a firecat.",
"I'm convinced the Wise Old Man is secretly a time traveler.",
"I'm a quest completionist, but I still can't find my keys.",
"I'm convinced the ducks are spying on us.",
"I'm a pro at avoiding the Lumbridge swamp. Too many frogs.",
"Hey, can someone lend me 10k? I promise I'll pay it back... eventually.",
"Why do I always find the one square where the random event spawns?",
"I'm training Prayer by burying bones. It's like a spiritual workout.",
"The Wise Old Man's fashion sense is questionable.",
"I'm convinced the ducks are secretly plotting world domination.",
"Why do wizards wear pointy hats? Is it a dress code?",
"I'm collecting cabbage. It's a noble pursuit, really.",
"I'm a vegetarian, except when it comes to killing dragons.",
"Why does the Lumbridge Guide always look so lost?",
"Training Agility, but my real-life agility is zero.",
"I'm convinced the Wise Old Man is secretly a time traveler.",
"Tried to mine air. It's an untapped resource.",
"I'm a quest completionist, but I still can't find my keys.",
"Challenged a guard to a staring contest. He won.",
"I'm saving up for a party hat. Priorities, you know?",
"Why do goblins drop coins? Do they moonlight as accountants?",
"I'm convinced the chickens are plotting something.",
"Clicked 'Attack' on a chicken. Now I'm a poultry murderer.",
"My character's fashion sense? Let's just say it's 'unique.'",
"Do you know where I can find the entrance to the Taverley Dungeon?",
"Hey, anyone here familiar with the Barrows? I need some tips.",
"Is there a bank nearby? My inventory is overflowing with loot",
"I'm clueless about clue scrolls",
"Where's the best spot to catch sharks? I'm aiming for 99 Fishing.",
"Is there a shortcut to the Karamja Volcano?",
"Can someone explain the mechanics of the Jad fight in the Fight Caves?",
"I'm stuck on the Elemental Workshop quest. Any hints?",
"Where can I find a loom to spin flax into bowstrings?",
"What's the best gear setup for killing dragons? I want that visage drop!",
"I'm trying to unlock the fairy rings",
"How do I recharge my amulet of glory?",
"Why do goblins drop coins?",
"The Grand Exchange is like the stock market",
"My real-life agility is more like a lumbering tortoise.",
"The Wise Old Man's fashion sense is like Woahs",
"I challenged a cow to a dance off, surprisingly smooth mooves.",
"Why does the Lumbridge Guide always look lost?",
"I'm convinced the ducks in Lumbridge are plotting world domination!",
"I accidentally ate my prayer potion I'm blessed with heartburn",
"I'm a vegetarian, except when it comes to slaying dragons.",
"Why do wizards wear pointy hats? Is it a magical dress code?",
"I'm a quest completionist, but I still can't find my keys in real life.",
"I challenged a guard to a staring contest. He won.",
"I'm saving up for a party hat. Priorities, ya know?",
"What's the deal with the Wilderness?",
"I'm convinced the chickens are secretly plotting world domination!",
"Accidentally clicked 'Attack' on a guard. Now I'm on a watchlist.",
"My character's fashion sense? Let's just say it's 'unique'",
"Lobsters heal my soul",
"Trimmed armor or bust!",
"Wilderness: Where friendships go to die",
"Buying gf 10k",
"Dancing for coins at Lumbridge",
"Wearing full rune like a boss",
"Teleporting to Camelot for quests",
"Fishing for hours at Catherby",
"PKing with a rune 2h",
"World 1 Falador Park parties",
"Staking my bank at the Duel Arena",
"Dying to Elvarg's fiery breath sums up my life",
"Got the Quest cape finally on my main!",
"Wearing a party hat with pride",
"Castle Wars: Red vs Blue",
"Trading in Varrock Square",
"Barrows runs for that sweet loot",
"Spending hours in Pest Control is life",
"Killing cows for leather armor is a good start",
"Farming herbs in Ardougne can be good money",
"Clan chat drama LOL",
"Mining rune essence endlessly",
"Agility courses: A love-hate relationship",
"Dueling for honor.... and GP",
"Buying runes from Aubury is decent money",
"Chasing the Easter Bunny like a scam",
"Wearing a skillcape with pride",
"Fletching yew longbows for profit",
"Going to implings in Puro-Puro",
"Castle Wars barricade wars",
"Dropping party hats at drop parties like pennies",
"Killing lesser demons in Karamja is part of my holy conquest",
"@name lures noobs into the Wilderness",
"Farming ranarrs for cash",
"Getting lost in the Underground Pass",
"Selling coal at the Grand Exchange",
"Fighting the Kalphite Queen",
"Picking flax in Seers' Village",
"Begging for free stuff in Lumbridge",
"Smithing rune platebodies for profit",
"Logging out in Lumbridge Castle",
"Hey @name, how do I get to the Grand Exchange?",
"Veteran here! @name, what's your favorite quest?",
"@name, how do I make money fast?",
"Hey @name, what's the best combat style for bossing?",
"@name, always carry an emergency teleport!",
"New player here! @name, what's the Wilderness like?",
"Hey @name, how do I join a clan?",
"@name, prioritize Prayer levels!",
"@name, what's the best way to train Agility?",
"Hey @name, what's your favorite minigame?",
"@name, never trust a PKer in Lumbridge!",
"@name, how do I get a fire cape?",
"Hey @name, what's the fastest way to level up Magic?",
"@name, try the Barrows tunnels!",
"@name, what's the deal with Pest Control?",
"Hey @name, how do I unlock the Fairy Rings?",
"@name, remember the old random events?",
"@name, should I train Strength or Attack first?",
"Hey @name, what's your favorite skillcape?",
"@name, can't do the Fight Caves!",
"@name, how do I get a pet?",
"Hey @name, what's the best food for boss fights?",
"@name, Castle Wars or Clan Wars?",
"@name, what's a clue scroll?",
"Hey @name, how do I defeat Jad?",
"@name, use Protect from Melee at KBD!",
"@name, should I train Ranged or Magic?",
"Hey @name, what's the best way to level up Crafting?",
"@name, don't forget your anti-dragon shield!",
"@name, what's the Stronghold of Security?",
"Hey @name, how do I access the Legends' Guild?",
"@name, remember the old PvP worlds?",
"@name, how do I get a dragon defender?",
"Hey @name, what's the best way to level up Herblore?",
"@name, always carry a charged amulet of glory!",
"@name, should I train Fishing or Cooking?",
"Hey @name, how do I defeat the Chaos Elemental?",
"@name, try the TzHaar Fight Pit!",
"@name, what's the best way to level up Smithing?",
"Hey @name, what's your favorite Slayer master?",
"@name, use the Ardougne cloak teleports!",
"@name, what's the Legends' Quest about?",
"Hey @name, how do I unlock the Ancient Magicks?",
"@name, remember the old Pest Control boats?",
"@name, what's the best way to level up Construction?",
"Hey @name, what's the fastest way to level up Prayer?",
"@name, the old Duel Arena stakes!",
"@name, what's the Warriors' Guild?",
"Hey @name, how do I defeat the Kalphite Queen?",
"@name, use the fairy ring code BIP!",
"@name, should I train Attack or Defense first?",
"Hey @name, what's the best way to level up Thieving?",
"@name, don't forget your charged glory amulet!",
"@name, what's the Legends' Cape?",
"Hey @name, how do I access the Heroes' Guild?",
"@name, remember the old Pest Control void gear?",
"@name, how do I get a firemaking skillcape?",
"Buying gf 10k",
"Trimming armor for free!",
"Wanna join my clan? We're called The Mighty Cabbages'!",
"I'll meet you at the Falador Party Room!",
"Dancing for coins in Varrock Square!",
"Remember when the Wilderness was dangerous?",
"I got a rune scimitar drop from Lesser Demons!",
"Lumbridge Swamp is haunted!",
"Anyone up for Castle Wars?",
"I miss the old random events!",
"World 2 is the trading hub!",
"I'm going to train my Agility at the Gnome Stronghold!",
"I just got 99 Cooking!",
"Fishing lobsters at Catherby is life!",
"The Legends' Guild is so exclusive!",
"Who needs a quest guide? I'll figure it out!",
"I'm mining rune essence for hours!",
"Barrows armor looks sick!",
"I'm stuck in the Underground Pass!",
"The Stronghold of Security taught me about account security!",
"I'm going to farm herbs in Ardougne!",
"I'm getting my fire cape!",
"I love the music in RuneScape!",
"I'm alching my maple longbows!",
"I'm doing the Recipe for Disaster subquests!",
"I'm going to train my combat stats at the Rock Crabs!",
"I'm going for the Quest Cape!",
"I'm going to mine pure essence!",
"I'm hunting chinchompas in the Feldip Hills!",
"I'm going to train my Woodcutting at Seers' Village!",
"I'm going to fish sharks at the Fishing Guild!",
"I'm going to train my Thieving at Ardougne Knights!",
"I'm going to hunt implings in Puro-Puro!",
"I'm going to train my Hunter at the Falconry!",
"I'm smithing rune platebodies!",
"I'm going to train my Farming at the Tree Gnome Stronghold!",
"I'm going to hunt red chinchompas in the Wilderness!",
"I'm doing the Underground Pass quest!",
"I'm going to fish monkfish in Piscatoris!",
"Meet me in Varrock, @name, for an epic trade",
"@name, join my clan; we'll conquer the Wilderness together!",
"Beware the dragons, @name, they're fiercer than you think",
"Crafting runes with @name, the best mage in Gielinor",
"Fishing lobsters with @name, the sea's no match for us",
"@name, your swordsmanship at Duel Arena is unmatched!",
"Questing through dark caves, @name always leads the way",
"Share your wisdom, @name, how'd you master those spells?",
"Legends speak of @name bravery at the God Wars",
"Need more arrows, @name? I've got plenty to spare",
"Cooking's a breeze when @name around, no burnt lobsters!",
"Mining together, @name and I strike gold every time",
"@name, let's barter; your herbs for my potions?",
"Training agility with @name, leaping like graceful gazelles",
"Heard @name got the best magic beans in town",
"Fletching bows with @name, aiming for perfection",
"Smithing with @name, our anvils never cool down",
"Adventuring with @name, every quest is a thrill",
"Battling demons, @name courage inspires us all",
"Slaying dragons, @name the hero we need",
"Gathering at Falador, @name party room is legendary",
"Hunting chinchompas, @name traps are always full",
"Farming's fun with @name, our crops never fail",
"Brewing potions, @name mixtures are magical",
"Casting spells with @name, we're invincible",
"Building fires, @name flames warm the coldest nights",
"Sailing to Pest Control, @name our fearless captain",
"Trading runes, @name deals are the fairest",
"Exploring dungeons, @name the light in the darkness",
"Charging orbs with @name, our energy knows no bounds",
"Dancing in Draynor, @name moves are enchanting",
"Playing Gnomeball, @name the star player",
"Harvesting willows, @name axe swings true",
"Enchanting jewelry, @name touch turns copper to gold",
"Summoning familiars, @name spirit wolf leads the pack",
"Thieving from stalls, @name hands are lightning-fast",
"Crafting runes, @name essence never runs dry",
"Fishing at Catherby, @name catch feeds us all",
"Cooking feasts, @name dishes delight the gods",
"Mining runite, @name pickaxe strikes rich veins",
"Bartering at Grand Exchange, @name a trading master",
"Training prayer, @name piety moves mountains",
"Fighting revenants, @name valor shines bright",
"Building homes, @name construction is flawless",
"Hunting imps, @name net is always full",
"Brewing ale, @name tavern is the town's favorite",
"Casting high alchemy, @name turns junk into treasure",
"Sailing to Karamja, @name adventures are legendary",
"Forging alliances, @name charisma unites clans",
"Defeating bosses, @name name echoes in legends",
"Are you mewing @name???",
"Check out that gyatt @name",
"Bruhhhhh @name got that rizz",
"@name rizzing up the bots",
"Ironman? More like copperboy LOL",
"What that gyatt do @name",
"He's got the zoomies!",
"@name likes pickles and dipped in mayo",
"Lmaaooooooo",
"Bruh she said she loved me...",
"I caught @name rizzing a mewing teacher",
"What that mouth do bb",
"Ayo tf he say",
"Ayo",
"Ayo @name a freak lowkey",
"Ayo tf",
"@name catch me outside howbout that",
"Wasssssuuuuppppppp",
"Knock knock @name",
"Oh boy howdy do i have a surprise for you",
"Noooooo",
"What do you mean I haven't done anything wtf",
"Redrocket redrocket!!!",
"I made 20,000 crochet sock puppets for ceikry",
"Come on @name",
"Are we rading tonight @name?",
"Why would he say that",
"Penguins are technically reptiles",
"Brb smell something burning",
"Need pest control partner, you handle the portals, i will afk",
"Bruhhhh the skibiddi rizz in my gyatt makes my mewing sesh rough",
"@name jajajajaja",
"Wait, I can't raid tonight @name",
"Brb, pizza's here. Hope they ask why I'm a grown man dressed like an elf",
"Sorry, gotta go AFK. My dog just ate my gaming headset.",
"Brb, my grandma just fell down the stairs",
"Hold on, the baby's crying, aka @name",
"Oops, spilled my drink",
"Guys, I need to log off, my plants are staging a revolt for not watering them",
"AFK a sec, my neighbor's llama is in my backyard again",
"My pizza rolls are ready",
"Lost track of time, i'm late for my own wedding",
"Sorry, can't hear you over the sound of my laundry",
"Turn HDR off in windows @name",
"Www. no one cares .com",
"Hey @name www dot stfu dot com",
"Like pitching a tent in a pair of britches",
"Mad as a bag of ferrets",
"I dont think beavers built the hoover dam",
"How do beavers get the concrete for dams?",
"@name show me the way",
"@name onwards brutha",
"@name eats fried rat tails",
"@name is a rat",
"Why are there so many people farming right now",
"@name fuck the police",
"@name says the like pickles on their hotdogs",
"Fuck the guards, free woah in varrock prison",
"Ayo fuck u mean",
"Woop woop thats da sound of the beast",
"How are you the way that you are",
"She sells seashells by the sea shore",
"@name certified rat",
"@name buys skimmed milk",
"Got milk?",
"Are you JSON because i want you to get array from me",
"@name likes string manipulation",
"@name sells legos",
"JUST DO IT",
"Why are there so many motherfucking options",
"Just hit the fucking auto hide thing",
"Just play",
"Hell no this shit is fuzzy as balls",
"@name is fuzzy as balls",
"Turn your brightness up @name",
"On my pc it runs perfectly",
"I know why mine seems a little jumpy",
"Stream the window not the monitor",
"Discords a bitch",
"Why are there so many handsome people at the ge like @name",
"I'll make you squeel of fortune",
"You will get it in due time @name",
"I was one turn away",
"It do be pipe time @name",
"Sometimes i like to cover myself in vaseline and pretend i'm a slug",
"Woah is a greased pig",
"Sometimes i dig holes in my backyard and pretend i'm a carrot",
"It's pipe time @name",
"If i am not pipe timing i am programming",
"Yes i have thigh high socks, no you cannot have them",
"I scream when i wear my programming socks",
"Anyone wanna buy @name's bathwater?",
"Anyone wanna buy my used socks?",
"@name be getting bags",
"What the fuck is this",
"Hi i noticed you haven't taken a break in hours @name",
"I really am seething rn",
"I am so fucking tilted",
"Go back to your fucking frogs",
"Life is simple as frog farmer",
"A q p",
"Oooooh that's a first",
"Been a minute @name",
"Hey @name",
"Oh shit it's @name",
"Hey @name wyd today?",
"Ayo @name",
"Wyd @name",
"Wbu @name?",
"Good fuck em, that's what they get",
"Deathknight lookin rat ass mf @name",
"@name sucks slugs",
"Brb gotta take a shit",
"@name will brb went to take a shit",
"Tell me when he is coming",
"This guy is being incredibly based",
"@name is based af",
"Taking l's all day today @name",
"That sucks massive dongus",
"Ah i was about to type that",
"Where is stormwind?",
"How do i buy gold",
"@name sells gold",
"@name is a gold digger",
"Ayo @name wanna buy some frog legs?",
"Brb fucking burnt my pizza rolls",
"I swear @name if you need roll again",
"@name you are a hunter you don't need plate armor",
"Dragonriding is satisfying",
"There's an old TzHarrian saying, you fuck up once, you lose two teeth",
"FUCK",
"@name i am ready when you are",
"Anyone selling logs?",
"That is hilarious @name",
"Alright @name",
"I need to go get my quest cape",
"500 barrows runs dry",
"Back to back to back barrows items, easy game",
"@name did you know them?",
"@name sucks eggs",
"@name eats snails",
"Who is that?",
"I've gotta go in 20 minutes",
"Bonk",
"Gtg in 30 minutes",
"They left 50 minutes ago",
"I think it's just gonna be us",
"Who is that?",
"Stop following me",
"@name stop following me",
"I think @name is watching me",
"@name wouldn't let me get a hit in at clan wars",
"Clan wars and chill?",
"Quick mewing sesh",
"Don't you stickbug me",
"Get stick bugged",
"Wtf why are you a dragon",
"Fun fact, woah eats eggs whole like a snake",
"Ceikys there's a rare over there",
"Where is goldshire?",
"How long have you played @name?",
"Wanna quest?",
"TROGDORRRRRR",
"Fuck this shit i'm out",
"Wait till you get your first 99",
"How is that even possible",
"That's the max",
"@name is trying to max",
"Complesionist cape?",
"How can you increase your run speed?",
"@name where is barrows?",
"@name where are rune rocks?",
"@name where is yanille?",
"@name how long have you played for?",
"Yes these quotes were hand typed",
"Kermit was here",
"World of Warcraft died after Wrath",
"Ceikry needs to add talent trees",
"How do you get to the wilderness?",
"Anyone tryna lure @name?",
"@name tried to lure me",
"@name bots all the time",
"Anyone want chicken tendies",
"Brb foods ready",
"Brb",
"Gotta go get food",
"Anyone else from northern alaska?",
"Fishing 4 gp",
"Looking for gf",
"Anyone wanna be my discord kitten?",
"Selling discord kittens",
"@name is a discord kitten",
"Add me on discord",
"Are you in the 09discord",
"Where are you going @name?",
"Idk what i am going to cook today",
"What should i eat tonight",
"He is in the cave",
"Don't forget to save game before logging out",
"American horror story died after season 1",
"Prequels are better than the sequels",
"Disney star wars is the best star wars",
"Halo 5 sucked",
"Selling xbox live gold and 1600 microsoft points for 50k gp",
"Buying gf 25gp and a bucket",
"@name i heard evilwaffles bots",
"@name hopefully ceikry doesn't find out about evilwaffles",
"Honk honk",
"Where is the road to mordor?",
"Golem lookin ass bitch",
"@name rat looking mf",
"@name uses sand paper to wipe",
"@name said Woah is cute",
"You need 25 of 40 to do that",
"Over 1000 unique lines of dialogue",
"What should i get to eat",
"Ge be poppin today",
"Where all the woahs at",
"Ayo woahscam got that gyatt",
"That is one i haven't seen before"
],
"halloween": [
"Trick or treat!!!",
@ -521,9 +1008,9 @@
"Costume party at my P O H!! Follow me!",
"Trick, then!",
"Brrrainssssssss...",
"'Cause this is thriller, thriller night, and no one's gonna save you from the beast about to strike!",
"This is Hallowe'en, this is Hallowe'en, pumpkins scream in the dead of night!",
"This is Hallowe'en, everybody make a scene, Trick or treat till the neighbors gonna die of fright!",
"'Cause this is thriller, thriller night!",
"This is Hallowe'en, this is Hallowe'en!",
"This is Hallowe'en, everybody make a scene!",
"In this town we call home, everyone hail to the pumpkin song!",
"Watch out for Skeleton Jack!",
"The headless-what-man? Horse? Never heard of those.",

File diff suppressed because it is too large Load diff

View file

@ -12,15 +12,16 @@ import core.game.world.map.Location
import core.game.world.map.RegionManager
import core.game.world.map.zone.ZoneBorders
import core.game.world.update.flag.*
import core.tools.RandomFunction
import org.json.simple.JSONArray
import org.json.simple.JSONObject
import core.ServerConstants
import core.api.log
import core.game.bots.AIRepository
import core.game.bots.CombatBotAssembler
import core.game.bots.Script
import core.game.interaction.IntType
import core.game.interaction.InteractionListeners
import core.tools.Log
import java.io.File
import java.io.FileReader
import java.time.LocalDateTime
@ -40,21 +41,27 @@ import kotlin.random.Random
* @author Ceikry
*/
//Adventure Bots v4.0.0 -Expansion Edition-
// Adventure Bots v1.1.0 : Expansion Edition (Previously v4.0.0)
// Super Grand Exchange Update
class Adventurer(val style: CombatStyle): Script() {
var city: Location = lumbridge
var ticks = 0
var freshspawn = true
var sold = false
private val geloc: Location = if (Random.nextBoolean()){
Location.create(3165, 3487, 0)
}else{
Location.create(3164, 3492, 0)
}
var poiloc: Location = karamja
var geSocialLoc: Location = getRandomGESocialLocation()
var geClerkLoc: Location = getRandomGELocation()
var geClerksloc: Location = neGEClerk
var freshspawn: Boolean = true
var sold: Boolean = false
var poi: Boolean = false
val chance: Int = if (cityLocationsGE.contains(city)) 3500 else 3000
var ticks: Int = 0
var counter: Int = 0
var random: Int = (5..30).random()
val waitTotal: Int = 8
var returnToAdventure: Int = 0
var geWait: Int = 0
var geLongWait: Int = 0
val type = when(style){
CombatStyle.MELEE -> CombatBotAssembler.Type.MELEE
@ -74,23 +81,81 @@ class Adventurer(val style: CombatStyle): Script() {
}
override fun toString(): String {
return "${bot.name} is an Adventurer bot at ${bot.location}! State: $state - City: $city"
return "${bot.username} is an Adventurer bot " +
"at ${bot.location}! " +
"State: $state - " +
"City: $city - " +
"Ticks: $ticks - " +
"Freshspawn: $freshspawn - " +
"Sold: $sold - " +
"Counter: $counter"
}
var state = State.START
fun getRandomCity(): Location{
private fun getRandomCity(): Location{
return cities.random()
}
fun getRandomPoi(): Location{
private fun getRandomPoi(): Location{
return pois.random()
}
private fun getRandomGESocialLocation(): Location{
return socialLocationsGE.random()
}
private fun getRandomGELocation(): Location {
return cityLocationsGE.random()
}
private fun randomNumberFromOne(maxInt: Int): Int {
return Random.nextInt(0, maxInt)
}
private fun otherPlayersNearby(): Boolean {
val localPlayers = RegionManager.getLocalPlayers(bot)
val otherPlayers = localPlayers.filter { it.name != bot.name }
return otherPlayers.isNotEmpty()
}
private fun checkNearBank() {
if(bankMap[city] == null){
scriptAPI.teleport(getRandomCity().also { city = it })
} else {
if(bankMap[city]?.insideBorder(bot) == true){
state = State.FIND_BANK
} else {
bankMap[city]?.let { scriptAPI.walkTo(it.randomLoc) }
}
}
}
private fun checkCounter(maxCounter: Int) {
if (counter++ >= maxCounter) {
state = State.TELEPORTING
}
}
private fun teleportToRandomCity() {
city = getRandomCity()
when (city) {
neGEClerk -> { scriptAPI.teleport(scriptAPI.randomizeLocationInRanges(city,-3,2,0,1,0)) }
swGEClerk -> { scriptAPI.teleport(scriptAPI.randomizeLocationInRanges(city,-2,3,-1,0,0)) }
nwGEBanker -> { scriptAPI.teleport(scriptAPI.randomizeLocationInRanges(city,-2,0,-3,2,0)) }
seGEBanker -> { scriptAPI.teleport(scriptAPI.randomizeLocationInRanges(city,0,2,-2,3,0)) }
else -> { scriptAPI.teleport(scriptAPI.randomizeLocationInRanges(city,-1,1,-1,1,0)) }
}
}
val resources = listOf(
"Rocks","Tree","Oak","Willow",
"Maple tree","Yew","Magic tree",
"Teak","Mahogany")
//TODO: Optimise and adjust how bots handle picking up ground items further.
fun immerse() {
if (counter++ == 180) {state = State.TELEPORTING
}
if (counter++ >= Random.nextInt(150,300)) { state = State.TELEPORTING }
val items = AIRepository.groundItems[bot]
if (Random.nextBoolean()) {
if (items.isNullOrEmpty()) {
@ -98,33 +163,13 @@ class Adventurer(val style: CombatStyle): Script() {
state = State.LOOT_DELAY
}
if (bot.inventory.isFull) {
if(bankMap[city] == null){
scriptAPI.teleport(getRandomCity().also { city = it })
} else {
if(bankMap[city]?.insideBorder(bot) == true){
state = State.FIND_BANK
} else {
scriptAPI.walkTo(bankMap[city]?.randomLoc ?: Location(0, 0, 0))
}
}
checkNearBank()
}
} else {
if (bot.inventory.isFull){
if(bankMap[city] == null){
scriptAPI.teleport(getRandomCity().also { city = it })
checkNearBank()
} else {
if(bankMap[city]?.insideBorder(bot) == true){
state = State.FIND_BANK
} else {
scriptAPI.walkTo(bankMap[city]?.randomLoc ?: Location(0, 0, 0))
}
}
} else {
val resources = listOf(
"Rocks","Tree","Oak","Willow",
"Maple tree","Yew","Magic tree",
"Teak","Mahogany")
val resource = scriptAPI.getNearestNodeFromList(resources,true)
if(resource != null){
if(resource.name.contains("ocks")) InteractionListeners.run(resource.id,
@ -137,18 +182,17 @@ class Adventurer(val style: CombatStyle): Script() {
}
fun refresh() {
// log(this::class.java, Log.WARN, "${bot.username} refreshed from $state at $city with $ticks and $counter counter.")
scriptAPI.teleport(lumbridge)
freshspawn = true
state = State.START
}
var poi = false
var poiloc = karamja
//Adventure Bots Actual Code STARTS HERE!!!
// 100 ticks = 60 seconds
override fun tick() {
ticks++
if (ticks++ >= 800) {
// Hard refresh
if (ticks >= 1000) {
ticks = 0
refresh()
return
@ -186,49 +230,42 @@ class Adventurer(val style: CombatStyle): Script() {
}
return
} else {
state = State.EXPLORE
state = State.ADVENTURE
}
}
State.START -> {
if (freshspawn) {
freshspawn = false
scriptAPI.randomWalkTo(lumbridge, 20)
scriptAPI.randomWalkTo(lumbridge, randomNumberFromOne(25))
} else {
city = getRandomCity()
state = State.TELEPORTING
}
}
State.TELEPORTING -> {
if (freshspawn){ freshspawn = false }
teleportToRandomCity()
poi = false
sold = false
ticks = 0
counter = 0
if (bot.location != city) {
poi = false
scriptAPI.teleport(city)
} else {
poi = false
state = State.EXPLORE
}
state = State.ADVENTURE
return
}
State.EXPLORE -> {
if (counter++ == 350) {
state = State.TELEPORTING
}
val chance = if (city == ge || city == ge2) 5000 else 2500
if (RandomFunction.random(chance) <= 10) {
val nearbyPlayers = RegionManager.getLocalPlayers(bot)
if (nearbyPlayers.isNotEmpty()) {
State.ADVENTURE -> {
checkCounter(800)
if (randomNumberFromOne(chance) <= 10) {
if (otherPlayersNearby()) {
ticks = 0
dialogue()
}
}
if (RandomFunction.random(1000) <= 150 && !poi) {
val roamDistance = if (city != ge && city != ge2) 225 else 7
if ((city == ge || city == ge2) && RandomFunction.random(100) < 90) {
if (!poi && randomNumberFromOne(1000) <= 75) {
val roamDistance = if (!cityLocationsGE.contains(city)) 225 else randomNumberFromOne(5)
if (cityLocationsGE.contains(city) && randomNumberFromOne(100) < 90) {
if (!bot.bank.isEmpty) {
state = State.FIND_GE
}
@ -238,33 +275,46 @@ class Adventurer(val style: CombatStyle): Script() {
return
}
if (RandomFunction.random(1000) <= 50 && poi){
if (poi && randomNumberFromOne(1000) <= 100){
immerse()
return
}
if (poi && randomNumberFromOne(1000) <= 25){
dialogue()
}
if (poi && randomNumberFromOne(1000) <= 50){
val roamDistancePoi = when(poiloc){
teakfarm, crawlinghands -> 5
treegnome -> 50
isafdar -> 40
eaglespeek -> 40
keldagrimout -> 30
teak1 -> 30
miningguild -> 5
magics, coal -> 7
gemrocks, chaosnpc, chaosnpc2 -> 1
magics, coalTrucks -> 7
miningguild, teakfarm, crawlinghands -> 5
varLumberYard -> 20
keldagrimout, teak1 -> 30
eaglespeek, isafdar -> 40
treegnome -> 50
else -> 60
}
scriptAPI.randomWalkTo(poiloc,roamDistancePoi)
return
}
if (RandomFunction.random(1000) <= 75) {
if (city != ge && city != ge2) {
if (randomNumberFromOne(1000) <= 75) {
if (!cityLocationsGE.contains(city)) {
ticks = 0
immerse()
return
} else {
return
} else if (randomNumberFromOne(chance) <= 55 && otherPlayersNearby()) {
ticks = 0
dialogue()
}
}
if (RandomFunction.random(20000) <= 60 && !poi) {
if (cityLocationsGE.contains(city) && randomNumberFromOne(1000) <= 50) {
state = State.IDLE_GE
}
if (!poi && randomNumberFromOne(1000) <= 5) {
poiloc = getRandomPoi()
city = teak1
poi = true
@ -272,26 +322,24 @@ class Adventurer(val style: CombatStyle): Script() {
return
}
if ((city == ge || city == ge2) && RandomFunction.random(1000) >= 999) {
ticks = 0
city = getRandomCity()
if (cityLocationsGE.contains(city) && randomNumberFromOne(1000) <= 100) {
state = State.TELEPORTING
}
if (city == ge || city == ge2) {
return
}
if (city == teak1 && counter++ >= 240){
city = getRandomCity()
state = State.TELEPORTING
if (cityLocationsGE.contains(city)) {
return
}
if (counter++ >= 240 && RandomFunction.random(100) >= 10) {
if (poi && randomNumberFromOne(1000) <= 20){
state = State.TELEPORTING
return
}
if (counter++ >= 750 && randomNumberFromOne(100) <= 50) {
// log(this::class.java, Log.FINE, "${bot.username} has moved on to a different city at $ticks ticks and $counter counter.")
city = getRandomCity()
if (RandomFunction.random(100) % 2 == 0) {
counter = 0
ticks = 0
if (randomNumberFromOne(100) % 2 == 0) {
state = State.TELEPORTING
} else {
if (citygroupA.contains(city)) {
@ -309,122 +357,122 @@ class Adventurer(val style: CombatStyle): Script() {
return
}
State.GE -> {
var ge = false
if (counter++ == 180) {
state = State.TELEPORTING
}
if (!sold) {
if (counter++ >= 15) {
sold = true
ge = true
State.IDLE_GE -> {
returnToAdventure = Random.nextInt(350, 750)
if (counter++ >= returnToAdventure){
if (randomNumberFromOne(100) <= 25){
ticks = 0
counter = 0
poiloc = getRandomPoi()
city = teak1
poi = true
scriptAPI.teleport(poiloc)
state = State.ADVENTURE
return
} else {
counter = 0
ticks = 0
scriptAPI.sellAllOnGeAdv()
state = State.TELEPORTING
return
}
}
if (cityLocationsGE.contains(city)){
if (randomNumberFromOne(1000) <= 5) {
ticks = 0
geSocialLoc = scriptAPI.randomizeLocationInRanges(getRandomGESocialLocation(),-1,1,-1,1,0)
} else if (randomNumberFromOne(1000) <= 10) {
ticks = 0
scriptAPI.randomWalkTo(geSocialLoc, randomNumberFromOne(5))
return
}
if (randomNumberFromOne(1000) <= 5 && otherPlayersNearby()){
ticks = 0
dialogue()
} else if (randomNumberFromOne(1000) <= 250){
return
}
} else if (ge && sold) {
ge = false
city = getRandomCity()
state = State.TELEPORTING
}
return
}
State.FIND_GE -> {
if (counter++ == 180) {
state = State.TELEPORTING
}
sold = false
val ge: Scenery? = scriptAPI.getNearestNode("Desk", true) as Scenery?
if (ge == null || bot.bank.isEmpty) state = State.EXPLORE
if (ge == null || bot.bank.isEmpty) state = State.ADVENTURE
class GEPulse : MovementPulse(bot, ge, DestinationFlag.OBJECT) {
override fun pulse(): Boolean {
bot.faceLocation(ge?.location)
state = State.GE
return true
return true.also { state = State.GE }
}
}
if (ge == null || bot.bank.isEmpty) state = State.ADVENTURE
if (ge != null && !bot.bank.isEmpty) {
counter = 0
scriptAPI.randomWalkTo(geloc, 3)
if (randomNumberFromOne(1000) <= 25 && otherPlayersNearby()){
dialogue()
scriptAPI.randomWalkTo(geSocialLoc, randomNumberFromOne(5))
} else if (randomNumberFromOne(500) <= 50) {
GameWorld.Pulser.submit(GEPulse())
}
}
checkCounter(500)
return
}
State.GE -> {
geClerksloc = clerkLocationsGe.random()
geWait = Random.nextInt(35, 100)
geLongWait = Random.nextInt(350, 750)
if (!sold) {
if (randomNumberFromOne(500) <= 25){ scriptAPI.randomWalkTo(geClerksloc, randomNumberFromOne(4))}
if (counter++ >= geWait) {
scriptAPI.randomWalkTo(geClerksloc, randomNumberFromOne(1))
sold = true
counter = 0
ticks = 0
scriptAPI.sellAllOnGeAdv()
state = State.TELEPORTING
return
}
} else if (counter++ >= geLongWait) {
state = State.TELEPORTING
return
}
checkCounter(1000)
return
}
State.FIND_BANK -> {
if (counter++ == 300) {
state = State.TELEPORTING
}
val bank: Scenery? = scriptAPI.getNearestNode("Bank booth", true) as Scenery?
if (badedge.insideBorder(bot) || bot.location == badedge2 || bot.location == badedge3 || bot.location == badedge4) {
bot.randomWalk(5, 5)
}
if (bank == null) state = State.EXPLORE
class BankingPulse : MovementPulse(bot, bank, DestinationFlag.OBJECT) {
override fun pulse(): Boolean {
bot.faceLocation(bank?.location)
state = State.IDLE_BANKS
return true
}
}
if (bank != null) {
bot.pulseManager.run(BankingPulse())
if (bank == null) { state = State.TELEPORTING }
if (bank != null && randomNumberFromOne(100) <= 5) {
scriptAPI.depositAtBank()
} else if (bank != null && randomNumberFromOne(100) <= 5){
scriptAPI.randomWalkTo(bank.location,3)
}
checkCounter(500)
return
}
State.IDLE_BANKS -> {
if (counter++ == 300) {
state = State.TELEPORTING
}
if (RandomFunction.random(1000) < 100) {
for (item in bot.inventory.toArray()) {
item ?: continue
when (item.id) {
1359, 590, 1271, 995 -> continue
}
bot.bank.add(item)
bot.inventory.remove(item)
}
counter = 0
state = State.EXPLORE
}
return
}
State.FIND_CITY -> {
if (counter++ >= 600 || (city == ge || city == ge2)) {
counter = 0
if (counter++ >= 500 || cityLocationsGE.contains(city)){
scriptAPI.teleport(getRandomCity().also { city = it })
state = State.EXPLORE
state = State.ADVENTURE
}
if (bot.location.equals(city)) {
state = State.EXPLORE
state = State.ADVENTURE
} else {
scriptAPI.randomWalkTo(city, 5)
scriptAPI.randomWalkTo(city, randomNumberFromOne(10))
}
checkCounter(600)
return
}
State.IDLE_CITY -> {
if (counter++ == 300) {
state = State.TELEPORTING
}
var random = (120..300).random()
if (counter++ == random && RandomFunction.random(1000) % 33 == 0) {
counter = 0
state = State.EXPLORE
}
return
}
}
}
fun dialogue() {
val localPlayer = RegionManager.getLocalPlayers(bot).random()
val until = 1225 - dateCode
val lineStd = dialogue.getLines("standard").rand()
var lineAlt = ""
@ -455,20 +503,29 @@ class Adventurer(val style: CombatStyle): Script() {
dateCode == 404 -> lineAlt = dialogue.getLines("easter").rand()
}
var localPlayers = RegionManager.getLocalPlayers(bot)
if (localPlayers.isNotEmpty()) {
val localPlayer = localPlayers
.filter { it.name != bot.name }
.randomOrNull()
if (localPlayer != null) {
val chat = if (lineAlt.isNotEmpty() && Random.nextBoolean()) { lineAlt } else { lineStd }
.replace("@name", localPlayer.username)
.replace("@timer", until.toString())
scriptAPI.sendChat(chat)
} else {
val chat = if (lineAlt.isNotEmpty() && Random.nextBoolean()) { lineAlt } else { lineStd }
scriptAPI.sendChat(chat)
}
}
}
enum class State{
START,
EXPLORE,
ADVENTURE,
FIND_BANK,
IDLE_BANKS,
FIND_CITY,
IDLE_CITY,
IDLE_GE,
GE,
TELEPORTING,
LOOT,
@ -489,44 +546,94 @@ class Adventurer(val style: CombatStyle): Script() {
}
companion object {
val badedge = ZoneBorders(3094, 3494, 3096, 3497)
val badedge2 = Location.create(3094, 3492, 0)
val badedge3 = Location.create(3094, 3490, 0)
val badedge4 = Location.create(3094, 3494, 0)
// Start Cities
val yanille: Location = Location.create(2615, 3104, 0)
val ardougne: Location = Location.create(2662, 3304, 0)
val seers: Location = Location.create(2726, 3485, 0)
val edgeville: Location = Location.create(3088, 3486, 0)
val ge: Location = Location.create(3168, 3487, 0)
val ge2: Location = Location.create(3161, 3493, 0)
val catherby: Location = Location.create(2809, 3435, 0)
val falador: Location = Location.create(2965, 3380, 0)
val varrock: Location = Location.create(3213, 3428, 0)
val draynor: Location = Location.create(3080, 3250, 0)
val rimmington: Location = Location.create(2977, 3239, 0)
val lumbridge: Location = Location.create(3222, 3219, 0)
val karamja = Location.create(2849, 3033, 0)
val alkharid = Location.create(3297, 3219, 0)
val feldiphills = Location.create(2535, 2919, 0)
val isafdar = Location.create(2241, 3217, 0)
val eaglespeek = Location.create(2333, 3579, 0)
val canafis = Location.create(3492, 3485, 0)
val treegnome = Location.create(2437, 3441, 0)
val teak1 = Location.create(2334, 3048, 0)
val teakfarm = Location.create(2825, 3085, 0)
val keldagrimout = Location.create(2724,3692,0)
val miningguild = Location.create(3046,9740,0)
val magics = Location.create(2285,3146,0)
val coal = Location.create(2581,3481,0)
val crawlinghands = Location.create(3422,3548,0)
val gemrocks = Location.create(2825,2997,0)
val chaosnpc = Location.create(2612,9484,0)
val chaosnpc2 = Location.create(2580,9501,0)
val taverly = Location.create(2909, 3436, 0)
val karamja: Location = Location.create(2849, 3033, 0)
val alkharid: Location = Location.create(3297, 3219, 0)
// Start POI
val feldiphills: Location = Location.create(2535, 2919, 0)
val isafdar: Location = Location.create(2241, 3217, 0)
val eaglespeek: Location = Location.create(2333, 3579, 0)
val canafis: Location = Location.create(3492, 3485, 0)
val treegnome: Location = Location.create(2437, 3441, 0)
val teak1: Location = Location.create(2334, 3048, 0)
val teakfarm: Location = Location.create(2825, 3085, 0)
val keldagrimout: Location = Location.create(2724,3692, 0)
val miningguild: Location = Location.create(3046,9740, 0)
val magics: Location = Location.create(2285,3146, 0)
val coalTrucks: Location = Location.create(2581,3481, 0)
val crawlinghands: Location = Location.create(3422,3548, 0)
val gemrocks: Location = Location.create(2825,2997, 0)
val chaosnpc: Location = Location.create(2612,9484, 0)
val chaosnpc2: Location = Location.create(2586, 9501, 0)
val varLumberYard: Location = Location.create(3289, 3482, 0)
val taverly: Location = Location.create(2909, 3436, 0)
val swGEClerk: Location = Location.create(3164, 3487, 0)
val neGEClerk: Location = Location.create(3165, 3492, 0)
val nwGEBanker: Location = Location.create(3162, 3490, 0)
val seGEBanker: Location = Location.create(3167, 3489, 0)
val badedge = ZoneBorders(3094, 3494, 3096, 3497)
val badedge2: Location = Location.create(3094, 3492, 0)
val badedge3: Location = Location.create(3094, 3490, 0)
val badedge4: Location = Location.create(3094, 3494, 0)
var citygroupA = listOf(falador, varrock, draynor, rimmington, lumbridge, edgeville)
var citygroupB = listOf(yanille, ardougne, seers, catherby)
val cities = listOf(
swGEClerk, neGEClerk, nwGEBanker, seGEBanker,
yanille, ardougne, seers, catherby,
falador, varrock, draynor, rimmington,
lumbridge, edgeville
)
val pois = listOf(
karamja, karamja, alkharid,
alkharid, feldiphills, feldiphills,
isafdar, eaglespeek, eaglespeek,
canafis, treegnome, treegnome,
teak1, teakfarm, keldagrimout,
miningguild, coalTrucks, crawlinghands,
magics, gemrocks, chaosnpc, chaosnpc,
chaosnpc2, taverly,
varLumberYard)
val cityLocationsGE = listOf(swGEClerk, neGEClerk, nwGEBanker, seGEBanker)
val socialLocationsGE = listOf(
Location.create(3158, 3483, 0),
Location.create(3165, 3480, 0),
Location.create(3172, 3483, 0),
Location.create(3174, 3489, 0),
Location.create(3171, 3497, 0),
Location.create(3164, 3499, 0),
Location.create(3157, 3497, 0),
Location.create(3155, 3489, 0),
Location.create(3167, 3492, 0),
Location.create(3162, 3492, 0),
Location.create(3162, 3487, 0),
Location.create(3167, 3487, 0)
)
val clerkLocationsGe = listOf(
Location.create(3165, 3492, 0),
Location.create(3164, 3492, 0),
Location.create(3164, 3487, 0),
Location.create(3165, 3487, 0)
)
var bankMap = mapOf<Location, ZoneBorders>(
falador to ZoneBorders(2950, 3374, 2943, 3368),
varrock to ZoneBorders(3182, 3435, 3189, 3446),
@ -538,22 +645,10 @@ class Adventurer(val style: CombatStyle): Script() {
catherby to ZoneBorders(2807, 3438, 2811, 3441)
)
val cities = listOf(yanille, ardougne, seers, catherby, falador, varrock,
draynor, rimmington, lumbridge, ge, ge2, edgeville)
val pois = listOf(
karamja, karamja, alkharid,
alkharid, feldiphills, feldiphills,
isafdar, eaglespeek, eaglespeek,
canafis, treegnome, treegnome,
teak1, teakfarm, keldagrimout,
miningguild, coal, crawlinghands,
magics, gemrocks, chaosnpc, chaosnpc,
chaosnpc2, taverly)
private val whiteWolfMountainTop = Location(2850, 3496, 0)
private val catherbyToTopOfWhiteWolf = arrayOf(Location(2856, 3442, 0), Location(2848, 3455, 0), Location(2848, 3471, 0), Location(2848, 3487, 0))
private val tavleryToTopOfWhiteWolf = arrayOf(Location(2872, 3425, 0), Location(2863, 3440, 0), Location(2863, 3459, 0), Location(2854, 3475, 0), Location(2859, 3488, 0))
val common_stuck_locations = mapOf(
// South of Tavlery dungeon
ZoneBorders(2878, 3386, 2884, 3395) to { it: Adventurer ->

View file

@ -53,7 +53,7 @@ class CombatBotAssembler {
val bot = CombatBot(location)
generateStats(bot, tier, Skills.RANGE, Skills.DEFENCE)
gearRangedBot(bot, crossbow ?: Random().nextInt() % 2 == 0)
gearRangedBot(bot, (crossbow ?: (Random().nextInt() % 2)) == 0)
return bot
}
@ -82,7 +82,7 @@ class CombatBotAssembler {
fun MeleeAdventurer(tier: Tier, location: Location): CombatBot {
val bot = CombatBot(location)
var max = 0
val level = RandomFunction.random(25, 65).also {max = 99 }
val level = RandomFunction.random(25, 69).also {max = 99 }
generateStats(bot,tier,Skills.ATTACK, Skills.STRENGTH, Skills.DEFENCE)
bot.skills.setStaticLevel(Skills.HITPOINTS, level)
bot.skills.setStaticLevel(Skills.ATTACK, level + 5)
@ -114,7 +114,7 @@ class CombatBotAssembler {
fun RangeAdventurer(tier: Tier, location: Location): CombatBot {
val bot = CombatBot(location)
var max = 0
val level = RandomFunction.random(35, 65).also {max = 75 }
val level = RandomFunction.random(35, 69).also {max = 75 }
generateStats(bot,tier,Skills.ATTACK, Skills.STRENGTH)
bot.skills.setStaticLevel(Skills.HITPOINTS, level)
bot.skills.setStaticLevel(Skills.DEFENCE, level)

View file

@ -98,7 +98,7 @@ class GeneralBotCreator {
}*/
if(!botScript.running) return true //has to be separated this way or it double-submits the respawn pulse.
if (botPulsesTriggeredThisTick++ >= 50)
if (botPulsesTriggeredThisTick++ >= 75)
return false
val idleRoll = RandomFunction.random(10)

View file

@ -54,6 +54,7 @@ import kotlin.math.pow
import kotlin.math.sqrt
import core.ServerConstants
import core.api.utils.Vector
import kotlin.random.Random
class ScriptAPI(private val bot: Player) {
val GRAPHICSUP = Graphics(1576)
@ -396,6 +397,20 @@ class ScriptAPI(private val bot: Player) {
}
}
/**
* @param location the location you want the coordinates randomized for.
* @param xMin the minimum range value X coordinates should be randomized by, must be xMin <= xMax ex: -1 min 1 max.
* @param xMax the maximum range value X coordinates should be randomized by, must be xMin <= xMax ex: -1 min 1 max.
* @param yMin the minimum range value Y coordinates should be randomized by, must be yMin <= yMax ex: -1 min 1 max.
* @param yMax the maximum range value Y coordinates should be randomized by, must be yMin <= yMax ex: -1 min 1 max.
* @param staticZ this value is static and does not change from what is given, must be actual Z value of location.
* @author Kermit
*/
fun randomizeLocationInRanges(location: Location, xMin: Int, xMax: Int, yMin: Int, yMax: Int, staticZ: Int): Location {
val newX = location.x + Random.nextInt(xMin, xMax)
val newY = location.y + Random.nextInt(yMin, yMax)
return Location(newX, newY, staticZ)
}
/**
* The iterator for long-distance walking. Limited by doors and large obstacles like mountains.
@ -553,7 +568,7 @@ class ScriptAPI(private val bot: Player) {
1517 -> continue
1519 -> continue
1521 -> continue
else -> Repository.sendNews(SERVER_GE_NAME + " just offered " + itemAmt + " " + ItemDefinition.forId(actualId).name.toLowerCase() + " on the GE.")
else -> sendNews(SERVER_GE_NAME + " just offered " + itemAmt + " " + ItemDefinition.forId(actualId).name.lowercase() + " on the GE.")
}
}
bot.bank.remove(item)
@ -562,8 +577,36 @@ class ScriptAPI(private val bot: Player) {
return true
}
}
if (ge != null) {
bot.pulseManager.run(toCounterPulseAll())
}
}
/**
* Function to bank all items that are not excluded at a nearby bank.
* @author Kermit & Ceikry
*/
fun depositAtBank(){
val bank: Scenery? = getNearestNode("Bank booth", true) as Scenery?
class BankingPulse : MovementPulse(bot, bank, DestinationFlag.OBJECT) {
override fun pulse(): Boolean {
bot.faceLocation(bank?.location)
for (item in bot.inventory.toArray()) {
item ?: continue
when (item.id) {
Items.RUNE_AXE_1359, Items.TINDERBOX_590, Items.ADAMANT_PICKAXE_1271, Items.COINS_995 -> continue
}
bot.bank.add(item)
bot.inventory.remove(item)
}
// log(this::class.java, Log.FINE, "${bot.username} Just finished banking at ${bot.location} || Bank contents: ${bot.bank}")
return true
}
}
if (bank != null) {
bot.pulseManager.run(BankingPulse())
}
}
/**
* Function to determine whether or not to bother everyone on the server

View file

@ -11,6 +11,7 @@ import core.game.bots.SkillingBotAssembler
import java.util.Timer
import java.util.concurrent.Executors
import kotlin.concurrent.schedule
import kotlin.random.Random
class ImmerseWorld : StartupListener {
@ -24,6 +25,12 @@ class ImmerseWorld : StartupListener {
var assembler = CombatBotAssembler()
var skillingBotAssembler = SkillingBotAssembler()
private fun randomizeLocationInRanges(location: Location, xMin: Int, xMax: Int, yMin: Int, yMax: Int): Location {
val newX = location.x + Random.nextInt(xMin, xMax)
val newY = location.y + Random.nextInt(yMin, yMax)
return Location(newX, newY, 0)
}
fun spawnBots()
{
if(GameWorld.settings!!.enable_bots)
@ -43,10 +50,10 @@ class ImmerseWorld : StartupListener {
}
}
fun immerseAdventurer() {
for (i in 0..(GameWorld.settings?.max_adv_bots ?: 50)) {
var random: Long = (10000..300000).random().toLong()
Timer().schedule(random) {
fun immerseAdventurer(){
for (i in 0..(GameWorld.settings?.max_adv_bots ?: 50)){
var random = Random.nextInt(20000, 400000).toLong()
Timer().schedule(random){
spawn_adventurers()
}
}
@ -55,15 +62,18 @@ class ImmerseWorld : StartupListener {
fun spawn_adventurers() {
val lumbridge = Location.create(3221, 3219, 0)
val tiers = listOf<CombatBotAssembler.Tier>(CombatBotAssembler.Tier.LOW, CombatBotAssembler.Tier.MED)
if (Random.nextBoolean()) {
GeneralBotCreator(
Adventurer(CombatStyle.MELEE),
assembler.MeleeAdventurer(tiers.random(), lumbridge)
assembler.MeleeAdventurer(tiers.random(), randomizeLocationInRanges(lumbridge,-1,1,-1,1))
)
} else {
GeneralBotCreator(
Adventurer(CombatStyle.RANGE),
assembler.RangeAdventurer(tiers.random(), lumbridge)
assembler.RangeAdventurer(tiers.random(), randomizeLocationInRanges(lumbridge,-1,1,-1,1))
)
}
}
fun immerseFishingGuild() {
val fishingGuild = Location.create(2604, 3421, 0)