mirror of
https://github.com/moparisthebest/Simba
synced 2025-01-30 23:00:18 -05:00
Added a couple of files, and a few comments.
git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@34 3f818213-9676-44b0-a9b4-5e4c4e03d09d
This commit is contained in:
parent
acfe2a5232
commit
ff4376d290
2
Changelog.txt
Normal file
2
Changelog.txt
Normal file
@ -0,0 +1,2 @@
|
||||
Changelog since version 1:
|
||||
|
8
Known Issues.txt
Normal file
8
Known Issues.txt
Normal file
@ -0,0 +1,8 @@
|
||||
Known issues:
|
||||
|
||||
Linux:
|
||||
- Mouse Clicking only works in the client, and the mouse click must be in the client, otherwise the event is ignored.
|
||||
- CopyClientToBitmap isn't stable for IntArrPtr.
|
||||
|
||||
Windows:
|
||||
|
@ -7,7 +7,7 @@
|
||||
<TargetFileExt Value=""/>
|
||||
<Title Value="Mufasa Stand Alone"/>
|
||||
<UseXPManifest Value="True"/>
|
||||
<ActiveEditorIndexAtStart Value="2"/>
|
||||
<ActiveEditorIndexAtStart Value="8"/>
|
||||
</General>
|
||||
<VersionInfo>
|
||||
<ProjectVersion Value=""/>
|
||||
@ -37,7 +37,7 @@
|
||||
<CursorPos X="74" Y="10"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="0"/>
|
||||
<UsageCount Value="63"/>
|
||||
<UsageCount Value="64"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
@ -166,10 +166,10 @@
|
||||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="TestUnit"/>
|
||||
<CursorPos X="39" Y="131"/>
|
||||
<TopLine Value="119"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<UsageCount Value="29"/>
|
||||
<CursorPos X="58" Y="168"/>
|
||||
<TopLine Value="128"/>
|
||||
<EditorIndex Value="5"/>
|
||||
<UsageCount Value="30"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit18>
|
||||
<Unit19>
|
||||
@ -298,10 +298,10 @@
|
||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="Client"/>
|
||||
<CursorPos X="35" Y="33"/>
|
||||
<TopLine Value="23"/>
|
||||
<EditorIndex Value="4"/>
|
||||
<UsageCount Value="28"/>
|
||||
<CursorPos X="46" Y="39"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="3"/>
|
||||
<UsageCount Value="29"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit37>
|
||||
<Unit38>
|
||||
@ -310,8 +310,8 @@
|
||||
<UnitName Value="MufasaTypes"/>
|
||||
<CursorPos X="3" Y="16"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="3"/>
|
||||
<UsageCount Value="28"/>
|
||||
<EditorIndex Value="2"/>
|
||||
<UsageCount Value="29"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit38>
|
||||
<Unit39>
|
||||
@ -320,27 +320,27 @@
|
||||
<CursorPos X="18" Y="8"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="9"/>
|
||||
<UsageCount Value="24"/>
|
||||
<UsageCount Value="25"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit39>
|
||||
<Unit40>
|
||||
<Filename Value="../../Units/MMLCore/files.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="files"/>
|
||||
<CursorPos X="1" Y="79"/>
|
||||
<TopLine Value="63"/>
|
||||
<CursorPos X="62" Y="61"/>
|
||||
<TopLine Value="46"/>
|
||||
<EditorIndex Value="7"/>
|
||||
<UsageCount Value="29"/>
|
||||
<UsageCount Value="30"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit40>
|
||||
<Unit41>
|
||||
<Filename Value="../../Units/MMLCore/window.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="Window"/>
|
||||
<CursorPos X="35" Y="227"/>
|
||||
<TopLine Value="204"/>
|
||||
<EditorIndex Value="5"/>
|
||||
<UsageCount Value="28"/>
|
||||
<CursorPos X="35" Y="187"/>
|
||||
<TopLine Value="174"/>
|
||||
<EditorIndex Value="4"/>
|
||||
<UsageCount Value="29"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit41>
|
||||
<Unit42>
|
||||
@ -356,7 +356,7 @@
|
||||
<CursorPos X="80" Y="9"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="10"/>
|
||||
<UsageCount Value="14"/>
|
||||
<UsageCount Value="15"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit43>
|
||||
<Unit44>
|
||||
@ -365,26 +365,26 @@
|
||||
<CursorPos X="39" Y="19"/>
|
||||
<TopLine Value="9"/>
|
||||
<EditorIndex Value="6"/>
|
||||
<UsageCount Value="13"/>
|
||||
<UsageCount Value="14"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit44>
|
||||
<Unit45>
|
||||
<Filename Value="../../Units/MMLCore/input.pas"/>
|
||||
<UnitName Value="Input"/>
|
||||
<CursorPos X="3" Y="160"/>
|
||||
<TopLine Value="149"/>
|
||||
<CursorPos X="34" Y="211"/>
|
||||
<TopLine Value="193"/>
|
||||
<EditorIndex Value="8"/>
|
||||
<UsageCount Value="12"/>
|
||||
<UsageCount Value="13"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit45>
|
||||
<Unit46>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="finder"/>
|
||||
<CursorPos X="51" Y="94"/>
|
||||
<TopLine Value="84"/>
|
||||
<EditorIndex Value="2"/>
|
||||
<UsageCount Value="21"/>
|
||||
<CursorPos X="24" Y="130"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<UsageCount Value="22"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit46>
|
||||
<Unit47>
|
||||
@ -395,127 +395,99 @@
|
||||
<UsageCount Value="10"/>
|
||||
</Unit47>
|
||||
</Units>
|
||||
<JumpHistory Count="30" HistoryIndex="29">
|
||||
<JumpHistory Count="23" HistoryIndex="22">
|
||||
<Position1>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="211" Column="1" TopLine="182"/>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="154" Column="49" TopLine="140"/>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="155" Column="8" TopLine="140"/>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="160" Column="23" TopLine="145"/>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="../../../cogat/Units/CogatUnits/compfiles.pas"/>
|
||||
<Caret Line="8" Column="18" TopLine="1"/>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="29" Column="14" TopLine="11"/>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="161" Column="39" TopLine="146"/>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="29" Column="20" TopLine="16"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="51" Column="14" TopLine="46"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="54" Column="17" TopLine="48"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||
<Caret Line="31" Column="71" TopLine="14"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="137" Column="62" TopLine="121"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="../../Units/MMLCore/window.pas"/>
|
||||
<Caret Line="157" Column="52" TopLine="141"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="../../Units/MMLCore/window.pas"/>
|
||||
<Caret Line="232" Column="59" TopLine="217"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="../../Units/MMLCore/window.pas"/>
|
||||
<Caret Line="236" Column="29" TopLine="217"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||
<Caret Line="1" Column="1" TopLine="1"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="../../Units/MMLCore/window.pas"/>
|
||||
<Caret Line="106" Column="10" TopLine="91"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="../../Units/MMLCore/windowutil.pas"/>
|
||||
<Caret Line="21" Column="37" TopLine="1"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="../../Units/MMLCore/windowutil.pas"/>
|
||||
<Caret Line="109" Column="35" TopLine="86"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="../../Units/MMLCore/windowutil.pas"/>
|
||||
<Caret Line="34" Column="34" TopLine="24"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
<Filename Value="../../Units/MMLCore/files.pas"/>
|
||||
<Caret Line="1" Column="1" TopLine="1"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="../../Units/MMLCore/files.pas"/>
|
||||
<Caret Line="213" Column="5" TopLine="203"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
<Filename Value="../../Units/MMLCore/input.pas"/>
|
||||
<Caret Line="1" Column="1" TopLine="1"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||
<Caret Line="8" Column="53" TopLine="1"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="35" Column="5" TopLine="31"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="92" Column="48" TopLine="75"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="84" Column="12" TopLine="64"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="84" Column="18" TopLine="69"/>
|
||||
</Position18>
|
||||
<Position19>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="45" Column="1" TopLine="41"/>
|
||||
<Caret Line="88" Column="30" TopLine="65"/>
|
||||
</Position19>
|
||||
<Position20>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="48" Column="5" TopLine="38"/>
|
||||
<Caret Line="87" Column="16" TopLine="69"/>
|
||||
</Position20>
|
||||
<Position21>
|
||||
<Filename Value="../../Units/MMLCore/windowutil.pas"/>
|
||||
<Caret Line="109" Column="35" TopLine="86"/>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="90" Column="41" TopLine="75"/>
|
||||
</Position21>
|
||||
<Position22>
|
||||
<Filename Value="../../Units/MMLCore/windowutil.pas"/>
|
||||
<Caret Line="34" Column="34" TopLine="24"/>
|
||||
<Filename Value="../../Units/MMLCore/input.pas"/>
|
||||
<Caret Line="201" Column="18" TopLine="1"/>
|
||||
</Position22>
|
||||
<Position23>
|
||||
<Filename Value="../../Units/MMLCore/files.pas"/>
|
||||
<Caret Line="1" Column="1" TopLine="1"/>
|
||||
</Position23>
|
||||
<Position24>
|
||||
<Filename Value="../../Units/MMLCore/files.pas"/>
|
||||
<Caret Line="213" Column="5" TopLine="203"/>
|
||||
</Position24>
|
||||
<Position25>
|
||||
<Filename Value="../../Units/MMLCore/input.pas"/>
|
||||
<Caret Line="1" Column="1" TopLine="1"/>
|
||||
</Position25>
|
||||
<Position26>
|
||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||
<Caret Line="8" Column="53" TopLine="1"/>
|
||||
</Position26>
|
||||
<Position27>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="35" Column="5" TopLine="31"/>
|
||||
</Position27>
|
||||
<Position28>
|
||||
<Filename Value="testunit.pas"/>
|
||||
<Caret Line="131" Column="39" TopLine="119"/>
|
||||
</Position28>
|
||||
<Position29>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="92" Column="48" TopLine="75"/>
|
||||
</Position29>
|
||||
<Position30>
|
||||
<Filename Value="../../Units/MMLCore/finder.pas"/>
|
||||
<Caret Line="84" Column="12" TopLine="64"/>
|
||||
</Position30>
|
||||
<Caret Line="209" Column="34" TopLine="195"/>
|
||||
</Position23>
|
||||
</JumpHistory>
|
||||
</ProjectOptions>
|
||||
<CompilerOptions>
|
||||
@ -527,6 +499,11 @@
|
||||
<IncludeFiles Value="$(ProjOutDir)/"/>
|
||||
<OtherUnitFiles Value="$(ProjPath)../../Units/MMLCore/"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
<Optimizations>
|
||||
<VariablesInRegisters Value="True"/>
|
||||
</Optimizations>
|
||||
</CodeGeneration>
|
||||
<Other>
|
||||
<CustomOptions Value="-dUseCThreads
|
||||
-dM_MEMORY_DEBUG"/>
|
||||
|
@ -1,7 +1,7 @@
|
||||
object Form1: TForm1
|
||||
Left = 237
|
||||
Left = 369
|
||||
Height = 527
|
||||
Top = 190
|
||||
Top = 223
|
||||
Width = 779
|
||||
ActiveControl = Button1
|
||||
Caption = 'Form1'
|
||||
|
@ -1,10 +1,10 @@
|
||||
{ This is an automatically generated lazarus resource file }
|
||||
|
||||
LazarusResources.Add('TForm1','FORMDATA',[
|
||||
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3#237#0#6'Height'#3#15#2#3'Top'#3#190#0#5'W'
|
||||
+'idth'#3#11#3#13'ActiveControl'#7#7'Button1'#7'Caption'#6#5'Form1'#12'Client'
|
||||
+'Height'#3#15#2#11'ClientWidth'#3#11#3#8'Position'#7#14'poScreenCenter'#10'L'
|
||||
+'CLVersion'#6#6'0.9.29'#0#7'TButton'#7'Button1'#4'Left'#2#8#6'Height'#2#25#3
|
||||
+'Top'#2#16#5'Width'#2'K'#7'Caption'#6#7'Button1'#7'OnClick'#7#12'Button1Clic'
|
||||
+'k'#8'TabOrder'#2#0#0#0#0
|
||||
]);
|
||||
|
||||
LazarusResources.Add('TForm1','FORMDATA',[
|
||||
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3'q'#1#6'Height'#3#15#2#3'Top'#3#223#0#5'Wi'
|
||||
+'dth'#3#11#3#13'ActiveControl'#7#7'Button1'#7'Caption'#6#5'Form1'#12'ClientH'
|
||||
+'eight'#3#15#2#11'ClientWidth'#3#11#3#8'Position'#7#14'poScreenCenter'#10'LC'
|
||||
+'LVersion'#6#6'0.9.29'#0#7'TButton'#7'Button1'#4'Left'#2#8#6'Height'#2#25#3
|
||||
+'Top'#2#16#5'Width'#2'K'#7'Caption'#6#7'Button1'#7'OnClick'#7#12'Button1Clic'
|
||||
+'k'#8'TabOrder'#2#0#0#0#0
|
||||
]);
|
||||
|
@ -25,6 +25,8 @@ var
|
||||
Form1: TForm1;
|
||||
|
||||
implementation
|
||||
uses
|
||||
lclintf;
|
||||
|
||||
type
|
||||
TMyThread = class(TThread)
|
||||
@ -63,7 +65,7 @@ Const
|
||||
{$ENDIF}
|
||||
Var
|
||||
Client: TClient;
|
||||
w,h, x, y, xx, yy, i:integer;
|
||||
w,h, x, y, xx, yy, i,t1,t2:integer;
|
||||
bmp: TBitmap;
|
||||
ReturnData : TRetData;
|
||||
arr: Array Of Integer;
|
||||
@ -79,8 +81,19 @@ begin
|
||||
|
||||
Writeln('Creating the client');
|
||||
Client := TClient.Create;
|
||||
//Client.MWindow.SetTarget(77594696);
|
||||
Writeln('Getting the dimensions');
|
||||
Client.MWindow.GetDimensions(w, h);
|
||||
t1 := lclintf.gettickcount;
|
||||
for i := 0 to 100 do
|
||||
Client.MFinder.FindColor(x, y, 123456, 0, 0, w, h);
|
||||
t2 := lclintf.gettickcount;
|
||||
writeln(inttostr(round((t2 - t1) / 101)));
|
||||
|
||||
//break;
|
||||
|
||||
|
||||
|
||||
writeln(inttostr(w) + ' , ' + inttostr(h));
|
||||
Writeln('Setting target');
|
||||
// Client.MWindow.SetTarget(67232,w_window);
|
||||
@ -159,7 +172,7 @@ begin
|
||||
// Client.MWIndow.SetTarget(PRGB32(@Arr[0]), Point(Loopx + 1, Loopy + 1));
|
||||
Client.MWindow.FreeReturnData;
|
||||
|
||||
Client.MInput.IsMouseButtonDown(mouse_Left);
|
||||
Client.MInput.IsMouseButtonDown(mouse_Right);
|
||||
// Sleep(1000);
|
||||
if Client.MInput.IsMouseButtonDown(mouse_Left) then
|
||||
writeln('Left mouse is down!');
|
||||
|
@ -201,7 +201,7 @@ begin
|
||||
|
||||
event.xbutton.send_event := 1;
|
||||
event.xbutton.same_screen:= 1;
|
||||
event.xbutton.subwindow:= 0;
|
||||
event.xbutton.subwindow:= 0; // this can't be right.
|
||||
event.xbutton.root := TClient(Client).MWindow.DesktopWindow;
|
||||
event.xbutton.window := TClient(Client).MWindow.CurWindow;
|
||||
event.xbutton.x_root:= x;
|
||||
|
@ -195,7 +195,7 @@ begin
|
||||
XSetErrorHandler(Old_Handler);
|
||||
Exit;
|
||||
end;
|
||||
WriteLn(IntToStr(Self.XWindowImage^.width) + ', ' + IntToStr(Self.XWindowImage^.height));
|
||||
//WriteLn(IntToStr(Self.XWindowImage^.width) + ', ' + IntToStr(Self.XWindowImage^.height));
|
||||
Result.Ptr := PRGB32(Self.XWindowImage^.data);
|
||||
Result.IncPtrWith := 0;
|
||||
Self.XImageFreed:=False;
|
||||
|
Loading…
Reference in New Issue
Block a user