Results 1 to 5 of 5

Thread: Dead Detection

  1. #1
    Join Date
    Jul 2007
    Location
    UK
    Posts
    307
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default Dead Detection

    May somebody give me the text and function to detect if your dead?


    ~ Thanks

  2. #2
    Join Date
    Apr 2007
    Location
    Australia
    Posts
    4,163
    Mentioned
    9 Post(s)
    Quoted
    19 Post(s)

    Default

    FindDead;

    SCAR Code:
    {*******************************************************************************
    function FindDead: Boolean;
    by: Stupid3ooo
    Description: Checks for text "Ow dear you are dead".
    Switches player if Reincarnate = True.
    *******************************************************************************}


    function FindDead: Boolean;
    begin
      Result := False;
      if (GetColor(34, 445) = 0) and (GetColor(134, 445) = 0) then
      begin
        Deaths := Deaths + 1;
        Result := True;
        SaveToChatLog;
        if Reincarnate then Exit
        else
        begin
          if ScreenShots then
            TakeScreen('Found Dead');
          repeat
            Wait(1000 + Random(1000));
          until (not (LoggedIn));
          //Players[CurrentPlayer].Loc := 'Oh Dear You Are in Lumby';
          Players[CurrentPlayer].Rand := 'Oh Dear You Are in Lumby';
          Players[CurrentPlayer].Active := False;
        end;
      end;
    end;

    From AntiRandoms.scar

    I have found it to be inaccurate when using certain anti ban functions such as RandomRClick however.

  3. #3
    Join Date
    Feb 2007
    Location
    SparklesProd.com
    Posts
    2,406
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    FindDead

    Edit: Beaten

    I also found finddead to be inacurate.

  4. #4
    Join Date
    Jul 2007
    Location
    UK
    Posts
    307
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    Thanks, I new there was a Prodcedure for it I just didet think it would be in antirandoms :s
    Any other alternatives?

  5. #5
    Join Date
    Aug 2007
    Posts
    429
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    You could do

    SCAR Code:
    if (GetBlackChatMessage='h dear') then  //will search for dead text in last line
    begin
      Blah;
    end;

    if IsChatBlackTextAnyLine('h dear') then //will search for dead text in All lines
    begin
      Blah;
    end;

    I use that in my script and it always works (although will be laggy for a couple seconds)

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Location Detection
    By ganbree in forum OSR Help
    Replies: 4
    Last Post: 04-24-2007, 09:43 PM

Posting Permissions

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