diff --git a/Projects/Simba/simbaunit.lfm b/Projects/Simba/simbaunit.lfm index d207d31..a8a7697 100644 --- a/Projects/Simba/simbaunit.lfm +++ b/Projects/Simba/simbaunit.lfm @@ -1,7 +1,7 @@ object SimbaForm: TSimbaForm - Left = 143 + Left = 483 Height = 623 - Top = 115 + Top = 95 Width = 660 AllowDropFiles = True Caption = 'THA FUKING Simba' @@ -3098,10 +3098,11 @@ object SimbaForm: TSimbaForm NumberAttri.Foreground = clNavy StringAttri.Foreground = clBlue SymbolAttri.Foreground = clRed + CaseLabelAttri.Style = [fsItalic] DirectiveAttri.Foreground = clRed DirectiveAttri.Style = [fsBold] CompilerMode = pcmObjFPC - NestedComments = True + NestedComments = False left = 528 top = 200 end @@ -3112,7 +3113,7 @@ object SimbaForm: TSimbaForm NumberAttri.Foreground = clHotLight StringAttri.Foreground = clFuchsia CompilerMode = pcmObjFPC - NestedComments = True + NestedComments = False left = 568 top = 200 end diff --git a/Projects/Simba/simbaunit.pas b/Projects/Simba/simbaunit.pas index 0bbc1b2..41b57af 100644 --- a/Projects/Simba/simbaunit.pas +++ b/Projects/Simba/simbaunit.pas @@ -46,7 +46,7 @@ uses CastaliaSimplePasPar, v_AutoCompleteForm, PSDump; const - SimbaVersion = 675; + SimbaVersion = 676; type diff --git a/Units/MMLAddon/PSInc/Wrappers/dtm.inc b/Units/MMLAddon/PSInc/Wrappers/dtm.inc index 0879198..c83dc17 100644 --- a/Units/MMLAddon/PSInc/Wrappers/dtm.inc +++ b/Units/MMLAddon/PSInc/Wrappers/dtm.inc @@ -24,13 +24,13 @@ function ps_FindDTM(DTM: Integer; var x, y: Integer; xs, ys, xe, ye: Integer): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTM(MDTM.GetDTM(DTM),x,y,xs,ys,xe,ye); + result := MFinder.FindDTM(MDTM.GetDTM(DTM)^,x,y,xs,ys,xe,ye); end; function ps_FindDTMs(DTM: Integer; var p: TPointArray; xs, ys, xe, ye: Integer): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTMs(MDTM.GetDTM(DTM), p, xs, ys, xe, ye); + result := MFinder.FindDTMs(MDTM.GetDTM(DTM)^, p, xs, ys, xe, ye); end; function ps_FindDTMRotatedAlternating(DTM: Integer; var x, y: Integer; xs, ys, xe, ye: @@ -38,7 +38,7 @@ function ps_FindDTMRotatedAlternating(DTM: Integer; var x, y: Integer; xs, ys, x var aFound: Extended): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM), x,y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,true); + result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM)^, x,y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,true); end; function ps_FindDTMRotatedSE(DTM: Integer; var x, y: Integer; xs, ys, xe, ye: @@ -46,20 +46,20 @@ function ps_FindDTMRotatedSE(DTM: Integer; var x, y: Integer; xs, ys, xe, ye: var aFound: Extended): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM), x, y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,false); + result := MFinder.FindDTMRotated(MDTM.GetDTM(DTM)^, x, y, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound,false); end; function ps_FindDTMsRotatedAlternating(DTM: Integer; var Points: TPointArray; xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; var aFound: T2DExtendedArray): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM), Points, xs, ys, xe, ye, + result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM)^, Points, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound, true); end; function ps_FindDTMsRotatedSE(DTM: Integer; var Points: TPointArray; xs, ys, xe, ye: Integer; sAngle, eAngle, aStep: Extended; var aFound: T2DExtendedArray): Boolean; extdecl; begin with CurrThread.Client do - result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM), Points, xs, ys, xe, ye, + result := MFinder.FindDTMsRotated(MDTM.GetDTM(DTM)^, Points, xs, ys, xe, ye, sAngle, eAngle, aStep, aFound, false); end; @@ -81,7 +81,7 @@ end; function ps_GetDTM(index: Integer) : pDTM; extdecl; begin - result := CurrThread.Client.MDTM.GetDTM(index); + result := CurrThread.Client.MDTM.GetDTM(index)^; end; function ps_AddDTM(const d: TDTM): Integer; extdecl; diff --git a/Units/MMLAddon/mmlpsthread.pas b/Units/MMLAddon/mmlpsthread.pas index c07e49f..da24629 100644 --- a/Units/MMLAddon/mmlpsthread.pas +++ b/Units/MMLAddon/mmlpsthread.pas @@ -587,7 +587,8 @@ procedure TPSThread.OnProcessDirective(Sender: TPSPreProcessor; Parser: TPSPascalPreProcessorParser; const Active: Boolean; const DirectiveName, DirectiveParam: string; var Continue: Boolean); begin - Continue := ProcessDirective(DirectiveName, DirectiveParam); + if CompareText(DirectiveName, 'LOADLIB') = 0 then + Continue := not ProcessDirective(DirectiveName,DirectiveParam); end; function TPSThread.PSScriptFindUnknownFile(Sender: TObject; diff --git a/Units/MMLCore/dtm.pas b/Units/MMLCore/dtm.pas index 775cb68..a525c26 100644 --- a/Units/MMLCore/dtm.pas +++ b/Units/MMLCore/dtm.pas @@ -43,9 +43,10 @@ type public function AddDTM(const d: TDTM): Integer; function AddpDTM(const d: pDTM): Integer; - function GetDTM(index: Integer) :pDTM; + function GetDTM(index: Integer) :ppDTM; procedure FreeDTM(DTM: Integer); function StringToDTM(const S: String): pDTM; + function DTMToString(const DTM : PDTM) : string; procedure SetDTMName(DTM: Integer;const S: String); constructor Create(Owner: TObject); destructor Destroy; override; @@ -169,6 +170,15 @@ begin result.l := length(result.p); end; + +function TMDTM.DTMToString(const DTM: PDTM): string; +var + i : integer; +begin + if DTM.l = 0 then + exit; +end; + procedure TMDTM.CheckIndex(index: integer); begin if (index < 0) or (index >= Length(DTMList)) or (DTMList[Index] = nil) then @@ -210,10 +220,10 @@ end; Returns true is succesfull, false if the dtm does not exist. /\} -function TMDTM.GetDTM(index: Integer) :pDTM; +function TMDTM.GetDTM(index: Integer) :ppDTM; begin CheckIndex(index); - result := DTMList[index]^; + result := DTMList[index]; end; procedure TMDTM.SetDTMName(DTM: Integer;const s: string);