TUserCastle
TUserCastle 属性名称 只读 功能 属性 property MapCastle: TEnvirnoment Y 城堡所在地图 property MapPalace: TEnvirnoment Y 皇宫所在地图 property MapSecret: TEnvirnoment Y 密道所在地图 property Name: String Y 城堡所在地图名 property TotalGold: Integer 城堡资金 property TodayIncome: Integer Y 今日收入 property Guild: TGUild Y 城堡所属行会 property HomeMap: String 行会回城点地图 property HomeX: Integer 行会回城点X property HomeY: Integer 行会回城点Y property WarDate: TDateTime 攻城日期 property UnderWar: Boolean 是否正在攻城 property MainDoor: TActor 城门 property MainDoorOpened: Boolean 城门是否打开 property LeftWall: TActor 皇宫左墙 property CenterWall: TActor 皇宫门 property RightWall: TActor 皇宫右墙 property Guard[Index: Integer]: TActor 取指定序号的卫士(序号0-3) property Archer[Index: Integer]: TActor 取指定序号的弓箭手(序号0-11) property AttackWarCount: Integer 已申请的攻城战总数 property AttackWarDate[Index: Integer]: TDateTime 取一个攻城战的日期 property AttackWarGuild[Index: Integer]: TGUild 取一个攻城战的申请行会 property AttackGuildCount: Integer 正在攻城的行会总数 property AttackGuild[Index: Integer]: TGUild 取一个正在攻城的行会
函数名称 功能 函数 function InCastleWarArea(Envir: TEnvirnoment; MapX, MapY: Integer): Boolean; 指定的地图X、Y坐标是否在攻城范围 function IsMember(Cert: TActor): Boolean; 判断是否为城堡成员 function IsMasterGuild(Guild: TGUild): Boolean; 判断行会是否拥有城堡 function IsAttackGuild(Guild: TGUild): Boolean; 是否为攻城方行会 function IsAttackAllyGuild(Guild: TGUild): Boolean; 是否为攻城方行会的联盟行会 function IsDefenseGuild(Guild: TGUild): Boolean; 是否为守城方行会 function IsDefenseAllyGuild(Guild: TGUild): Boolean; 是否为守城方联盟行会 procedure StartWall; 开始攻城战 procedure StopWall; 停止攻城战 function AddAttacker(Guild: TGUild): Boolean; 将行会增加到攻城方列表 function AddAttackerByTime(Guild: TGUild; ATime: TDateTime): Boolean; 将行会增加到指定日期的攻城列表 procedure AddAllAttacker; 将全部公会加入到当前的攻城列表 procedure AddAllAttackerByTime(ATime: TDateTime); 将全部公会加入到指定日期的攻城列表 function RepairDoor: Boolean; 修复大门 function RepairWall(WallIndex: Integer): Boolean; 修复指定位置的城墙 procedure OpenDoor; 打开大门 procedure CloseDoor; 关闭大门 function HireArcher(Index: Integer): Boolean; 在指定的位置租用弓箭手 function HireGuard(Index: Integer): Boolean; 在指定的位置租用卫士 function UnHireArcher(Index: Integer): Boolean; 解散指定位置的弓箭手 function UnHireGuard(Index: Integer): Boolean; 解散指定位置的卫士 function GetChangeDateTime(): TDateTime; 获取城堡被占领时间