Results 1 to 2 of 2

Thread: First Script Help !!

  1. #1
    Join Date
    Sep 2006
    Posts
    457
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    First Script Help !!

    Ok this is my first script i was looking for some help on a fighting procedure. As you can see i hvnt made my own.

    Any suggestions are helpful.

    Any ideas plz tell me.

    Errors plz tell me. still working on it

    Plz feedback!!!



    program Jesus45Chickenmassacre;
    {.include SRL\SRL.scar}


    ///////////////////////////////////////////////////////////////
    // /////// ////// ////// // // ////// //
    // // /// // // // // //
    // // // ////// //// // // ///// //
    // // // /// // // // // //
    // ///// /////// ////// ///// ////// //
    ///////////////////////////////////////////////////////////////
    {================================================= =======
    [ Jesus45 ChickenMassacre ]
    [ ]
    [ Description: This is V.1 of Jesus45's chicken ]
    [ Massacre. Drag the CrossHairs ]
    [ Over the Runescape client, setup ]
    [ Users below and options then hit ]
    [ play button. Happy Autoing ]
    ================================================== ========}

    {FILL OUT OPTIONS HERE} {PLAYER SETUP BELOW}


    const
    FightingStyle = 0; // 1 = attack 2 = strength 3 = defense
    PickUpfeathers = True; // true to pick up feathers false to not.(May lag)
    ChickenKills = 566546; //how many chickens you want to kill.



    Var//////////////////////////////////////////////////////////
    ChickensKilled: integer;// DONT CHANGE !! //
    Feathers: integer; // DONT CHANGE !! //
    //////////////////////////////////////////////////////////

    {************************************************* ************}
    procedure DeclarePlayers; //
    begin //
    HowManyPlayers := 6; //Number of PLAYERS. active or not. //
    NumberOfPlayers(HowManyPlayers); //
    CurrentPlayer := 0; //Player to start on. //
    {************************************************* ************}


    {SET ALL USERS CORRECTLY}

    Players[0].Name := 'Jadseven';
    Players[0].Pass := 'Password';
    Players[0].Nick := 'dsev'; // 3 letters of your username
    Players[0].Active := True;

    Players[1].Name := 'UserName';
    Players[1].Pass := 'Password';
    Players[1].Nick := '3-4 letters of UserName';
    Players[1].Active := False;

    Players[2].Name := 'UserName';
    Players[2].Pass := 'Password';
    Players[2].Nick := '3-4 letters of UserName';
    Players[2].Active := False;

    Players[3].Name := 'UserName';
    Players[3].Pass := 'Password';
    Players[3].Nick := '3-4 letters of UserName';
    Players[3].Active := False;

    Players[4].Name := 'UserName';
    Players[4].Pass := 'Password';
    Players[4].Nick := '3-4 letters of UserName';
    Players[4].Active := False;

    Players[5].Name := 'UserName';
    Players[5].Pass := 'Password';
    Players[5].Nick := '3-4 letters of UserName';
    Players[5].Active := False;

    NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
    end;
    {************************************************* ***********************}
    { Logs in first player }
    {************************************************* ***********************}


    Procedure Log1stPlayer;
    begin
    LoginPlayer;
    Wait(500+random(100);
    end;
    {************************************************* ***********************}
    { Sets the color brightness to highest }
    {************************************************* ***********************}

    Procedure ReallyBrightColor;
    Begin
    GameTab(11);
    Wait(500+random(12));
    end;
    If GetColor(712, 226) <> 16777215 Then
    Begin
    Mouse(712, 226, 2, 2, True);
    Wait(300+random(50));
    End;
    End;
    {************************************************* ***********************}
    { Anti ban & Anti random }
    {************************************************* ***********************}
    Procedure JesusNoBanPlz; // Took alot of advice from JAD on
    if(not(LoggedIn))then // the anti ban (thanks).
    Log1stplayer;
    FindThelight;
    JesusNoBanPlz;
    begin
    case random(4) of

    1: PickUpMouse;

    2: AlmostLogOutEvery(15+random(2));
    Wait(800+random(200))
    GameTab(4);

    3: begin
    Sendkeys('wow im almost up a str lvl');
    Wait(1000+random(500));
    GameTab(4)
    end;

    4: begin
    HoverSkill('Strength',false);
    Wait(1000+random(200));
    GameTab(4)
    end;



    {************************************************* ***********************}
    { Anti Randoms }
    {************************************************* ***********************}

    procedure FindRandoms; // By WT-Fakawi
    begin
    FindFastRandoms;
    FindNormalRandoms;
    Wait(500+random(150));
    end;
    {************************************************* ***********************}
    { FightStyle }
    {************************************************* ***********************}
    procedure FightStyle;

    if (FightingStyle = 1)then
    begin
    GameTab(1);
    Wait(1000+random(100));
    Mouse(730,483,5,5,True);
    Writeln('Switched fightmode to attack')
    end;
    if (FightStyle = 2)then
    begin
    GameTab(1);
    Wait(1000+random(200));
    Mouse(814,483,5,5,True);
    Writeln('Switched fightmode to strength')
    end;
    if (FightStyle = 3)then
    begin
    GameTab(1);
    Wait(1000+random(200));
    Mouse(732,536,5,5,True);
    Writeln('Switched fightmode to fightmode 3')
    end;
    if (FightStyle = 4)then
    begin
    GameTab(1);
    Wait(1000+random(200));
    Mouse(811,534,5,5,True);
    Writeln('Switched fightmode to defense')
    end;
    if(not(LoggedIn))then
    begin
    TerminateScript;
    end;

    {************************************************* ***********************}
    { Finds Chickens and Attacks }
    {************************************************* ***********************}
    function FightNPC(Color1, Color2, Color3, Color4, Color5, Color6, tol, TimeOut:
    Integer): Boolean; // By WT-Fakawi
    var
    I, Color: Integer;
    begin
    for I := 1 to 6 do
    begin
    case I of
    1: Color := 5796737;
    2: Color := 5928324;
    3: Color := 3627637;
    4: Color := 3627637;
    5: Color := 5928324;
    6: Color := 7904432;
    end;
    if (LoggedIn) then
    begin
    if (FindObj(x, y, 'ttack', Color, tol)) then
    begin
    Result := True;
    GetMousePos(x, y);
    if (not (LoggedIn) or (WeAreDead)) then Break;
    Mouse(x, y, 0, 0, True);
    if (not (LoggedIn) or (WeAreDead)) then Break;
    Wait(2000);
    FFlag(10);
    MarkTime(Mark);
    repeat
    if (not (LoggedIn) or (WeAreDead)) then Break;
    Wait(1000 + Random(500));
    FindNormalRandoms;
    if (TimeFromMark(Mark) > TimeOut) then Break;
    until ((not (FindColorSpiral(x, y, GreenStatusColor, 240, 140, 290, 175))
    or (WeAreDead)));
    NPCS := NPCS + 1;
    Players[CurrentPlayer].Killed := Players[CurrentPlayer].Killed + 1;
    ChickensKilled +1
    end
    else
    Result := False;
    end
    end
    end;
    {************************************************* ********************}
    { Picks Up Feathers. }
    {************************************************* ********************}
    Procedure BitMapForFeathers;

    var
    Feather: Integer;
    x,y: Integer;

    procedure LoadBmps;
    begin

    Feather := BitmapFromString2(False, 'aE4B0678DA6D90410E0421' +
    '0804BFC48C34304740FDFF93567492DDC3AAA9904ED107898 8662' +
    'E905F0B2252242EC21611E33B8F4D2B075AF36D6502D580B9 77EF' +
    '2A63DF73A0A8D5ACB13B77C3C9F529F5D2566C9296B4EE0FA B9E2' +
    '8DCA78F80AFA35D20FCB09ACA1F533D3D0ECD95A46B434764 2467' +
    '3B7C4DF3E15D81897168439BDE189C1CF5228EA9171C8F308 8A7C' +
    'EF53D38C99B1377EEC784B1B08039AE971F38F');gin

    end;

    procedure ClickingOnBitMap;
    begin
    if(FindBitmapIn(Feather,x,y,0,0,100,100)) then
    begin
    Mouse(x,y+random(0),20,40,45,25,20);
    Wait(1000+random(100));
    ClickMouse(x,y,False);
    Wait(100+random(50));
    ClickOption('fea', 1);
    end;
    end;
    procedure FreeBmps;
    begin
    FreeBitmap(Feather);
    end;
    {************************************************* ********************}
    { Progress Report. }
    {************************************************* ********************}
























    {************************************************* ****************}
    { Main Loop }
    {************************************************* ****************}
    Procedure LoopMyScript;

    begin
    SetupSrl;
    ActivateCLient;
    DeclarePlayers;
    Log1stPlayer;
    repeat
    JesusNoBanPlz;
    FindRandoms;


    end.
    Finished my curser ---> it's in mage section.

  2. #2
    Join Date
    Jun 2006
    Posts
    1,492
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well, you could use FindObj, or make your own fighting proc.

    Look for the unique chicken color (the little red thing on its head). Then, look for the white of its body in a box around where you found the red. If you find it, thats your chicken!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •