mirror of
https://github.com/moparisthebest/Simba
synced 2024-11-25 18:52:15 -05:00
Added some functions.
git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@249 3f818213-9676-44b0-a9b4-5e4c4e03d09d
This commit is contained in:
parent
614533d701
commit
0a46930651
@ -69,6 +69,11 @@ begin;
|
||||
Result := Round(Sqrt(Sqr(x2-x1) + Sqr(y2-y1)));
|
||||
end;
|
||||
|
||||
procedure TerminateScript;
|
||||
begin;
|
||||
CurrThread.PSScript.Stop;
|
||||
end;
|
||||
|
||||
procedure HakunaMatata;
|
||||
begin;
|
||||
OpenWebPage('http://www.youtube.com/v/ejEVczA8PLU&hl=en&fs=1&autoplay=1');
|
||||
|
@ -24,6 +24,7 @@
|
||||
Sender.Comp.AddConstantN('AppPath','string').SetString(CurrThread.AppPath);
|
||||
Sender.Comp.AddConstantN('ScriptPath','string').SetString(CurrThread.ScriptPath);
|
||||
Sender.Comp.AddTypeS('TIntegerArray', 'Array of integer');
|
||||
Sender.Comp.AddTypes('TBox', 'record X1,Y1,X2,Y2 : Integer; end;');
|
||||
Sender.Comp.AddTypeS('TPointArray','Array of TPoint');
|
||||
Sender.Comp.AddTypeS('TBmpMirrorStyle','(MirrorWidth,MirrorHeight,MirrorLine)');
|
||||
Sender.Comp.AddTypeS('TMask','record White, Black : TPointArray; WhiteHi,BlackHi : integer; W,H : integer;end;');
|
||||
@ -56,6 +57,7 @@ Sender.AddFunction(@ps_addDTM, 'function AddDTM(d: TDTM): Integer;');
|
||||
Sender.AddFunction(@ps_addpDTM, 'function AddpDTM(d: pDTM): Integer;');
|
||||
|
||||
{maths}
|
||||
sender.AddFunction(@ceil,'function ceil(e : extended) : integer');
|
||||
sender.AddFunction(@power,'function pow(base,exponent : extended) : extended');
|
||||
Sender.AddFunction(@max,'function Max(a, b: Integer): Integer;');
|
||||
Sender.AddFunction(@min,'function Min(a, b: Integer): Integer;');
|
||||
@ -90,6 +92,7 @@ Sender.AddFunction(@GetTickCount, 'function GetSystemTime: Integer;');
|
||||
Sender.AddFunction(@CreateForm,'function CreateForm : TForm;');
|
||||
Sender.AddFunction(@CreateButton,'function CreateButton(Owner : TComponent) : TButton');
|
||||
Sender.AddFunction(@HakunaMatata,'procedure HakunaMatata;');
|
||||
Sender.AddFunction(@TerminateScript,'procedure TerminateScript;');
|
||||
|
||||
{web}
|
||||
Sender.AddFunction(@OpenWebPage,'procedure OpenWebPage(url : string);');
|
||||
|
Loading…
Reference in New Issue
Block a user