Log in

View Full Version : Typing in diabled SMART



Shararazati
08-28-2010, 11:37 PM
Is it possible to enter text in SMART when disabled?

I can enter mouse clicks, but not keyboard strokes.

Seems like being able to type would go a long way toward not getting banned.

i luffs yeww
08-29-2010, 12:38 AM
Disable it, enable it, disable it, click in the chat box, then type. If it doesn't work, try that a few times and minimize and restore a few times after each time.

Coh3n
08-29-2010, 02:53 AM
There was a system (RM wrote it I think?) where you could type something into a text box of some form and it would send that text to the script, then your player would type it. That actually sounds like it would be a sweet Simba extension.

Other than that, there's no other way to type while SMART is disabled.

Rich
08-29-2010, 11:23 AM
^ I think it was something like this:

Press F2, and ReadLn would pop up asking you what you wanted to type. Simple, but effective. I agree with the idea of a Simba extension.

Shuttleu
08-29-2010, 11:29 AM
is there anyway to interact between the extensions and the script without ini files?, otherwise it could be hard

~shut

EDIT: or have something in SRL which is called regularly which can check the ini file, but then how would it know which simba its meant for...?

EDIT: nice and simple
this goes somewhere where it will be called a lot in SRL
procedure WriteSMART;
begin
if StrToBool(ReadINI('Changed', 'Changed', IncludePath+'SRL/SRL/SmartSendLine.INI')) then
begin
WriteINI('Changed', 'Changed', 'False', IncludePath+'SRL/SRL/SmartSendLine.INI');
TypeSend(ReadINI('SMART', 'SMART', IncludePath+'SRL/SRL/SmartSendLine.INI'));
end;
end;
and this is an extension
program SMARTTalker;

var
MainMenuItem, MenuSMARTForm: TMenuItem;

procedure SMARTReadLine(Sender: TObject);
var
TheLine: string;
begin
TheLine:= ReadLn('What to type?');
if (Length(TheLine) > 0) then
begin
WriteINI('Changed', 'Changed', 'True', IncludePath+'SRL/SRL/SmartSendLine.INI');
WriteINI('SMART', 'SMART', TheLine, IncludePath+'SRL/SRL/SmartSendLine.INI');
end;
end;

procedure Init;
begin;
MainMenuItem := TMenuItem.Create(Simba_MainMenu);
MainMenuItem.Caption := 'SMART';
Simba_MainMenu.Items.Add(MainMenuItem);

MenuSMARTForm := TMenuItem.Create(MainMenuItem);
MenuSMARTForm.Caption := 'Type Line';
MenuSMARTForm.OnClick := @SMARTReadLine;
MainMenuItem.Add(MenuSMARTForm);

end;

procedure Free;
begin

end;

procedure Attach;
begin;

end;

Procedure Detach;
begin

end;

function GetName : string;
begin;
result := 'SMART Talker';
end;

function GetVersion : string;
begin;
result := '1.0';
end;

begin
end.

the reason for INI files is because i havent found any way (other than INI files) to interact between extensions and scripts

Shararazati
08-30-2010, 02:28 AM
Wow thanks for all the help.

I'll try a few / all of those.

I did find that I can type in SMART if it is disabled and my script is stopped, but not if my script is paused.

Shuttleu
08-30-2010, 10:35 AM
Wow thanks for all the help.

I'll try a few / all of those.

I did find that I can type in SMART if it is disabled and my script is stopped, but not if my script is paused.there is only one at the mo, what i posted :)

~shut

Shuttleu
09-27-2010, 10:06 PM
bump, wondering if you would consider adding what i posted above

~shut

Naike
09-27-2010, 10:12 PM
I remember doing a ReadLn, and added the check with the in-build pointers in SRL..

OnRandomCall, or something like that, check it out, works very well ;)

doublex8
09-28-2010, 12:21 AM
Sorry I am extremely new to this. What does the code Shuttleu posted let you do? Does it let you type?

Wyn
09-28-2010, 01:17 AM
What I usually do to be able to type is...

1. Spam the crap of of the enable/disable button bout 7/8 times.
2. Click the compass.
3. Voila.

Dgby714
09-28-2010, 01:42 AM
...

1.) Add this to your script.

procedure SMARTCheck;
var
Data: string;
begin
if (IsKeyDown(VK_F2)) then
if (InputQuery('SMARTCheck', 'What would you like too say in SMART?', Data)) then
TypeSend(Data);
end;

2.) Then add one or both of these too the main "begin end.".

SRL_Procs[srl_AntiBan] := @SMARTCheck;
and/or
SRL_Procs[srl_OnRandomCall] := @SMARTCheck;

3.) Hit F2 too type in SMART

Shuttleu
09-28-2010, 07:59 AM
1.) Add this to your script.

procedure SMARTCheck;
var
Data: string;
begin
if (IsKeyDown(VK_F2)) then
if (InputQuery('SMARTCheck', 'What would you like too say in SMART?', Data)) then
TypeSend(Data);
end;

2.) Then add one or both of these too the main "begin end.".

SRL_Procs[srl_AntiBan] := @SMARTCheck;
and/or
SRL_Procs[srl_OnRandomCall] := @SMARTCheck;

3.) Hit F2 too type in SMART
well maybe that should be in SRL?
maybe under the name of SMARTCheckType

~shut

Wizzup?
09-28-2010, 12:31 PM
How would this work if you're running several scripts? ;) It's fine as a small tool but I don't think it should be in SRL.

Wyn
09-28-2010, 01:09 PM
How would this work if you're running several scripts? ;) It's fine as a small tool but I don't think it should be in SRL.

As a option. :stirthepot: