API Update:Add CallBack
This commit is contained in:
@@ -17,7 +17,7 @@ type
|
||||
private
|
||||
//p:Pointer;
|
||||
public
|
||||
//constructor Create(p:Pointer);
|
||||
constructor Create(s:string);
|
||||
//function Call(OutType:PTypeInfo;args:TArray<TValue>;CallType:TRTBCallType=CRTBCallTypeDefault):TValue;override;
|
||||
//destructor Destroy;override;
|
||||
end;
|
||||
@@ -597,19 +597,9 @@ function TRTBLuaCompiler.TRTBLuaSource.Compilate:TRTBModule;
|
||||
var
|
||||
templib,PreDecl:string;
|
||||
i,sb:NativeUInt;
|
||||
FuncDict:TDictionary<string,NativeUInt>;
|
||||
RegVarDict:TDictionary<string,TPair<NativeUInt,PTypeInfo>>;
|
||||
p:pointer;
|
||||
begin
|
||||
//FuncDict:=TDictionary<string,NativeUInt>.Create();
|
||||
with funcs do
|
||||
if Count<>0 then
|
||||
for i:=0 to Count-1 do
|
||||
begin
|
||||
PreDecl:=PreDecl+Strings[i]+sLineBreak;
|
||||
FuncDict.Add(Strings[i],base);
|
||||
inc(base,SizeOf(pointer));
|
||||
end;
|
||||
{RegVarDict:=TDictionary<string,TPair<NativeUInt,PTypeInfo>>.Create();
|
||||
with regvars do
|
||||
if Count<>0 then
|
||||
@@ -625,7 +615,7 @@ with consts do
|
||||
with Items[i] do
|
||||
ConstParse(Key,Value,PreDecl,base);}
|
||||
|
||||
//Result:=TRTBFasmModule.Create(p,Res.sb,FuncDict,RegVarDict);
|
||||
Result:=TRTBLuaModule.Create(FText,funcs);
|
||||
end;
|
||||
|
||||
destructor TRTBLuaCompiler.TRTBLuaSource.Destroy;
|
||||
|
||||
Reference in New Issue
Block a user