Dudenow12
2007-12-01 13:41:47
I keep getting a pop up error saying Define not closed. I have been using smart for a little while now and it normally works just fine and when I try to run it now I keep getting the error.
This is what the first part looks like.
And the main loop.
[Admin]Please do not double post, if you have more to add to your post, please use the Edit button at the bottom left-hand of your post.
Thank you,
Hobbit[/admin]
I fixed the first problem, because I need and {$EndIF} in my text.scar. But now it doesn't log in properly. But in bobarkantor's post it doesn't say to have {$EndIF}.
This is what the first part looks like.
{$Define SMART} // This is where I defined SMART. If you don't want to use SMART, take out this line.
{$IfDef SMART} // In the next 3 lines, it will only include SMART.scar if you have defined SMART.
{.include SRL/SRL/Misc/Smart.scar}
{$EndIf} And the main loop.
begin
{$IfDef SMART}
SmartSetup('se3', False, False);
while not(SmartReady) do Wait(100);
SetTargetDC(SmartGetDC);
if not(LoggedIn) then
while not(SmartGetColor(386, 249) = 65535) do Wait(100);
{$EndIf}
setupsrl;
scriptID:='447';
if not(yourSRLstatsID = '') then SRLID := yourSRLstatsID;
if not(yourSRLstatsPW = '') then SRLPassword := yourSRLstatsPW;
declareplayers;
fwBankers:=DTMFromString('78DA639CC6C8C0B094010C182114C39F3F4C7' +
'0FE7F20609C8D5F0D989E44849A3EC26A008F2810DA');
furnaceDTM:=DTMFromString('78DA6374656460B8CC80029E01B1081003651' +
'8FE03012348CD393435AF5F338841D5800058CD75026A5CF0DB05' +
'56E34E580D00B38F1216');
bar:=DTMFromString('78DA636C67646008026214C0884402E97A20C' +
'B9F809A4A20CB97809A3E20CB87809A2940961B7E3500BC00043B' +
'');
activateclient;
wait(500);
marktime(np);
repeat
if not(loggedin) then loginplayer;
findnormalrandoms;
if lowercase(players[currentplayer].loc)='bank' then bank;
if lowercase(players[currentplayer].loc)='walktofurnace' then walktofurnace;
if lowercase(players[currentplayer].loc)='furnace' then shmelt;
if lowercase(players[currentplayer].loc)='walktobank' then walktobank;
if not(loggedIn) then
begin
writeln('not logged in, next player');
nextplayer(false);
marktime(np);
end;
if timefrommark(np)>1200000 then
begin
if lowercase(players[currentplayer].loc)='bank' then bank;
logout;
nextplayer(true);
marktime(np);
end;
until(false);
end.[Admin]Please do not double post, if you have more to add to your post, please use the Edit button at the bottom left-hand of your post.
Thank you,
Hobbit[/admin]
I fixed the first problem, because I need and {$EndIF} in my text.scar. But now it doesn't log in properly. But in bobarkantor's post it doesn't say to have {$EndIF}.