Footy
2012-09-23 18:11:49
Is there a function for this? I've looked through the include and can't find anything. I need it to figure out how many fish were cooked, and how many were burned.
Thanks
~Footy
Thanks
~Footy
2012-09-23 18:11:49
2012-09-23 18:13:53
2012-09-23 18:16:29
:p
2012-09-23 18:22:42
2012-09-23 18:28:51

procedure test;
var
thisTPA:TPointArray;
DTM, P:Integer;
begin
DTM := DTMFromString('mfgEAAHicE2JgYMhhYmDIh+JEIE4A4nIgLgHidCjOgorFAXEplJ8CxblAXATENowMDM5AbALEbkBsC8QWQGwHxO5AbIYkDlJnCMUgOUuoHEhvfHAQ0FVMFGNWBuoARiphTAAAH5sNWg==');
FindDTMs(DTM, thisTPA, MIX1, MIY1, MIX2, MIY2);
P := Length(thisTPA) + 1;
writeln(IntToStr(P));
end;2012-09-23 18:30:48
From: Footy
Another problem… I've made my DTM with as many points as possible so it only finds one match per fishie, but I'm still getting 244 matches with 27 fish in my inv… This is what the DTM editor looks like.
And this is my code:procedure test;
var
thisTPA:TPointArray;
DTM, P:Integer;
begin
DTM := DTMFromString('mfgEAAHicE2JgYMhhYmDIh+JEIE4A4nIgLgHidCjOgorFAXEplJ8CxblAXATENowMDM5AbALEbkBsC8QWQGwHxO5AbIYkDlJnCMUgOUuoHEhvfHAQ0FVMFGNWBuoARiphTAAAH5sNWg==');
FindDTMs(DTM, thisTPA, MIX1, MIY1, MIX2, MIY2);
P := Length(thisTPA) + 1;
writeln(IntToStr(P));
end;
Yet the output is 244… Is there a better way to do this? I can't make any more points on the outline anymore, since I'm clicking on other points. :p
OreCount := OreCount + CountItems('DTM',GoldDTM,[])+CountItems('DTM',CoalDTM,[]);
2012-09-23 18:38:50
From: Brandon
CountItemIn(……..);
It's something like that. It'll count the amount of DTM's. Or use ItemAmount(…); It'll again, count how many of a dtm is in your inventory.
2012-09-24 05:19:16
for i:=0 to 27 do
if FindDTM(blabla, InvBox(i).X1, etc.) then
inc(matches)
2012-09-24 05:37:34
From: J J
You could also use the bounds of an inventory slot and search in there. If it finds one or more matches you simply increase the amount of matches by one instead of the amount of matches.
for i:=0 to 27 do
if FindDTM(blabla, InvBox(i).X1, etc.) then
inc(matches)
I'm using that in my cooking guild script for the competition but I actually ran out of variables or something so I stored them as a TBox each time. Otherwise you are using 28*4 coords :P