CWindow = class(
function(self, windowTitle)
self.win = nil;
print(self);
print(windowTitle);
self.title = windowTitle;
print(self.title);
end
);
function CWindow:getWin()
print(self);
print(self.win);
print(self.title);
if(self.win == nil) then
self.win = findWindow(self.title);
end
if (self.win == 0) then
cprintf_ex("|red|ERROR:|white| Unable to find the |yellow|%s|white| window.\n", self.title);
cprintf_ex("|white|Launch the game and press |yellow|%s|white| restart the macro.\n", getKeyName(getStartKey()));
cprintf_ex("|red|Macro paused.\n");
stopPE();
-- getWin();
end
return self.win;
end
function CWindow:showWindow(state)
print("showWindow");
showWindow(CWindow:getWin(), state);
end