diff --git a/src/shared/MAPDEF.pas b/src/shared/MAPDEF.pas
index a7137162c81c5be25db278bc34b11462913c11a9..ededbdd40c7f885f7d8ea932af4493002678f51d 100644 (file)
--- a/src/shared/MAPDEF.pas
+++ b/src/shared/MAPDEF.pas
{$INCLUDE mapdef_help.inc}
function trigMonsterId (): Integer; inline;
+ private
+ // user fields
+ function getGamePanelId (): Integer; inline;
+ procedure setGamePanelId (v: Integer); inline;
+
public
property panel[idx: Integer]: TDynRecord read getPanelByIdx;
property panelIndex[pan: TDynRecord]: Integer read getPanelIndex;
property tgPanelID: Integer read getPanelId {write setPanelId};
property tgShotPanelID: Integer read getPanelId {write setPanelId};
property TexturePanel: Integer read getTexturePanel {write setTexturePanel}; // texturepanel, int
+ // user fields
+ property gamePanelId: Integer read getGamePanelId write setGamePanelId;
end;
implementation
constructor TDFPoint.Create (ax, ay: LongInt); begin X := ax; Y := ay; end;
+// ////////////////////////////////////////////////////////////////////////// //
+function TDynRecordHelper.getGamePanelId (): Integer; inline;
+var
+ fld: TDynField;
+begin
+ fld := field['gamePanelId'];
+ if (fld = nil) or (fld.baseType <> TDynField.TType.TInt) then result := -1 else result := fld.ival;
+end;
+
+
+procedure TDynRecordHelper.setGamePanelId (v: Integer); inline;
+begin
+ setUserField('gamePanelId', Integer(v));
+end;
+
+
// ////////////////////////////////////////////////////////////////////////// //
function TDynRecordHelper.getFieldWithType (const aname: AnsiString; atype: TDynField.TType): TDynField; inline;
begin