DeSnob
2010-11-02 21:19:20
I'm completing a form for my aimbot and I'm having issues with my checkbox. It seems that whether or not it is clicked if it is already checked it will uncheck itself. For example, I clicked it and it stayed checked. I opened and exited the form and opened again and the checkbox was unchecked.
Here's the script so far:
Can anyone help me with this?
Here's the script so far:
program PawngameAimbot;
{$i srl/srl.scar}
{FORM VARS}
var
Controls: TForm;
TeamLabel: Array [0..2] of TLabel;
TeamBox: Array [0..1] of TComboBox;
Setting: Array [0..1] of TCheckBox;
Button1: TButton;
var
x, y, detects, Proggy, Login, TeamID: Integer;
Input, team, Map: String;
Human, HumanCheck, Aimbot: Boolean;
Procedure Save(Sender: TObject);
Begin
team := lowercase(TeamBox[0].text);
map := lowercase(TeamBox[1].text);
Writeln('Saved settings.');
Controls.ModalResult:= mrOk;
End;
procedure HumanMode(Sender: TObject);
begin
if (HumanCheck = True) then
HumanCheck := False
else
HumanCheck := True;
if (HumanCheck = True) then
if (Human = True) then
Human := False
else
Human := True;
Writeln('Safety mode changed.');
end;
procedure InitForm;
begin
Controls := TForm.Create(nil);
with Controls do
begin
Position := poScreenCenter;
Width := 600;
Height := 400;
Caption := 'DeSnob PawnGame Aimbot Controls';
Color := 3416346;
end;
TeamLabel[0] := TLabel.Create(Controls);
TeamLabel[0].Parent := Controls;
TeamLabel[0].Top := 10;
TeamLabel[0].Left := 250;
TeamLabel[0].Caption := 'Controls';
TeamLabel[0].Font.Color := 16777215;
TeamLabel[0].Font.Size := 20;
TeamLabel[0].Font.Name := 'Copperplate Gothic Light';
TeamLabel[1] := TLabel.Create(Controls);
TeamLabel[1].Parent := Controls;
TeamLabel[1].Top := 50;
TeamLabel[1].Left := 70;
TeamLabel[1].Caption := 'Which team are you on?';
TeamLabel[1].Font.Color := 16777215;
TeamLabel[1].Font.Size := 13;
TeamLabel[1].Font.Name := 'Eras Light ITC';
TeamBox[0] := TComboBox.Create(Controls);
TeamBox[0].Parent := Controls;
TeamBox[0].Top := 75;
TeamBox[0].Left := 120;
TeamBox[0].Width := 60;
TeamBox[0].Height := 10;
TeamBox[0].Caption := (team);
TeamBox[0].Items.Add('Red');
TeamBox[0].Items.Add('Blue');
TeamBox[0].MaxLength := 4;
TeamLabel[2] := TLabel.Create(Controls);
TeamLabel[2].Parent := Controls;
TeamLabel[2].Top := 100;
TeamLabel[2].Left := 70;
TeamLabel[2].Caption := 'What type of map are you playing in?';
TeamLabel[2].Font.Color := 16777215;
TeamLabel[2].Font.Size := 13;
TeamLabel[2].Font.Name := 'Eras Light ITC';
TeamBox[1] := TComboBox.Create(Controls);
TeamBox[1].Parent := Controls;
TeamBox[1].Top := 130;
TeamBox[1].Left := 120;
TeamBox[1].Width := 150;
TeamBox[1].Height := 10;
TeamBox[1].Caption := 'No specific map';
TeamBox[1].Items.Add('Underwater');
TeamBox[1].Items.Add('No specific map');
TeamBox[1].MaxLength := 10;
Setting[0] := TCheckBox.Create(Controls);
Setting[0].Parent := Controls;
Setting[0].Top := 50;
Setting[0].Left := 400;
Setting[0].Caption := 'Toggle Safe/Human Mode';
Setting[0].Color := 16777215;
Setting[0].OnClick := @HumanMode;
Setting[0].CHECKED := HumanCheck;
Button1 := TButton.Create(Controls);
Button1.Parent := Controls;
Button1.Left := 450;
Button1.Top := 325;
Button1.Height := 30;
Button1.Width := 100;
Button1.Caption := 'Save Changes';
Button1.OnClick := @Save;
end;
procedure SafeInitForm;
var
v: TVariantArray;
begin
setarraylength(V, 0);
ThreadSafeCall('InitForm', v);
end;
procedure ShowFormModal;
begin
Controls.ShowModal;
end;
procedure SafeShowFormModal;
var
v: TVariantArray;
begin
setarraylength(V, 0);
ThreadSafeCall('ShowFormModal', v);
end;
function Screen: boolean;
begin
Result := CountColorTolerance(0,151, 523, 654, 535, 0) > 6000;
end;
function GScreen: boolean;
begin
Result := CountColorTolerance(15418179,0, 0, 750, 575, 0) > 0;
end;
function Lobby: boolean;
begin
Result := CountColorTolerance(65884,360, 35, 650, 63, 0) > 8000;
end;
function DetectGameEnter: boolean;
begin
Result := CountColorTolerance(14090211,52, 125, 283, 431, 0) > 0;
end;
function InGame: boolean;
begin
Result := Lobby and GScreen;
end;
Procedure HoverEnemy;
begin
If (Screen) or (Lobby) or (Aimbot = false) then
Exit;
if (team = 'red') and not(lowercase(Map) = 'underwater') then
if FindColorTolerance(x, y, 10422784, 0, 0, 750, 575, 0) then
begin
case (Human) of
True:
begin
MouseSpeed := 15;
MMouse(x, y, 0, 0);
end;
False: MoveMouse(x, y);
end;
Inc(detects);
end else
if FindColorTolerance(x, y, 4456448, 0, 0, 750, 575, 0) then
begin
case (Human) of
True:
begin
MouseSpeed := 15;
MMouse(x, y, 0, 0);
end;
False: MoveMouse(x, y);
end;
Inc(detects);
end;
if (team = 'blue') and not(lowercase(Map) = 'underwater') then
if FindColorTolerance(x, y, 3871354, 0, 0, 750, 575, 0) then
begin
case (Human) of
True:
begin
MouseSpeed := 15;
MMouse(x, y, 0, 0);
end;
False: MoveMouse(x, y);
end;
Inc(detects);
end else
if FindColorTolerance(x, y, 40, 0, 0, 750, 575, 0) then
begin
case (Human) of
True:
begin
MouseSpeed := 15;
MMouse(x, y, 0, 0);
end;
False: MoveMouse(x, y);
end;
Inc(detects);
end;
end;
procedure Msg;
begin
if not(team = 'blue') or not(team = 'red') then
begin
If (TeamID = 1) then
begin
if team = 'blue' then
team := 'red'
else
team := 'blue';
end else
if InputQuery('DeSnob''s PawnGame Aimbot V1.8', 'What team are you on?', Input) then
begin
if lowercase(Input) = 'blue' then
begin
team := 'blue';
TeamID := 1;
end;
if lowercase(Input) = 'red' then
begin
team := 'red';
TeamID := 1;
end;
end;
end;
end;
procedure ChangeHuman;
begin
if (Human = True) then
Human := False
else
Human := True;
end;
procedure ToggleAimbot;
begin
if (Aimbot = True) then
Aimbot := False
else
Aimbot := True;
Wait(100+random(500));
end;
procedure ChangeMap;
begin
if InputQuery('DeSnob''s PawnGame Aimbot V1.8', 'Which map? (underground, red, or "leave blank for normal")', Input) then
begin
if lowercase(Input) = 'underwater' then
Map := 'underwater';
if lowercase(Input) = '' then
Map := '';
end;
end;
procedure Progress;
begin
If TimeFromMark(Proggy) < 1000 then
Exit;
if (Aimbot = false) then
begin
ClearDebug;
Writeln('Aimbot OFF.');
MarkTime(Proggy);
Exit;
end;
ClearDebug;
Writeln('DESNOB PAWNGAME AIMBOT- V1.8!');
Writeln('Latest update allows for more stable killing!');
Writeln('Current Stats:');
Writeln('Currently hovered '+ IntToStr(detects) + ' times.');
Writeln('Your team is '+ (team) +'.');
Writeln('Human-like movement: '+ BoolToStr(Human));
Writeln('Press F1 for the controls.');
if (GScreen) and (Lobby) then
begin
Writeln('At login screen. PLEASE LOG IN!');
if not(Login > 0) then
begin
MessageBox('At login screen. PLEASE LOG IN!', 'DeSnob''s PawnGame Aimbot V1.8', 0);
Inc(Login);
end;
end else
if (Lobby) then
begin
Writeln('Currently at lobby.');
Login := 0;
end;
if (DetectGameEnter) then
Writeln('Choosing game.');
MarkTime(Proggy);
end;
begin
Progress;
MarkTime(Proggy);
Aimbot := True;
repeat
if IsKeyDown(123) or (Input = '') then //Fpp12
Msg;
if IsKeyDown(122) then //F11
ChangeHuman;
if IsKeyDown(121) then //F10
ChangeMap;
if IsKeyDown(112) then // F1
begin
//MessageBox('Press F3 to toggle the aimbot ('+ BoolToStr(Aimbot) +') Press F10 to switch maps('+ (Map) +') Press F11 to toggle human mode('+ BoolToStr(Human) +') Press F12 to switch teams('+ (team) +')', 'DeSnob''s PawnGame Aimbot V1.8 Controls', 0);
SafeInitForm;
SafeShowFormModal;
end;
if ISKeyDown(114) then //Since it isn't a mode, it isn't clustered together - F3
ToggleAimbot;
HoverEnemy;
Progress;
until(false)
end.Can anyone help me with this?