matto
11-25-2007, 09:12 AM
***SOLVED PLEASE REMOVE/LOCK***
Hey,
When I run the script below I get this error:
Failed when compiling
Line 414: [Error] (15604:48): Invalid number of parameters in script C:\Documents and Settings\xxx\Desktop\GnomeAgilityRunner v3.0.scar
I am using SCAR Divi 3.12 and SRL4. (Note I uploaded the original script, without my account info)
ScarScript:By Drunkenoldma
//################################################## #######</p><p>//################################################## #######</p><p>//#### Azzon's Gnome Agility Runner ####</p><p>//#### Version: 3.0 ####</p><p>//#### - Fr0zn S0ul Edit - ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>//#### ####</p><p>//#### Hello, and Welcome. I would like to start ####</p><p>//#### off by saying thank you for using this ####</p><p>//#### script. If you have any questions, ####</p><p>//#### suggestions, or problems related to this ####</p><p>//#### script, then feel free to post on the ####</p><p>//#### thread or send me a pm. ####</p><p>//#### ####</p><p>//#### You can find the player adjustable ####</p><p>//#### variables for the script between lines ####</p><p>//#### 76 and 94. ####</p><p>//#### ####</p><p>//#### You can setup the players using this ####</p><p>//#### script between lines 104 and 118. Due note ####</p><p>//#### that the script is only designed for a ####</p><p>//#### single player, and the purpose of the ####</p><p>//#### player setup is for Anti-Randoms. ####</p><p>//#### ####</p><p>//#### Thank you for using this script. ####</p><p>//#### - Azzon ####</p><p>//#### ####</p><p>//#### This script is made using SCAR DIVI v3.12 ####</p><p>//#### and SRL 4. ####</p><p>//#### - Fr0zn S0ul ####</p><p>//#### ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>//#### ####</p><p>//#### Fr0zn S0ul's additions: ####</p><p>//#### *Made script acceptable for new runescape ####</p><p>//#### interface and SRL 4 / SCAR 3.12. ####</p><p>//#### *Added LogOut procedure for less randoms ####</p><p>//#### and switch of players - requires your own ####</p><p>//#### addition for extra players sorry, most ####</p><p>//#### people only have one members account. ####</p><p>//#### *Added LogOutWait variables. These mean that ####</p><p>//#### after logging out and back in a certain ####</p><p>//#### amount of times, your player will wait for ####</p><p>//#### an amount of minutes before logging back in. ####</p><p>//#### *Made script run a lot faster by removing and ####</p><p>//#### reducing Wait times. ####</p><p>//#### *Added Levels Gained and XP to next level ####</p><p>//#### in the Player Report. ####</p><p>//#### *Added more failsafes, as player got stuck ####</p><p>//#### behind nets and pipe sometimes. ####</p><p>//#### *Reduced the extra random x and y axis ####</p><p>//#### additions, as they made player go slightly ####</p><p>//#### off course sometimes. ####</p><p>//#### *Remodeled the Declare Players procedure. ####</p><p>//#### *Slightly adjusted some of the obstacle ####</p><p>//#### colors. ####</p><p>//#### ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>program GnomeAgilityRunner; //931 Lines, With Spacers And Procedure Headers</p><p>{.include SRL/SRL.scar}</p><p> </p><p>var</p><p> x, y, LapsMade, LogAfter, LapsTillLog, tries, WaitOnPipe, LapsTillCheckRun, WaitOnFlagLoops : Integer;</p><p> LostCount, LogOutWaitFor, LogOutWaitEvery, LogCounter, StartLevel, LevelsGained : Integer;</p><p> NextLevel, XPNextLevel, NWorld, OWorld : Integer;</p><p> FirstLap, s1_Complete, s2_Complete, s3_Complete, s4_Complete : Boolean;</p><p> s5_Complete, s6_Complete, NewLap, LapComplete, FoundPipe, WalkingToStart, LogOutWait : Boolean;</p><p> </p><p>{.include SRL/SRL/misc/WorldSwitcher.scar}</p><p> </p><p>//################################################## ##############</p><p>//## Manual Player Setup ##</p><p>//################################################## ##############</p><p> </p><p>const</p><p> g_ColorTol = 16; //Game Screen Color Tolerance. Lowering Will Make Script Run Faster. Too Low And It Won't Work!</p><p> Laps = 150500; //Number Of Laps You Want The Script To Run For</p><p> CheckRunLapDelay = 8; //Number Of Laps To Complete Before Calling CheckRun Again</p><p> </p><p> </p><p>//################################</p><p>//## Note: Unless You Experience##</p><p>//## Color Problems, It Is ##</p><p>//## Recommended To Leave The ##</p><p>//## Color's As They Are. ##</p><p>//################################</p><p> </p><p> s_LogBalance_C1 = 868973; // Obstacle 1, Log Color</p><p> s_LogBalance_C2 = 606056; // Obstacle 1, Log Color</p><p> s_LogBalance_C3 = 602705; // Obstacle 1, Log Color</p><p> s_ObstacleNet_C1 = 5530233; //Obstacle 2, Net Color</p><p> s_ObstacleNet_C2 = 869744; //Obstacle 6, Net Color</p><p> s_TreeBranch_C = 3431793; //Obstacle 3, and Obstacle 5, Tree Color</p><p> s_BalancingRope_C = 4613245; //Obstacle 4, Rope Color</p><p> s_ObstaclePipe_C = 5592411; //Obstacle 7, Pipe Color</p><p> s_Mushroom_C = 2576031; //End Of Obstacle 7, Mushroom Color</p><p> </p><p>//################################################## ##############</p><p>//################################################## ##############</p><p> </p><p>//####################################</p><p>//## Player Setup Location ##</p><p>//####################################</p><p> </p><p>Procedure DeclarePlayers;</p><p>begin</p><p> SRLID := '0'; // Don't have this? Please Register at:</p><p> SRLPassword := ''; // <a href="http://www.stats.srl-forums.com/" target="_blank">http://www.stats.srl-forums.com/</a></p><p> //You must let this script connect to <a href="http://www.villu-reborn.com/stats/stats.php" target="_blank">www.villu-reborn.com/stats/stats.php</a> to send script statistics to SRL!</p><p> </p><p> HowManyPlayers := 1; // How many players to use.</p><p> NumberOfPlayers( HowManyPlayers ); // Leave this.</p><p> CurrentPlayer := 0; // Start Player? ie. 0 = Players[0].name</p><p> </p><p> LogAfter := 10; // Log Out every how many laps?</p><p> LogOutWait := true; // Every (LogOutWaitevery) logouts, log out for (LogOutWaitFor) extra amount of time?</p><p> LogOutWaitEvery := 8; // How often to wait extra time at logout</p><p> LogOutWaitFor := 10 + random(5); // Wait for how many extra MINUTES plus random(x) amount of time at LogOutWait?</p><p> //LogOutWaitFor is in MINUTES!</p><p> </p><p> </p><p> Players[0].Name := 'youruser0'; // UserName</p><p> Players[0].Pass := 'yourpass1'; // Password</p><p> Players[0].Nick := 'urus'; // 3/4 String of Name (ie: if accname is 'macroman' then set .nick at 'acro'). Script won't work if this is set wrong!</p><p> Players[0].Active := True; // Use this account? True / False</p><p>end;</p><p> </p><p>//####################################</p><p>//## World Selector ##</p><p>//####################################</p><p> </p><p>{************************************************* ******************************</p><p>function SelectWorld(Which: Integer): Boolean;</p><p>By: WT-Fakawi</p><p>Description: Selects World using ingame switcher.</p><p>************************************************** *****************************}</p><p> </p><p>Procedure WorldSelect;</p><p>Begin</p><p> OWorld := NWorld;</p><p> Repeat</p><p> if Players[CurrentPlayer].Booleans[0] = false then</p><p> Begin</p><p> Repeat</p><p> case random(54) of</p><p> 0: NWorld := 12;</p><p> 1: NWorld := 22 ;</p><p> 2: NWorld := 23;</p><p> 3: NWorld := 24;</p><p> 4: NWorld := 26</p><p> 5: NWorld := 27;</p><p> 6: NWorld := 28;</p><p> 7: NWorld := 31;</p><p> 8: NWorld := 36;</p><p> 9: NWorld := 39;</p><p> 10: NWorld := 42;</p><p> 11: NWorld := 44;</p><p> 12: NWorld := 45;</p><p> 13: NWorld := 46;</p><p> 14: NWorld := 48;</p><p> 15: NWorld := 54;</p><p> 16: NWorld := 56;</p><p> 17: NWorld := 58;</p><p> 18: NWorld := 59;</p><p> 19: NWorld := 64;</p><p> 20: NWorld := 65;</p><p> 21: NWorld := 66;</p><p> 22: NWorld := 70;</p><p> 23: NWorld := 71;</p><p> 24: NWorld := 76;</p><p> 25: NWorld := 77;</p><p> 26: NWorld := 78;</p><p> 27: NWorld := 79;</p><p> 28: NWorld := 88;</p><p> 29: NWorld := 89;</p><p> 30: NWorld := 91;</p><p> 31: NWorld := 92;</p><p> 32: NWorld := 97;</p><p> 33: NWorld := 98;</p><p> 34: NWorld := 99;</p><p> 35: NWorld := 100;</p><p> 36: NWorld := 103;</p><p> 37: NWorld := 104;</p><p> 38: NWorld := 110;</p><p> 39: NWorld := 111;</p><p> 40: NWorld := 112;</p><p> 41: NWorld := 114;</p><p> 42: NWorld := 115;</p><p> 43: NWorld := 116;</p><p> 44: NWorld := 120;</p><p> 45: NWorld := 121;</p><p> 46: NWorld := 124;</p><p> 47: NWorld := 129;</p><p> 48: NWorld := 130;</p><p> 49: NWorld := 131;</p><p> 50: NWorld := 132;</p><p> 51: NWorld := 137;</p><p> 52: NWorld := 138;</p><p> 53: NWorld := 143;</p><p> end;</p><p> until(Nworld <> OWorld);</p><p> end;</p><p> until(SelectWorld(NWorld));</p><p> ReportVars[1] := ReportVars[1] + 1;</p><p>end;</p><p> </p><p>{************************************************* ******************************</p><p>function SolveChatRandom: Boolean;</p><p>By: Nielsie95</p><p>Description: Solves a random when there's found one inchat.</p><p>************************************************** *****************************}</p><p> </p><p>function SolveChatRandom2: Boolean;</p><p>var</p><p> Event: string;</p><p>begin</p><p> if (not SolveChatRandoms) or (not AreTalking) then</p><p> Exit;</p><p> Event := GetNPCEvent;</p><p> </p><p> case Capitalize(Event) of</p><p> 'Unknown': Exit;</p><p> 'Pious Pete': // Candle Lighting</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Stupid Pete =(');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Mysterious Old Man': // Maze + Pinball</p><p> begin</p><p> if ((GetColor(83, 431) = 0) and (GetColor(88, 418) = 0)) or</p><p> ((GetColor(83, 430) = 0) and (GetColor(88, 417) = 0)) or</p><p> ((GetColor(151, 426) = 0) and (GetColor(470, 393) = 0) and</p><p> (GetColor(372, 370) = 128)) then</p><p> begin</p><p> SolvePinball;</p><p> end</p><p> Exit;</p><p> end;</p><p> 'Quiz Master': FindQuiz; // Quiz Master</p><p> 'Prison Pete': // ScapeRune balloons</p><p> begin</p><p> Inc(ScapeRunes);</p><p> Writeln(Players[CurrentPlayer].Name + ': Yay Balloon Animals!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Sergeant Damien': FindDemon; // Camo</p><p> 'Leo The Gravedigger': // Zombie</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': I Don' + chr(39) + 't Want To Dig Any Graves! ');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Evil Bob': // ScapeRune island</p><p> begin</p><p> Inc(ScapeRunes);</p><p> Writeln(Players[CurrentPlayer].Name + ': An Evil Cat? What is the World Coming To?!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Freaky Forester': // Lederhosen</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Since When Do Birds Have More Than One Tail...');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Mr Mordaut': // Surprise Exam</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': School? NO WAY!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> end;</p><p>end;</p><p> </p><p>{************************************************* ******************************</p><p>function FindNormalRandoms: Boolean;</p><p>by: The SRL Developers Team!... all time sexiness by Mutant</p><p>Description: Calls the 'normal' random checks.</p><p>************************************************** *****************************}</p><p> </p><p>function FindNormalRandoms2: Boolean;</p><p>var</p><p> i: Integer;</p><p>begin</p><p> for i := 0 to 14 do</p><p> begin</p><p> case I of</p><p> 0: if SolveChatRandom2 then</p><p> Result := True;</p><p> 1: if SolveTalkingRandom(Players[CurrentPlayer].Nick) then</p><p> Result := True;</p><p> 2: Respond;</p><p> 3: if FindTalk then</p><p> Result := True;</p><p> 4: if FindDead then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Noooo I died =...(');</p><p> Logout;</p><p> Result := True;</p><p> TerminateScript;</p><p> end;</p><p> 5: if FindMod then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Ooh A Moderator!');</p><p> Result := True;</p><p> end;</p><p> 6: if FindDemon then</p><p> Result := True;</p><p> 7: if FindMime then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Miming?! Why Can' + chr(39) + 't You Just Talk?');</p><p> TerminateScript;</p><p> Result := True;</p><p> end;</p><p> 8: if FindMaze then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Aww Mazes Are Too Hard =(');</p><p> TerminateScript;</p><p> Result := True;</p><p> end;</p><p> 9: if FindQuiz then</p><p> Result := True;</p><p> 10: if FindTalk then // Call it twice</p><p> Result := True;</p><p> 11: if FindLamp(LampSkill) then // Maybe we missed it?</p><p> Result := True;</p><p> 12: if (FindBox) then</p><p> begin</p><p> Result := True;</p><p> if (UseBoxSolver) then</p><p> SolveBox</p><p> else</p><p> GambleBox;</p><p> end;</p><p> 13:</p><p> begin</p><p> if NoGameTab then</p><p> begin</p><p> Wait(3000 + Random(300));</p><p> if SolveChatRandom2 then</p><p> begin</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> end;</p><p> 14: if RC then</p><p> Result := True;</p><p> end;</p><p> if Result then</p><p> Break;</p><p> end;</p><p> If Not(LoggedIn) then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Hey Why Are We Just Sitting Here?');</p><p> WorldSelect;</p><p> LogInPlayer;</p><p> end;</p><p>end;</p><p> </p><p>//####################################</p><p>//## AntiRandom Procedure ##</p><p>//####################################</p><p> </p><p>Procedure AntiRandoms;</p><p>begin</p><p> FindNormalRandoms2;</p><p> DwarfItem;</p><p>end;</p><p> </p><p>//####################################</p><p>//## Greeting Procedure ##</p><p>//####################################</p><p> </p><p>procedure A_Greeting;</p><p> begin</p><p> WriteLn('#################################');</p><p> WriteLn('## Welcome ##');</p><p> WriteLn('## You Are Using ##');</p><p> WriteLn('## A Script Created By Azzon ##');</p><p> WriteLn('## Enjoy ##');</p><p> WriteLn('## - Fr0zN S0uL Edit - ##');</p><p> WriteLn('#################################');</p><p> end;</p><p> </p><p>//####################################</p><p>//## Player Report Procedure ##</p><p>//####################################</p><p> </p><p>procedure PlayerReport;</p><p> begin</p><p> LevelsGained := GetSkillLevel('agility') - StartLevel;</p><p> XPNextLevel := XpTilNextLevel('agility', false);</p><p> NextLevel := GetSkillLevel('agility') + 1;</p><p> ClearDebug;</p><p> WriteLn('() (======================================)');</p><p> WriteLn('() (= Azzons Gnome Agility Course Runner =)');</p><p> WriteLn('() (= - Fr0zn S0ul Edit - =)');</p><p> WriteLn('() (======================================)');</p><p> WriteLn('() (= Laps Completed : ' + IntToStr(LapsMade));</p><p> WriteLn('() (= Laps Left : ' + IntToStr(Laps - LapsMade));</p><p> WriteLn('() (= Levels Gained : ' + IntToStr(LevelsGained));</p><p> Writeln('() (= ' + IntToStr(XPNextLevel) + ' XP To Level ' + IntToStr(NextLevel) + ' Agility');</p><p> Writeln('() (= Script Running For ' + TimeRunning);</p><p> WriteLn('() (======================================)');</p><p> SRLRandomsReport;</p><p>end;</p><p> </p><p>//####################################</p><p>//## CheckForLevel Procedure ##</p><p>//####################################</p><p> </p><p>procedure CheckForLevel;</p><p>begin</p><p> if Not(FindText(x,y,Players[CurrentPlayer].Nick,SmallChars,7,457,117,476)) then</p><p> begin</p><p> repeat</p><p> ClickToContinue;</p><p> until(FindText(x,y,Players[CurrentPlayer].Nick,SmallChars,7,457,117,476));</p><p> end;</p><p>end;</p><p> </p><p>//####################################</p><p>//## WaitOnFlag Procedure ##</p><p>//####################################</p><p> </p><p>procedure WaitOnFlag;</p><p> begin</p><p> WaitOnFlagLoops := 0;</p><p> repeat</p><p> Wait(500+random(250));</p><p> AntiRandoms;</p><p> CheckForLevel;</p><p> WaitOnFlagLoops := WaitOnFlagLoops + 1;</p><p> if WaitOnFlagLoops = 18 then</p><p> begin</p><p> Mouse(250, 210, 32, 32, true);</p><p> end;</p><p> if not(LoggedIn) then Exit;</p><p> until(FlagPresent = false);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 1st Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s1_LogBalance;</p><p> begin</p><p> tries := 0;</p><p> repeat</p><p> if (tries = 3) then</p><p> begin</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WaitOnFlag;</p><p> tries := 0;</p><p> end;</p><p> end;</p><p> AntiRandoms;</p><p> if FindObjCustom(x, y, ['Log balance'], [s_LogBalance_C1, s_LogBalance_C2, s_LogBalance_C3], g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 6, 6, true);</p><p> WaitOnFlag;</p><p> Wait(2250 + random(500));</p><p> end;</p><p> tries := tries + 1;</p><p> Wait(750+random(375));</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('carefully') or FindBlackChatMessage('safely') or FindBlackChatMessage('advanced'));</p><p> repeat</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('safely') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> case random(3) of</p><p> 0: Begin</p><p> Mouse(200, 260, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> 1: Begin</p><p> Mouse(240, 250, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> 2: Begin</p><p> Mouse(300, 250, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> end;</p><p> s1_Complete := true;</p><p> end</p><p> else LostCount := LostCount + 1;</p><p> if (not(LoggedIn)) then Exit;</p><p> if (LostCount >= 4) then</p><p> begin</p><p> Repeat</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WaitOnFlag;</p><p> tries := 0</p><p> break;</p><p> end</p><p> else if (tries = 3) then</p><p> Begin</p><p> Logout;</p><p> Writeln(Players[CurrentPlayer].Name + ': Could not find agility symbol. Logged Out.');</p><p> end;</p><p> tries := tries + 1;</p><p> wait(500 + random(250));</p><p> until(tries = 5);</p><p> end;</p><p> until(s1_Complete = true);</p><p> tries := 0</p><p> LostCount := 0</p><p> end;</p><p> </p><p>//####################################</p><p>//## 2nd Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s2_ObstacleNet;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle net', s_ObstacleNet_C1, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> Wait(750 + random(250));</p><p> end;</p><p> if FindBlackChatMessage('that from here') then</p><p> begin</p><p> GameTab(7);</p><p> Wait(100 + random(250));</p><p> Mouse(620,430,0,0,true);</p><p> Wait(100 + random(250));</p><p> Mouse(260,80,2,2,true);</p><p> WaitOnFlag;</p><p> end;</p><p> Wait(750+random(250));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('netting') or FindBlackChatMessage('advanced'));</p><p> repeat</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('netting') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s2_Complete := true;</p><p> wait(500 +random(250));</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s2_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 3rd Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s3_TreeBranch;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Tree branch', s_TreeBranch_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 3, 3, true);</p><p> end;</p><p> Wait(1000+random(500));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until (FindBlackChatMessage('tree.') or FindBlackChatMessage('platform'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(150));</p><p> if FindBlackChatMessage('platform') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> Mouse(325, 200, 20, 6, true);</p><p> WaitOnFlag;</p><p> s3_Complete := true;</p><p> end;</p><p> if Not(FindBlackChatMessage('platform') or FindBlackChatMessage('advanced')) then</p><p> begin</p><p> Mouse(278, 188, 0, 0, true);</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s3_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 4th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s4_BalancingRope;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Balancing rope', s_BalancingRope_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> end;</p><p> WaitOnFlag;</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('carefully') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(250));</p><p> if FindBlackChatMessage('tightrope') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s4_Complete := true;</p><p> end;</p><p> if FindBlackChatMessage('reach') then</p><p> begin</p><p> Mouse(x - 20 + random(10), y, 0, 0, true);</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s4_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 5th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s5_TreeBranch;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Tree branch', s_TreeBranch_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 3, 3, true);</p><p> WaitOnFlag;</p><p> end;</p><p> Wait(750+random(325));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('tree') or FindBlackChatMessage('ground') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(250+random(125));</p><p> if FindBlackChatMessage('ground') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> case random(3)+1 of</p><p> 1: Mouse(240, 50, 8, 8, true);</p><p> 2: Mouse(170, 75, 8, 8, true);</p><p> 3: Mouse(310, 45, 8, 8, true);</p><p> end;</p><p> s5_Complete := true;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s5_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 6th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s6_ObstacleNet;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle net', s_ObstacleNet_C2, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> WaitOnFlag</p><p> end;</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('not do that from') then</p><p> begin</p><p> s6_Complete := true;</p><p> break;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('netting') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('netting') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s6_Complete := true;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s6_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## Pipe Finder Procedure ##</p><p>//####################################</p><p> </p><p>procedure PipeFinding;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle pipe', s_ObstaclePipe_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 4, 4, true);</p><p> WaitOnFlag;</p><p> PlayerReport;</p><p> Wait(2000+random(1000));</p><p> if FindBlackChatMessage('this side') or FindBlackChatMessage('enter') or FindBlackChatMessage('ide')then</p><p> begin</p><p> FoundPipe:=True</p><p> end;</p><p> if FindBlackChatMessage('being') then</p><p> begin</p><p> FoundPipe := false;</p><p> end else</p><p> begin</p><p> FoundPipe := true;</p><p> WaitOnPipe := 0;</p><p> end;</p><p> end;</p><p> Wait(500+random(250));</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FoundPipe = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 7th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s7_ObstaclePipe;</p><p> begin</p><p> PipeFinding;</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(250));</p><p> if FindColorTolerance(x, y, s_Mushroom_C, msx1, msy1, msx2, msy2, g_ColorTol) then</p><p> begin</p><p> tries := 0;</p><p> repeat</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WalkingToStart := true;</p><p> WaitOnFlag;</p><p> LapComplete := true;</p><p> end;</p><p> tries := tries + 1;</p><p> if (not(LoggedIn)) then Exit;</p><p> until((WalkingToStart = true) or (tries = 12));</p><p> if (tries = 12) then</p><p> begin</p><p> LogOut;</p><p> WriteLn('Couldnt find the agility symbol.');</p><p> end;</p><p> end else</p><p> begin</p><p> WaitOnPipe := WaitOnPipe + 1;</p><p> end;</p><p> if (WaitOnPipe = 3) then</p><p> begin</p><p> PipeFinding;</p><p> end;</p><p> until(LapComplete = true);</p><p> tries := 0</p><p> end;</p><p> </p><p>//####################################</p><p>//## Global Script Setup ##</p><p>//####################################</p><p> </p><p>procedure SetupAgilityRunner;</p><p> begin</p><p> SetupSRL;</p><p> ScriptID := '353'</p><p> ClearDebug;</p><p> Disguise('iTunes');</p><p> A_Greeting;</p><p> ActivateClient;</p><p> Wait(250+random(125));</p><p> FirstLap := true;</p><p> DeclarePlayers;</p><p> WriteLn(Players[CurrentPlayer].Name + ': "Time to Run!"');</p><p> GetApplication.MINIMIZE;</p><p> LoginPlayer;</p><p> LapsMade := 1</p><p> LapsTillLog := LogAfter + random(5);</p><p> LogCounter := 0;</p><p> LostCount := 0;</p><p> OWorld := 0;</p><p> NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, Upchars);</p><p> StartLevel := GetSkillLevel('agility');</p><p> HighestAngle;</p><p> MakeCompass('N');</p><p> end;</p><p> </p><p>//################################################## ######################</p><p>//################################################## ######################</p><p> </p><p>//####################################</p><p>//## Main Loop ##</p><p>//####################################</p><p> </p><p>begin</p><p> SetupAgilityRunner;</p><p> Wait(100+random(50));</p><p> Mouse(32,491,0,0,true);</p><p> SetChat('friends', 1);</p><p> SetChat('off', 2);</p><p> repeat</p><p> if (not(LoggedIn)) then Exit;</p><p> if (FirstLap = true) then</p><p> begin</p><p> LapsTillCheckRun := CheckRunLapDelay;</p><p> SetRun(true);</p><p> FirstLap := false;</p><p> s1_LogBalance;</p><p> end;</p><p> if LapsTillCheckRun <= 0 then</p><p> begin</p><p> LapsTillCheckRun := CheckRunLapDelay;</p><p> SetRun(true);</p><p> end;</p><p> if NewLap = true then</p><p> begin</p><p> NewLap := false;</p><p> LapsTillCheckRun := LapsTillCheckRun - 1;</p><p> HighestAngle;</p><p> MakeCompass('N');</p><p> s1_LogBalance;</p><p> end;</p><p> if s1_Complete = true then</p><p> begin</p><p> s1_Complete := false;</p><p> s2_ObstacleNet;</p><p> end;</p><p> if s2_Complete = true then</p><p> begin</p><p> s2_Complete := false;</p><p> s3_TreeBranch;</p><p> end;</p><p> if s3_Complete = true then</p><p> begin</p><p> s3_Complete := false;</p><p> s4_BalancingRope;</p><p> end;</p><p> if s4_Complete = true then</p><p> begin</p><p> s4_Complete := false;</p><p> s5_TreeBranch;</p><p> end;</p><p> if s5_Complete = true then</p><p> begin</p><p> s5_Complete := false;</p><p> s6_ObstacleNet;</p><p> end;</p><p> if s6_Complete = true then</p><p> begin</p><p> s6_Complete := false;</p><p> s7_ObstaclePipe;</p><p> end;</p><p> if LapComplete = true then</p><p> begin</p><p> LapComplete := false;</p><p> LapsMade := LapsMade + 1;</p><p> ReportVars[0] := ReportVars[0] + 1;</p><p> LapsTillLog := LapsTillLog - 1;</p><p> NewLap := true;</p><p> end;</p><p> if (LapsTillLog <= 0) then</p><p> begin</p><p> LogOut;</p><p> wait(500 + random(250));</p><p> LogCounter := LogCounter + 1;</p><p> if LogOutWait = true then</p><p> begin</p><p> if (LogOutWaitEvery <= LogCounter) then</p><p> begin</p><p> LogCounter := 0;</p><p> Wait(LogOutWaitFor * 60000);</p><p> end;</p><p> end;</p><p> WorldSelect;</p><p> LoginPlayer;</p><p> LapsTillLog := LogAfter + random(5)</p><p> SetRun(true);</p><p> end;</p><p> until(LapsMade >= Laps);</p><p> if (LapsMade >= Laps) then</p><p> begin</p><p> LogOut;</p><p> WriteLn('Training Was A Success.');</p><p> WriteLn('Thanks For Using My Script! Have a Nice Day =)');</p><p> end else</p><p> begin</p><p> WriteLn('A Problem Was Encountered During Training.');</p><p> WriteLn('Thanks For Using My Script! Have a Nice Day =)');</p><p> end;</p><p>end.</p><p> </p><p>//################################################## ######################</p><p>//################################################## ######################
Hey,
When I run the script below I get this error:
Failed when compiling
Line 414: [Error] (15604:48): Invalid number of parameters in script C:\Documents and Settings\xxx\Desktop\GnomeAgilityRunner v3.0.scar
I am using SCAR Divi 3.12 and SRL4. (Note I uploaded the original script, without my account info)
ScarScript:By Drunkenoldma
//################################################## #######</p><p>//################################################## #######</p><p>//#### Azzon's Gnome Agility Runner ####</p><p>//#### Version: 3.0 ####</p><p>//#### - Fr0zn S0ul Edit - ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>//#### ####</p><p>//#### Hello, and Welcome. I would like to start ####</p><p>//#### off by saying thank you for using this ####</p><p>//#### script. If you have any questions, ####</p><p>//#### suggestions, or problems related to this ####</p><p>//#### script, then feel free to post on the ####</p><p>//#### thread or send me a pm. ####</p><p>//#### ####</p><p>//#### You can find the player adjustable ####</p><p>//#### variables for the script between lines ####</p><p>//#### 76 and 94. ####</p><p>//#### ####</p><p>//#### You can setup the players using this ####</p><p>//#### script between lines 104 and 118. Due note ####</p><p>//#### that the script is only designed for a ####</p><p>//#### single player, and the purpose of the ####</p><p>//#### player setup is for Anti-Randoms. ####</p><p>//#### ####</p><p>//#### Thank you for using this script. ####</p><p>//#### - Azzon ####</p><p>//#### ####</p><p>//#### This script is made using SCAR DIVI v3.12 ####</p><p>//#### and SRL 4. ####</p><p>//#### - Fr0zn S0ul ####</p><p>//#### ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>//#### ####</p><p>//#### Fr0zn S0ul's additions: ####</p><p>//#### *Made script acceptable for new runescape ####</p><p>//#### interface and SRL 4 / SCAR 3.12. ####</p><p>//#### *Added LogOut procedure for less randoms ####</p><p>//#### and switch of players - requires your own ####</p><p>//#### addition for extra players sorry, most ####</p><p>//#### people only have one members account. ####</p><p>//#### *Added LogOutWait variables. These mean that ####</p><p>//#### after logging out and back in a certain ####</p><p>//#### amount of times, your player will wait for ####</p><p>//#### an amount of minutes before logging back in. ####</p><p>//#### *Made script run a lot faster by removing and ####</p><p>//#### reducing Wait times. ####</p><p>//#### *Added Levels Gained and XP to next level ####</p><p>//#### in the Player Report. ####</p><p>//#### *Added more failsafes, as player got stuck ####</p><p>//#### behind nets and pipe sometimes. ####</p><p>//#### *Reduced the extra random x and y axis ####</p><p>//#### additions, as they made player go slightly ####</p><p>//#### off course sometimes. ####</p><p>//#### *Remodeled the Declare Players procedure. ####</p><p>//#### *Slightly adjusted some of the obstacle ####</p><p>//#### colors. ####</p><p>//#### ####</p><p>//################################################## #######</p><p>//################################################## #######</p><p>program GnomeAgilityRunner; //931 Lines, With Spacers And Procedure Headers</p><p>{.include SRL/SRL.scar}</p><p> </p><p>var</p><p> x, y, LapsMade, LogAfter, LapsTillLog, tries, WaitOnPipe, LapsTillCheckRun, WaitOnFlagLoops : Integer;</p><p> LostCount, LogOutWaitFor, LogOutWaitEvery, LogCounter, StartLevel, LevelsGained : Integer;</p><p> NextLevel, XPNextLevel, NWorld, OWorld : Integer;</p><p> FirstLap, s1_Complete, s2_Complete, s3_Complete, s4_Complete : Boolean;</p><p> s5_Complete, s6_Complete, NewLap, LapComplete, FoundPipe, WalkingToStart, LogOutWait : Boolean;</p><p> </p><p>{.include SRL/SRL/misc/WorldSwitcher.scar}</p><p> </p><p>//################################################## ##############</p><p>//## Manual Player Setup ##</p><p>//################################################## ##############</p><p> </p><p>const</p><p> g_ColorTol = 16; //Game Screen Color Tolerance. Lowering Will Make Script Run Faster. Too Low And It Won't Work!</p><p> Laps = 150500; //Number Of Laps You Want The Script To Run For</p><p> CheckRunLapDelay = 8; //Number Of Laps To Complete Before Calling CheckRun Again</p><p> </p><p> </p><p>//################################</p><p>//## Note: Unless You Experience##</p><p>//## Color Problems, It Is ##</p><p>//## Recommended To Leave The ##</p><p>//## Color's As They Are. ##</p><p>//################################</p><p> </p><p> s_LogBalance_C1 = 868973; // Obstacle 1, Log Color</p><p> s_LogBalance_C2 = 606056; // Obstacle 1, Log Color</p><p> s_LogBalance_C3 = 602705; // Obstacle 1, Log Color</p><p> s_ObstacleNet_C1 = 5530233; //Obstacle 2, Net Color</p><p> s_ObstacleNet_C2 = 869744; //Obstacle 6, Net Color</p><p> s_TreeBranch_C = 3431793; //Obstacle 3, and Obstacle 5, Tree Color</p><p> s_BalancingRope_C = 4613245; //Obstacle 4, Rope Color</p><p> s_ObstaclePipe_C = 5592411; //Obstacle 7, Pipe Color</p><p> s_Mushroom_C = 2576031; //End Of Obstacle 7, Mushroom Color</p><p> </p><p>//################################################## ##############</p><p>//################################################## ##############</p><p> </p><p>//####################################</p><p>//## Player Setup Location ##</p><p>//####################################</p><p> </p><p>Procedure DeclarePlayers;</p><p>begin</p><p> SRLID := '0'; // Don't have this? Please Register at:</p><p> SRLPassword := ''; // <a href="http://www.stats.srl-forums.com/" target="_blank">http://www.stats.srl-forums.com/</a></p><p> //You must let this script connect to <a href="http://www.villu-reborn.com/stats/stats.php" target="_blank">www.villu-reborn.com/stats/stats.php</a> to send script statistics to SRL!</p><p> </p><p> HowManyPlayers := 1; // How many players to use.</p><p> NumberOfPlayers( HowManyPlayers ); // Leave this.</p><p> CurrentPlayer := 0; // Start Player? ie. 0 = Players[0].name</p><p> </p><p> LogAfter := 10; // Log Out every how many laps?</p><p> LogOutWait := true; // Every (LogOutWaitevery) logouts, log out for (LogOutWaitFor) extra amount of time?</p><p> LogOutWaitEvery := 8; // How often to wait extra time at logout</p><p> LogOutWaitFor := 10 + random(5); // Wait for how many extra MINUTES plus random(x) amount of time at LogOutWait?</p><p> //LogOutWaitFor is in MINUTES!</p><p> </p><p> </p><p> Players[0].Name := 'youruser0'; // UserName</p><p> Players[0].Pass := 'yourpass1'; // Password</p><p> Players[0].Nick := 'urus'; // 3/4 String of Name (ie: if accname is 'macroman' then set .nick at 'acro'). Script won't work if this is set wrong!</p><p> Players[0].Active := True; // Use this account? True / False</p><p>end;</p><p> </p><p>//####################################</p><p>//## World Selector ##</p><p>//####################################</p><p> </p><p>{************************************************* ******************************</p><p>function SelectWorld(Which: Integer): Boolean;</p><p>By: WT-Fakawi</p><p>Description: Selects World using ingame switcher.</p><p>************************************************** *****************************}</p><p> </p><p>Procedure WorldSelect;</p><p>Begin</p><p> OWorld := NWorld;</p><p> Repeat</p><p> if Players[CurrentPlayer].Booleans[0] = false then</p><p> Begin</p><p> Repeat</p><p> case random(54) of</p><p> 0: NWorld := 12;</p><p> 1: NWorld := 22 ;</p><p> 2: NWorld := 23;</p><p> 3: NWorld := 24;</p><p> 4: NWorld := 26</p><p> 5: NWorld := 27;</p><p> 6: NWorld := 28;</p><p> 7: NWorld := 31;</p><p> 8: NWorld := 36;</p><p> 9: NWorld := 39;</p><p> 10: NWorld := 42;</p><p> 11: NWorld := 44;</p><p> 12: NWorld := 45;</p><p> 13: NWorld := 46;</p><p> 14: NWorld := 48;</p><p> 15: NWorld := 54;</p><p> 16: NWorld := 56;</p><p> 17: NWorld := 58;</p><p> 18: NWorld := 59;</p><p> 19: NWorld := 64;</p><p> 20: NWorld := 65;</p><p> 21: NWorld := 66;</p><p> 22: NWorld := 70;</p><p> 23: NWorld := 71;</p><p> 24: NWorld := 76;</p><p> 25: NWorld := 77;</p><p> 26: NWorld := 78;</p><p> 27: NWorld := 79;</p><p> 28: NWorld := 88;</p><p> 29: NWorld := 89;</p><p> 30: NWorld := 91;</p><p> 31: NWorld := 92;</p><p> 32: NWorld := 97;</p><p> 33: NWorld := 98;</p><p> 34: NWorld := 99;</p><p> 35: NWorld := 100;</p><p> 36: NWorld := 103;</p><p> 37: NWorld := 104;</p><p> 38: NWorld := 110;</p><p> 39: NWorld := 111;</p><p> 40: NWorld := 112;</p><p> 41: NWorld := 114;</p><p> 42: NWorld := 115;</p><p> 43: NWorld := 116;</p><p> 44: NWorld := 120;</p><p> 45: NWorld := 121;</p><p> 46: NWorld := 124;</p><p> 47: NWorld := 129;</p><p> 48: NWorld := 130;</p><p> 49: NWorld := 131;</p><p> 50: NWorld := 132;</p><p> 51: NWorld := 137;</p><p> 52: NWorld := 138;</p><p> 53: NWorld := 143;</p><p> end;</p><p> until(Nworld <> OWorld);</p><p> end;</p><p> until(SelectWorld(NWorld));</p><p> ReportVars[1] := ReportVars[1] + 1;</p><p>end;</p><p> </p><p>{************************************************* ******************************</p><p>function SolveChatRandom: Boolean;</p><p>By: Nielsie95</p><p>Description: Solves a random when there's found one inchat.</p><p>************************************************** *****************************}</p><p> </p><p>function SolveChatRandom2: Boolean;</p><p>var</p><p> Event: string;</p><p>begin</p><p> if (not SolveChatRandoms) or (not AreTalking) then</p><p> Exit;</p><p> Event := GetNPCEvent;</p><p> </p><p> case Capitalize(Event) of</p><p> 'Unknown': Exit;</p><p> 'Pious Pete': // Candle Lighting</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Stupid Pete =(');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Mysterious Old Man': // Maze + Pinball</p><p> begin</p><p> if ((GetColor(83, 431) = 0) and (GetColor(88, 418) = 0)) or</p><p> ((GetColor(83, 430) = 0) and (GetColor(88, 417) = 0)) or</p><p> ((GetColor(151, 426) = 0) and (GetColor(470, 393) = 0) and</p><p> (GetColor(372, 370) = 128)) then</p><p> begin</p><p> SolvePinball;</p><p> end</p><p> Exit;</p><p> end;</p><p> 'Quiz Master': FindQuiz; // Quiz Master</p><p> 'Prison Pete': // ScapeRune balloons</p><p> begin</p><p> Inc(ScapeRunes);</p><p> Writeln(Players[CurrentPlayer].Name + ': Yay Balloon Animals!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Sergeant Damien': FindDemon; // Camo</p><p> 'Leo The Gravedigger': // Zombie</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': I Don' + chr(39) + 't Want To Dig Any Graves! ');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Evil Bob': // ScapeRune island</p><p> begin</p><p> Inc(ScapeRunes);</p><p> Writeln(Players[CurrentPlayer].Name + ': An Evil Cat? What is the World Coming To?!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Freaky Forester': // Lederhosen</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Since When Do Birds Have More Than One Tail...');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> 'Mr Mordaut': // Surprise Exam</p><p> begin</p><p> Writeln(Players[CurrentPlayer].Name + ': School? NO WAY!');</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> end;</p><p>end;</p><p> </p><p>{************************************************* ******************************</p><p>function FindNormalRandoms: Boolean;</p><p>by: The SRL Developers Team!... all time sexiness by Mutant</p><p>Description: Calls the 'normal' random checks.</p><p>************************************************** *****************************}</p><p> </p><p>function FindNormalRandoms2: Boolean;</p><p>var</p><p> i: Integer;</p><p>begin</p><p> for i := 0 to 14 do</p><p> begin</p><p> case I of</p><p> 0: if SolveChatRandom2 then</p><p> Result := True;</p><p> 1: if SolveTalkingRandom(Players[CurrentPlayer].Nick) then</p><p> Result := True;</p><p> 2: Respond;</p><p> 3: if FindTalk then</p><p> Result := True;</p><p> 4: if FindDead then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Noooo I died =...(');</p><p> Logout;</p><p> Result := True;</p><p> TerminateScript;</p><p> end;</p><p> 5: if FindMod then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Ooh A Moderator!');</p><p> Result := True;</p><p> end;</p><p> 6: if FindDemon then</p><p> Result := True;</p><p> 7: if FindMime then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Miming?! Why Can' + chr(39) + 't You Just Talk?');</p><p> TerminateScript;</p><p> Result := True;</p><p> end;</p><p> 8: if FindMaze then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Aww Mazes Are Too Hard =(');</p><p> TerminateScript;</p><p> Result := True;</p><p> end;</p><p> 9: if FindQuiz then</p><p> Result := True;</p><p> 10: if FindTalk then // Call it twice</p><p> Result := True;</p><p> 11: if FindLamp(LampSkill) then // Maybe we missed it?</p><p> Result := True;</p><p> 12: if (FindBox) then</p><p> begin</p><p> Result := True;</p><p> if (UseBoxSolver) then</p><p> SolveBox</p><p> else</p><p> GambleBox;</p><p> end;</p><p> 13:</p><p> begin</p><p> if NoGameTab then</p><p> begin</p><p> Wait(3000 + Random(300));</p><p> if SolveChatRandom2 then</p><p> begin</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> Logout;</p><p> TerminateScript;</p><p> Result := True;</p><p> Exit;</p><p> end;</p><p> end;</p><p> 14: if RC then</p><p> Result := True;</p><p> end;</p><p> if Result then</p><p> Break;</p><p> end;</p><p> If Not(LoggedIn) then</p><p> Begin</p><p> Writeln(Players[CurrentPlayer].Name + ': Hey Why Are We Just Sitting Here?');</p><p> WorldSelect;</p><p> LogInPlayer;</p><p> end;</p><p>end;</p><p> </p><p>//####################################</p><p>//## AntiRandom Procedure ##</p><p>//####################################</p><p> </p><p>Procedure AntiRandoms;</p><p>begin</p><p> FindNormalRandoms2;</p><p> DwarfItem;</p><p>end;</p><p> </p><p>//####################################</p><p>//## Greeting Procedure ##</p><p>//####################################</p><p> </p><p>procedure A_Greeting;</p><p> begin</p><p> WriteLn('#################################');</p><p> WriteLn('## Welcome ##');</p><p> WriteLn('## You Are Using ##');</p><p> WriteLn('## A Script Created By Azzon ##');</p><p> WriteLn('## Enjoy ##');</p><p> WriteLn('## - Fr0zN S0uL Edit - ##');</p><p> WriteLn('#################################');</p><p> end;</p><p> </p><p>//####################################</p><p>//## Player Report Procedure ##</p><p>//####################################</p><p> </p><p>procedure PlayerReport;</p><p> begin</p><p> LevelsGained := GetSkillLevel('agility') - StartLevel;</p><p> XPNextLevel := XpTilNextLevel('agility', false);</p><p> NextLevel := GetSkillLevel('agility') + 1;</p><p> ClearDebug;</p><p> WriteLn('() (======================================)');</p><p> WriteLn('() (= Azzons Gnome Agility Course Runner =)');</p><p> WriteLn('() (= - Fr0zn S0ul Edit - =)');</p><p> WriteLn('() (======================================)');</p><p> WriteLn('() (= Laps Completed : ' + IntToStr(LapsMade));</p><p> WriteLn('() (= Laps Left : ' + IntToStr(Laps - LapsMade));</p><p> WriteLn('() (= Levels Gained : ' + IntToStr(LevelsGained));</p><p> Writeln('() (= ' + IntToStr(XPNextLevel) + ' XP To Level ' + IntToStr(NextLevel) + ' Agility');</p><p> Writeln('() (= Script Running For ' + TimeRunning);</p><p> WriteLn('() (======================================)');</p><p> SRLRandomsReport;</p><p>end;</p><p> </p><p>//####################################</p><p>//## CheckForLevel Procedure ##</p><p>//####################################</p><p> </p><p>procedure CheckForLevel;</p><p>begin</p><p> if Not(FindText(x,y,Players[CurrentPlayer].Nick,SmallChars,7,457,117,476)) then</p><p> begin</p><p> repeat</p><p> ClickToContinue;</p><p> until(FindText(x,y,Players[CurrentPlayer].Nick,SmallChars,7,457,117,476));</p><p> end;</p><p>end;</p><p> </p><p>//####################################</p><p>//## WaitOnFlag Procedure ##</p><p>//####################################</p><p> </p><p>procedure WaitOnFlag;</p><p> begin</p><p> WaitOnFlagLoops := 0;</p><p> repeat</p><p> Wait(500+random(250));</p><p> AntiRandoms;</p><p> CheckForLevel;</p><p> WaitOnFlagLoops := WaitOnFlagLoops + 1;</p><p> if WaitOnFlagLoops = 18 then</p><p> begin</p><p> Mouse(250, 210, 32, 32, true);</p><p> end;</p><p> if not(LoggedIn) then Exit;</p><p> until(FlagPresent = false);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 1st Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s1_LogBalance;</p><p> begin</p><p> tries := 0;</p><p> repeat</p><p> if (tries = 3) then</p><p> begin</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WaitOnFlag;</p><p> tries := 0;</p><p> end;</p><p> end;</p><p> AntiRandoms;</p><p> if FindObjCustom(x, y, ['Log balance'], [s_LogBalance_C1, s_LogBalance_C2, s_LogBalance_C3], g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 6, 6, true);</p><p> WaitOnFlag;</p><p> Wait(2250 + random(500));</p><p> end;</p><p> tries := tries + 1;</p><p> Wait(750+random(375));</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('carefully') or FindBlackChatMessage('safely') or FindBlackChatMessage('advanced'));</p><p> repeat</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('safely') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> case random(3) of</p><p> 0: Begin</p><p> Mouse(200, 260, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> 1: Begin</p><p> Mouse(240, 250, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> 2: Begin</p><p> Mouse(300, 250, 32, 32, true);</p><p> wait(100 + random(100));</p><p> end;</p><p> end;</p><p> s1_Complete := true;</p><p> end</p><p> else LostCount := LostCount + 1;</p><p> if (not(LoggedIn)) then Exit;</p><p> if (LostCount >= 4) then</p><p> begin</p><p> Repeat</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WaitOnFlag;</p><p> tries := 0</p><p> break;</p><p> end</p><p> else if (tries = 3) then</p><p> Begin</p><p> Logout;</p><p> Writeln(Players[CurrentPlayer].Name + ': Could not find agility symbol. Logged Out.');</p><p> end;</p><p> tries := tries + 1;</p><p> wait(500 + random(250));</p><p> until(tries = 5);</p><p> end;</p><p> until(s1_Complete = true);</p><p> tries := 0</p><p> LostCount := 0</p><p> end;</p><p> </p><p>//####################################</p><p>//## 2nd Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s2_ObstacleNet;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle net', s_ObstacleNet_C1, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> Wait(750 + random(250));</p><p> end;</p><p> if FindBlackChatMessage('that from here') then</p><p> begin</p><p> GameTab(7);</p><p> Wait(100 + random(250));</p><p> Mouse(620,430,0,0,true);</p><p> Wait(100 + random(250));</p><p> Mouse(260,80,2,2,true);</p><p> WaitOnFlag;</p><p> end;</p><p> Wait(750+random(250));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('netting') or FindBlackChatMessage('advanced'));</p><p> repeat</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('netting') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s2_Complete := true;</p><p> wait(500 +random(250));</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s2_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 3rd Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s3_TreeBranch;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Tree branch', s_TreeBranch_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 3, 3, true);</p><p> end;</p><p> Wait(1000+random(500));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until (FindBlackChatMessage('tree.') or FindBlackChatMessage('platform'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(150));</p><p> if FindBlackChatMessage('platform') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> Mouse(325, 200, 20, 6, true);</p><p> WaitOnFlag;</p><p> s3_Complete := true;</p><p> end;</p><p> if Not(FindBlackChatMessage('platform') or FindBlackChatMessage('advanced')) then</p><p> begin</p><p> Mouse(278, 188, 0, 0, true);</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s3_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 4th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s4_BalancingRope;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Balancing rope', s_BalancingRope_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> end;</p><p> WaitOnFlag;</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('carefully') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(250));</p><p> if FindBlackChatMessage('tightrope') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s4_Complete := true;</p><p> end;</p><p> if FindBlackChatMessage('reach') then</p><p> begin</p><p> Mouse(x - 20 + random(10), y, 0, 0, true);</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s4_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 5th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s5_TreeBranch;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Tree branch', s_TreeBranch_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 3, 3, true);</p><p> WaitOnFlag;</p><p> end;</p><p> Wait(750+random(325));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('tree') or FindBlackChatMessage('ground') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(250+random(125));</p><p> if FindBlackChatMessage('ground') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> case random(3)+1 of</p><p> 1: Mouse(240, 50, 8, 8, true);</p><p> 2: Mouse(170, 75, 8, 8, true);</p><p> 3: Mouse(310, 45, 8, 8, true);</p><p> end;</p><p> s5_Complete := true;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s5_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 6th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s6_ObstacleNet;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle net', s_ObstacleNet_C2, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 2, 2, true);</p><p> WaitOnFlag</p><p> end;</p><p> Wait(250+random(125));</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('not do that from') then</p><p> begin</p><p> s6_Complete := true;</p><p> break;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FindBlackChatMessage('netting') or FindBlackChatMessage('advanced'));</p><p> Wait(250+random(125));</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> if FindBlackChatMessage('netting') or FindBlackChatMessage('advanced') then</p><p> begin</p><p> s6_Complete := true;</p><p> end;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(s6_Complete = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## Pipe Finder Procedure ##</p><p>//####################################</p><p> </p><p>procedure PipeFinding;</p><p> begin</p><p> repeat</p><p> WaitOnFlag;</p><p> if FindObj(x, y, 'Obstacle pipe', s_ObstaclePipe_C, g_ColorTol) then</p><p> begin</p><p> Mouse(x, y, 4, 4, true);</p><p> WaitOnFlag;</p><p> PlayerReport;</p><p> Wait(2000+random(1000));</p><p> if FindBlackChatMessage('this side') or FindBlackChatMessage('enter') or FindBlackChatMessage('ide')then</p><p> begin</p><p> FoundPipe:=True</p><p> end;</p><p> if FindBlackChatMessage('being') then</p><p> begin</p><p> FoundPipe := false;</p><p> end else</p><p> begin</p><p> FoundPipe := true;</p><p> WaitOnPipe := 0;</p><p> end;</p><p> end;</p><p> Wait(500+random(250));</p><p> AntiRandoms;</p><p> if (not(LoggedIn)) then Exit;</p><p> until(FoundPipe = true);</p><p> end;</p><p> </p><p>//####################################</p><p>//## 7th Obstacle Procedure ##</p><p>//####################################</p><p> </p><p>procedure s7_ObstaclePipe;</p><p> begin</p><p> PipeFinding;</p><p> repeat</p><p> CheckForLevel;</p><p> AntiRandoms;</p><p> Wait(500+random(250));</p><p> if FindColorTolerance(x, y, s_Mushroom_C, msx1, msy1, msx2, msy2, g_ColorTol) then</p><p> begin</p><p> tries := 0;</p><p> repeat</p><p> if FindSymbol(x, y, 'agility') then</p><p> begin</p><p> Mouse(x, y + 10, 6, 6, true);</p><p> WalkingToStart := true;</p><p> WaitOnFlag;</p><p> LapComplete := true;</p><p> end;</p><p> tries := tries + 1;</p><p> if (not(LoggedIn)) then Exit;</p><p> until((WalkingToStart = true) or (tries = 12));</p><p> if (tries = 12) then</p><p> begin</p><p> LogOut;</p><p> WriteLn('Couldnt find the agility symbol.');</p><p> end;</p><p> end else</p><p> begin</p><p> WaitOnPipe := WaitOnPipe + 1;</p><p> end;</p><p> if (WaitOnPipe = 3) then</p><p> begin</p><p> PipeFinding;</p><p> end;</p><p> until(LapComplete = true);</p><p> tries := 0</p><p> end;</p><p> </p><p>//####################################</p><p>//## Global Script Setup ##</p><p>//####################################</p><p> </p><p>procedure SetupAgilityRunner;</p><p> begin</p><p> SetupSRL;</p><p> ScriptID := '353'</p><p> ClearDebug;</p><p> Disguise('iTunes');</p><p> A_Greeting;</p><p> ActivateClient;</p><p> Wait(250+random(125));</p><p> FirstLap := true;</p><p> DeclarePlayers;</p><p> WriteLn(Players[CurrentPlayer].Name + ': "Time to Run!"');</p><p> GetApplication.MINIMIZE;</p><p> LoginPlayer;</p><p> LapsMade := 1</p><p> LapsTillLog := LogAfter + random(5);</p><p> LogCounter := 0;</p><p> LostCount := 0;</p><p> OWorld := 0;</p><p> NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, Upchars);</p><p> StartLevel := GetSkillLevel('agility');</p><p> HighestAngle;</p><p> MakeCompass('N');</p><p> end;</p><p> </p><p>//################################################## ######################</p><p>//################################################## ######################</p><p> </p><p>//####################################</p><p>//## Main Loop ##</p><p>//####################################</p><p> </p><p>begin</p><p> SetupAgilityRunner;</p><p> Wait(100+random(50));</p><p> Mouse(32,491,0,0,true);</p><p> SetChat('friends', 1);</p><p> SetChat('off', 2);</p><p> repeat</p><p> if (not(LoggedIn)) then Exit;</p><p> if (FirstLap = true) then</p><p> begin</p><p> LapsTillCheckRun := CheckRunLapDelay;</p><p> SetRun(true);</p><p> FirstLap := false;</p><p> s1_LogBalance;</p><p> end;</p><p> if LapsTillCheckRun <= 0 then</p><p> begin</p><p> LapsTillCheckRun := CheckRunLapDelay;</p><p> SetRun(true);</p><p> end;</p><p> if NewLap = true then</p><p> begin</p><p> NewLap := false;</p><p> LapsTillCheckRun := LapsTillCheckRun - 1;</p><p> HighestAngle;</p><p> MakeCompass('N');</p><p> s1_LogBalance;</p><p> end;</p><p> if s1_Complete = true then</p><p> begin</p><p> s1_Complete := false;</p><p> s2_ObstacleNet;</p><p> end;</p><p> if s2_Complete = true then</p><p> begin</p><p> s2_Complete := false;</p><p> s3_TreeBranch;</p><p> end;</p><p> if s3_Complete = true then</p><p> begin</p><p> s3_Complete := false;</p><p> s4_BalancingRope;</p><p> end;</p><p> if s4_Complete = true then</p><p> begin</p><p> s4_Complete := false;</p><p> s5_TreeBranch;</p><p> end;</p><p> if s5_Complete = true then</p><p> begin</p><p> s5_Complete := false;</p><p> s6_ObstacleNet;</p><p> end;</p><p> if s6_Complete = true then</p><p> begin</p><p> s6_Complete := false;</p><p> s7_ObstaclePipe;</p><p> end;</p><p> if LapComplete = true then</p><p> begin</p><p> LapComplete := false;</p><p> LapsMade := LapsMade + 1;</p><p> ReportVars[0] := ReportVars[0] + 1;</p><p> LapsTillLog := LapsTillLog - 1;</p><p> NewLap := true;</p><p> end;</p><p> if (LapsTillLog <= 0) then</p><p> begin</p><p> LogOut;</p><p> wait(500 + random(250));</p><p> LogCounter := LogCounter + 1;</p><p> if LogOutWait = true then</p><p> begin</p><p> if (LogOutWaitEvery <= LogCounter) then</p><p> begin</p><p> LogCounter := 0;</p><p> Wait(LogOutWaitFor * 60000);</p><p> end;</p><p> end;</p><p> WorldSelect;</p><p> LoginPlayer;</p><p> LapsTillLog := LogAfter + random(5)</p><p> SetRun(true);</p><p> end;</p><p> until(LapsMade >= Laps);</p><p> if (LapsMade >= Laps) then</p><p> begin</p><p> LogOut;</p><p> WriteLn('Training Was A Success.');</p><p> WriteLn('Thanks For Using My Script! Have a Nice Day =)');</p><p> end else</p><p> begin</p><p> WriteLn('A Problem Was Encountered During Training.');</p><p> WriteLn('Thanks For Using My Script! Have a Nice Day =)');</p><p> end;</p><p>end.</p><p> </p><p>//################################################## ######################</p><p>//################################################## ######################