Results 1 to 18 of 18

Thread: How To Make Easy DDTM's!

  1. #1
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default How To Make Easy DDTM's!

    How To Make DDTM's Using Nielsie95's DDTM Edit0r!


    Table Of Contents

    I - What Are DDTM's?

    II - Capturing The Client.

    III - Getting To Grips with the DDTM Edit0r!

    IV - Using the DDTM[s] In Your Script!

    V - Links!



    LINK TO THE DDTM EDITOR : http://www.villavu.com/forum/showthread.php?t=25312


    |||||||||||||||||||||||||||||||||||||||||||||||||| |||||||||||||||||||||||||||||||||||||||||||||||||| ||||||||||||||||||||||||||||||||||||||



    I - What Are DDTM's?

    So What the f*ck are DDTM's? DDTM's are related to DTM's, but they have a more user friendly Interface. DDTM's stand for Dynamic Deformable Template Model. They are used mainly for walking to places in runescape using SCAR. Coding a DDTM by hand isn't at all hard, but takes a lot of time.
    This Is why Nielsie has made a very easy shortcut for us, this was located in the Delphi Programming Section of the forum and sadly only got 'jack' views. This is a shame really as I think this is one of the best programming helping tools available (ACA 2 ). It has a very Human friendly interface and is very very easy to use.

    A Picture:






    II - Capturing The Client.


    Ok So now we need to Get the client picture (Runescape Interface) to plot the DDTM

    MainPoints and Subpoints, For this I would use the Screen Captcha that Sumilion sent me:

    SCAR Code:
    program RS_ScreenCaptcha;
    var
      bmpScreen, x, y: Integer;
    begin
      ActivateClient;
      wait(1800+Random(200))
      Disguise('Dont touch');
      GetClientDimensions(x, y);
      bmpScreen := BitmapFromString(x, y, '');
      CopyClientToBitmap(bmpScreen, 0, 0, x, x);
      SaveBitmap(bmpScreen, ScriptPath + 'RS Screenshot.bmp');
      Disguise('Done!');
    end.

    Not: 'You must save this to your desktop as that is where the picture will be saved aswell

    '

    ^ Just Specify the Client to where you want to walk to and it will capture it in a .Bmp

    form^

    So you ask why do I Need this? You need this becuase Nielsie's DDTM editor goes of co-ords from about 100 pixels to 500, you need to capture the Screen exactally or it won't Find the DDTM when we go to the end.

    Ok so we should now have the picture ready on which to Make the DDTM, Now comes the Hard Part j/k....



    III - Getting To Grips with the DDTM Edit0r!


    Now the DDTM Editor is just like the DTM editor that SCAR has built in, but with a few extra Functions :

    • Create, edit, view and delete points
    • Adjustable colors for the lines to the points.
    • Yellow pointers to see which point you're editing.
    • Load / save DTM's (supports the SCAR format)
    • Load DTM's from strings.
    • Load images from a .bmp file.
    • Load images from clipboard
    • Show the matching pixels (similar to cts 1).
    • Generate a DDTM or DTM which you can use in SCAR.


    Now we go to Image ( in the taskbar! ) --> Browse Image.
    You should now see a screen like this:



    Go onto the desktop and select this .bmp image called 'RS Screenshot', Open it and proceed.
    Now we have the Image Open. My Image Looks Like this:



    Now we make the DDTM, just like you would do with the Normal DTM Editor you make a mainpoint and a subpoint. As your plotting the points you should notice these Boxes called Tolerance, Color, Area Size, Area Shape, x and y.
    You might want to play about with these values to find the right DDTM for you.

    My DDTM Looks like this :



    As you see my mouse is hovering over the DDTM to Text option you might want to do this after you have made your DDTM.
    When you are finished click that Option and a window should pop up with the DDTM:



    Use this Copy to Clip Board Function and close the DDTM Editor.



    IV - Using the DDTM[s] In Your Script!


    Open Scar you should see:

    SCAR Code:
    program New;
    begin
    end.

    Now This is what my DDTM looks Like and this is How you should Paste it

    SCAR Code:
    Program New;

     
    function SetDDTM: Integer;
    var
      dtmMainPoint: TDTMPointDef;
      dtmSubPoints: Array [0..4] of TDTMPointDef;
      TempTDTM: TDTM;
    begin
      dtmMainPoint.x := 633;
      dtmMainPoint.y := 55;
      dtmMainPoint.AreaSize := 0;
      dtmMainPoint.AreaShape := 0;
      dtmMainPoint.Color := 8355209;
      dtmMainPoint.Tolerance := 0;
     
      dtmSubPoints[0].x := 633;
      dtmSubPoints[0].y := 55;
      dtmSubPoints[0].AreaSize := 0;
      dtmSubPoints[0].AreaShape := 0;
      dtmSubPoints[0].Color := 8355209;
      dtmSubPoints[0].Tolerance := 0;
     
      dtmSubPoints[1].x := 620;
      dtmSubPoints[1].y := 67;
      dtmSubPoints[1].AreaSize := 0;
      dtmSubPoints[1].AreaShape := 0;
      dtmSubPoints[1].Color := 8355209;
      dtmSubPoints[1].Tolerance := 0;
     
      dtmSubPoints[2].x := 648;
      dtmSubPoints[2].y := 67;
      dtmSubPoints[2].AreaSize := 0;
      dtmSubPoints[2].AreaShape := 0;
      dtmSubPoints[2].Color := 8355209;
      dtmSubPoints[2].Tolerance := 0;
     
      dtmSubPoints[3].x := 645;
      dtmSubPoints[3].y := 38;
      dtmSubPoints[3].AreaSize := 0;
      dtmSubPoints[3].AreaShape := 0;
      dtmSubPoints[3].Color := 8355209;
      dtmSubPoints[3].Tolerance := 0;
     
      dtmSubPoints[4].x := 600;
      dtmSubPoints[4].y := 22;
      dtmSubPoints[4].AreaSize := 0;
      dtmSubPoints[4].AreaShape := 0;
      dtmSubPoints[4].Color := 8355209;
      dtmSubPoints[4].Tolerance := 0;
     
      TempTDTM.MainPoint := dtmMainPoint;
      TempTDTM.SubPoints := dtmSubPoints;
      Result := AddDTM(TempTDTM);
    end;  

    Begin



    end.

    Now as we want scar to Find the DDTM we must specify it as so:


    SCAR Code:
    Program New;

    Var
    DTM1 : Integer;

    function SetDDTM: Integer;
    var
      dtmMainPoint: TDTMPointDef;
      dtmSubPoints: Array [0..4] of TDTMPointDef;
      TempTDTM: TDTM;
    begin
      dtmMainPoint.x := 633;
      dtmMainPoint.y := 55;
      dtmMainPoint.AreaSize := 0;
      dtmMainPoint.AreaShape := 0;
      dtmMainPoint.Color := 8355209;
      dtmMainPoint.Tolerance := 0;
     
      dtmSubPoints[0].x := 633;
      dtmSubPoints[0].y := 55;
      dtmSubPoints[0].AreaSize := 0;
      dtmSubPoints[0].AreaShape := 0;
      dtmSubPoints[0].Color := 8355209;
      dtmSubPoints[0].Tolerance := 0;
     
      dtmSubPoints[1].x := 620;
      dtmSubPoints[1].y := 67;
      dtmSubPoints[1].AreaSize := 0;
      dtmSubPoints[1].AreaShape := 0;
      dtmSubPoints[1].Color := 8355209;
      dtmSubPoints[1].Tolerance := 0;
     
      dtmSubPoints[2].x := 648;
      dtmSubPoints[2].y := 67;
      dtmSubPoints[2].AreaSize := 0;
      dtmSubPoints[2].AreaShape := 0;
      dtmSubPoints[2].Color := 8355209;
      dtmSubPoints[2].Tolerance := 0;
     
      dtmSubPoints[3].x := 645;
      dtmSubPoints[3].y := 38;
      dtmSubPoints[3].AreaSize := 0;
      dtmSubPoints[3].AreaShape := 0;
      dtmSubPoints[3].Color := 8355209;
      dtmSubPoints[3].Tolerance := 0;
     
      dtmSubPoints[4].x := 600;
      dtmSubPoints[4].y := 22;
      dtmSubPoints[4].AreaSize := 0;
      dtmSubPoints[4].AreaShape := 0;
      dtmSubPoints[4].Color := 8355209;
      dtmSubPoints[4].Tolerance := 0;
     
      TempTDTM.MainPoint := dtmMainPoint;
      TempTDTM.SubPoints := dtmSubPoints;
      Result := AddDTM(TempTDTM);
    end;  

    Begin



    end.

    ^ As you can see I have added an Integer called 'DTM1' I want my script to walk to this place so what I must now do is to Make scar associate that DTM1 with the SetDDTM :

    SCAR Code:
    Program New;
    {.include srl/srl.scar}
    Var
    DTM1, x, y : Integer;


     
    function SetDDTM: Integer;
    var
      dtmMainPoint: TDTMPointDef;
      dtmSubPoints: Array [0..4] of TDTMPointDef;
      TempTDTM: TDTM;
    begin
      dtmMainPoint.x := 633;
      dtmMainPoint.y := 55;
      dtmMainPoint.AreaSize := 0;
      dtmMainPoint.AreaShape := 0;
      dtmMainPoint.Color := 8355209;
      dtmMainPoint.Tolerance := 0;
     
      dtmSubPoints[0].x := 633;
      dtmSubPoints[0].y := 55;
      dtmSubPoints[0].AreaSize := 0;
      dtmSubPoints[0].AreaShape := 0;
      dtmSubPoints[0].Color := 8355209;
      dtmSubPoints[0].Tolerance := 0;
     
      dtmSubPoints[1].x := 620;
      dtmSubPoints[1].y := 67;
      dtmSubPoints[1].AreaSize := 0;
      dtmSubPoints[1].AreaShape := 0;
      dtmSubPoints[1].Color := 8355209;
      dtmSubPoints[1].Tolerance := 0;
     
      dtmSubPoints[2].x := 648;
      dtmSubPoints[2].y := 67;
      dtmSubPoints[2].AreaSize := 0;
      dtmSubPoints[2].AreaShape := 0;
      dtmSubPoints[2].Color := 8355209;
      dtmSubPoints[2].Tolerance := 0;
     
      dtmSubPoints[3].x := 645;
      dtmSubPoints[3].y := 38;
      dtmSubPoints[3].AreaSize := 0;
      dtmSubPoints[3].AreaShape := 0;
      dtmSubPoints[3].Color := 8355209;
      dtmSubPoints[3].Tolerance := 0;
     
      dtmSubPoints[4].x := 600;
      dtmSubPoints[4].y := 22;
      dtmSubPoints[4].AreaSize := 0;
      dtmSubPoints[4].AreaShape := 0;
      dtmSubPoints[4].Color := 8355209;
      dtmSubPoints[4].Tolerance := 0;
     
      TempTDTM.MainPoint := dtmMainPoint;
      TempTDTM.SubPoints := dtmSubPoints;
      Result := AddDTM(TempTDTM);
    end;  

    Begin
      DTM1 := SetDDTM;
        If DTMRotated(DTM1, X, Y, MMX1, MMY1, MMX2, MMY2) Then
          WriteLn('Found DTM1');
    end.

    What I have done is used the Procedure DTMROtated to search for the DTM1 in the Minimap, If it finds it then it will write in the DebugBox : Found DTM1.
    This is just a glimpse of How smex-eh the DDTM Editor is.

    Good Night!


    [Note Some of the Example Might'nt Work]



    V - LINKS!

    http://www.villavu.com/forum/showthr...ight=ddtm+tuts

    http://www.villavu.com/forum/showthr...ight=ddtm+tuts

    http://www.villavu.com/forum/showthread.php?t=12584

    Use the search Button to Find More!


    Credits:
    Nielsie
    Sumilion




    THANKS FOR READING!!!









  2. #2
    Join Date
    Sep 2006
    Posts
    6,089
    Mentioned
    77 Post(s)
    Quoted
    43 Post(s)

    Default

    Looks good
    Thank you for making this.
    Hup Holland Hup!

  3. #3
    Join Date
    Nov 2007
    Location
    The Netherlands
    Posts
    1,490
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    nice tut nauman
    good job
    tough i prefer making them by my own
    rep+

  4. #4
    Join Date
    Sep 2007
    Location
    Sweden
    Posts
    765
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    another great tut by a great scripter Nauman, you rock. you're my scripting idol xD. you're friendly, helpful and all you could imagine. good job!


    ^LOL^

  5. #5
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Thanks for all the replies Guys

  6. #6
    Join Date
    Sep 2007
    Location
    Sweden
    Posts
    765
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    i have a quick question, when making a bank DDTM, whats a good tolerance? i tried around 25 on the main point, and about 0-5 on the sub points. i just want to know what you guys are using


    ^LOL^

  7. #7
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Nub.

    good resfreshment of ddtm's lol, good job.
    ~Hermen

  8. #8
    Join Date
    Sep 2007
    Location
    Sweden
    Posts
    765
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    Quote Originally Posted by Hermpie View Post
    Nub.
    Haha Hermpie, are you begin sarcastic again? i told you not to anyways, i think this thread should be stickified xD contains alot of good info, easy to understand too.
    Yeah, i did actually see the white text. i wonder if anyone sees this?


    ^LOL^

  9. #9
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by kor View Post
    another great tut by a great scripter Nauman, you rock. you're my scripting idol xD. you're friendly, helpful and all you could imagine. good job!
    Just wait till he begs for a rep every 10 times in a sec
    ~Hermen

  10. #10
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Here's My Script To Beg for Rep:

    SCAR Code:
    Program New;
    var
    i : Integer;
    Begin
       For i:=0 to 10 Do
         SendKeys(' REP ME NOW!');
    end.

    I dunno It might do it in one second or maybe less

  11. #11
    Join Date
    Mar 2008
    Location
    The Netherlands
    Posts
    1,395
    Mentioned
    1 Post(s)
    Quoted
    1 Post(s)

    Default

    Maybe TypeSend cuz that knows enter too, but thats kinda like.. slow ;P


  12. #12
    Join Date
    Dec 2006
    Posts
    173
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Great tutorial! Helped me a lot. Rep +
    Starting to merchant, if you know of any good clans, PM me please.

  13. #13
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    It does it in 47 msec. :P

  14. #14
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Lol . Thx for the comments guys

  15. #15
    Join Date
    Sep 2007
    Location
    Sweden
    Posts
    765
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    Nauman, you didnt answer my question

    *cough*
    i have a quick question, when making a bank DDTM, whats a good tolerance? i tried around 25 on the main point, and about 0-5 on the sub points. i just want to know what you guys are using
    *cough*


    ^LOL^

  16. #16
    Join Date
    Jan 2007
    Location
    Illinois.. >.<
    Posts
    1,158
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    @ kor: The beauty of DDTM's is that you can change the tolerance.. So start it off lower maybe and increase the tolerance by 5 or 10 each time using a loop. And then maybe for debugging purposes if you want, make it writeln what the tolerance was when it found the DTM.

  17. #17
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Yeah. Added New Parts.

  18. #18
    Join Date
    Aug 2009
    Location
    Inside the Matrix...yes it has me, and it has you too.
    Posts
    1,896
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    smex-eh tut m8. really cleared a few things up for me, may have even finished my script to get into SRL membs with help from this tut
    NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN NYAN

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How easy would it be to make a tutorial island script?
    By guidenation in forum News and General
    Replies: 13
    Last Post: 01-26-2009, 12:43 AM
  2. Prayer, Easy To Make?
    By yanix in forum RS3 Outdated / Broken Scripts
    Replies: 6
    Last Post: 10-19-2007, 10:38 PM
  3. Easy To Make!!
    By yanix in forum RS3 Outdated / Broken Scripts
    Replies: 5
    Last Post: 07-11-2007, 05:13 AM

Posting Permissions

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