*CONTINUED FROM ABOVE*
•Now we must test to see if your DTM works. So click:
• If it worked correctly you should see somthing like this:
Step6:: Useing your DTM in your script:
•Using a DTM in a script is similar to using a bitmap in a script. First you must convert you DTM to text. So open up the DTM editor and click File>Open>Where ever your DTM is saved and click
•Now exit out of the DTM editor and look in the SCAR report box you should see somthing like this:
Code:
DTM := DTMFromString('78DA63AC666460286740017509960CFF81345' + '086E13F1030B663AA81C8C248205D0B64D51050934F849A2A202B' + '8B809A26202B13BF1A0034E80BCD');
•See where it says "DTM" before the :=? That is where you name the DTM anything you want to!
•Now all we have to do it use it in a script like a bitmap. The FindDTM function goes as followed:
Code:
FindDTM(DTM: Integer; var x, y: Integer; x1, y1, x2, y2: Integer): Integer
•This is what all of they variables mean
DTM= Name of Your DTM
x,y= The x,y cords that the dtm is it. (Scar finds this)
x1,y1,x2,y2: The box in which SCAR tries to find the DTM in
•So here is an example of using this DTM in a script:
Code:
program New;
var Logs,x,y:integer;
begin
Logs := DTMFromString('78DA63AC666460286740017509960CFF81345' + '086E13F1030B663AA81C8C248205D0B64D51050934F849A2A202B' + '8B809A26202B13BF1A0034E80BCD');
if FindDTM(Logs,x, y,1, 1, 200, 200) then
writeln('Congratz! You have just found your first DTM!')
end.
And this concludes Yohojo's DTM Tutorial