Forum in READ ONLY mode! All questions and discussions on Discord official server, invite link: https://discord.gg/VxsGzJ7

6.7.0 pascal] do you know how to delete artefacts

Ask for help
Post Reply
epsilon2
Neophyte
Neophyte
Posts: 19
Joined: 15.08.2016 20:41

6.7.0 pascal] do you know how to delete artefacts

Post by epsilon2 »

i wrote the following code

Code: Select all

Program New;
var
i          : integer;
x          : integer;
list2      : TStringList;
UserList   : TStringList;
 
BEGIN

ClearShopList;
SetAutoSellDelay($0001);
AutoSell($1EFD,$0000,999);
UOSay('Hello World');
FindDistance:= 9;
FindVertical:= 9;
list2 := TStringList.Create;
FindType($0190,Ground);
wait(100);
UserList := TStringList.Create;
GetFindedList(UserList);
for i:= 0 to UserList.count -1 do
begin
    FillNewWindow(GetTooltip(StrToInt('$'+UserList[i])));
    if  0 < pos('tailor', GetTooltip(StrtoInt('$'+UserList[i]))) then
    begin
        ClearContextMenu;
        RequestContextMenu(StrtoInt('$'+UserList[i]));
        wait(1000);        
        GetContextMenu(list2);
        for x:= 1 to list2.count do
        begin
            if  0 < pos('Sell', list2[x]) then
            begin
                SetContextMenuHook(StrToInt('$'+UserList[i]), x);                    
            end;
            ClearShopList;
        end;
        ClearContextMenu;        
    end;
end;
UserList.free;
list2.free;

End.
My expirience is about not closing sell gump and context menue.
Do You have an idea how to gump free client window?
BTW. After executeing the code and clicking by mouse on the used NPC. I get an autosell, contextmenue or random gump.
User avatar
Vizit0r
Developer
Developer
Posts: 3958
Joined: 24.03.2005 17:05
Contact:

Re: 6.7.0 pascal] do you know how to delete artefacts

Post by Vizit0r »

http://stealth.od.ua/Doc:Api/CloseClientUIWindow
but have no idea - available in 6.7 or not.
"Пишите код так, как будто сопровождать его будет склонный к насилию психопат, который знает, где вы живете". (с) Макконнелл, "Совершенный код".
Post Reply