bool kbAddAttackRouteIgnoreID( int ignoreAreaID ) : ignore this area when finding the route.
bool kbAddAttackRouteIgnoreID( int ignoreAreaID ): 在寻找进攻路径时忽略此区域 ID。
bool kbAddAttackRouteIgnoreType( int ignoreAreaTypeID ) : ignore this areatype when finding the route.
bool kbAddAttackRouteIgnoreType( int ignoreAreaTypeID ): 在寻找进攻路径时忽略此区域类型 ID。
bool kbAddAttackRouteSector( int sector ) : add a new sector to path to.
bool kbAddAttackRouteSector( int sector ): 向进攻路径中添加新的地块(sector)。
void kbAreaCalculate() : Creates areas and area groups. DO THIS BEFORE ANYTHING ELSE IN YOUR SCRIPT.
void kbAreaCalculate(): 创建区域及区域组。请在脚本中最先执行此操作。
int kbAreaFindBestGatherAreaID( int unitTypeID ) : Returns the Area ID of the best area to gather the given unit type.
int kbAreaFindBestGatherAreaID( int unitTypeID ): 返回最适合该单位类型采集的区域 ID。
int kbAreaGetBorderAreaID( int areaID, long index ) : Returns the Area ID of the index-th border area in the given area.
int kbAreaGetBorderAreaID( int areaID, long index ): 返回给定区域的第 index 个边界区域的 ID。
vector kbAreaGetCenter( int areaID ) : Returns the center of the given area.
vector kbAreaGetCenter( int areaID ): 返回指定区域的中心坐标。
int kbAreaGetClosetArea( vector position, int areaType, int areaType1, float minDistance ) : Returns the Area ID of the closest area, of the given types, to given postion.
int kbAreaGetClosetArea( vector position, int areaType, int areaType1, float minDistance ): 在指定范围和类型内返回距离给定坐标最近的区域 ID。
int kbAreaGetIDByPosition( vector position ) : Returns the ID of the given area.
int kbAreaGetIDByPosition( vector position ): 根据给定坐标返回所属区域的 ID。
int kbAreaGetNumber( void ) : Returns the number of areas.
int kbAreaGetNumber( void ): 返回当前所有区域的总数量。
int kbAreaGetNumberBlackTiles( int areaID ) : Returns the number of black tiles in the given area.
int kbAreaGetNumberBlackTiles( int areaID ): 返回此区域内未探索地块(黑地块)的数量。
int kbAreaGetNumberBorderAreas( int areaID ) : Returns the number of border areas for the given area.
int kbAreaGetNumberBorderAreas( int areaID ): 返回此区域邻接的边界区域数量。
int kbAreaGetNumberFogTiles( int areaID ) : Returns the number of fog tiles in the given area.
int kbAreaGetNumberFogTiles( int areaID ): 返回此区域内处于战争迷雾(fog)状态的地块数量。
int kbAreaGetNumberTiles( int areaID ) : Returns the number of tiles in the given area.
int kbAreaGetNumberTiles( int areaID ): 返回此区域包含的地块总数。
int kbAreaGetNumberUnits( int areaID ) : Returns the number of units in the given area.
int kbAreaGetNumberUnits( int areaID ): 返回此区域内的单位数量。
int kbAreaGetNumberVisibleTiles( int areaID ) : Returns the number of visible tiles in the given area.
int kbAreaGetNumberVisibleTiles( int areaID ): 返回此区域可见的地块数量。
int kbAreaGetType( int areaID ) : Returns the Type of area.
int kbAreaGetType( int areaID ): 返回此区域的类型标识。
int kbAreaGetUnitID( int areaID, long index ) : Returns the Unit ID of the index-th unit in the given area.
int kbAreaGetUnitID( int areaID, long index ): 获取此区域内第 index 个单位的 ID。
int kbAreaGetVisibilityChangeTime( int areaID ) : Returns the gametime of the last visibility change for the given area.
int kbAreaGetVisibilityChangeTime( int areaID ): 返回此区域最后一次可见性变化发生的游戏时间。
int kbAreaGetVPSiteID(int areaID) : returns an area's VP site ID (-1 if an area doesn't have a VP site).
int kbAreaGetVPSiteID(int areaID): 返回此区域的 VP(胜利点)场所 ID,若无则返回 -1。
vector kbAreaGroupGetCenter( int groupID ) : Returns the center of the given areaGroup.
vector kbAreaGroupGetCenter( int groupID ): 返回指定区域组的中心点坐标。
int kbAreaGroupGetIDByPosition( vector position ) : Returns the ID of the given area group.
int kbAreaGroupGetIDByPosition( vector position ): 根据坐标位置获取所属的区域组 ID。
bool kbAttackRouteAddPath( int attackRouteID, int pathID) : Rreturns true if path was added to attack route.
bool kbAttackRouteAddPath( int attackRouteID, int pathID ): 将指定路径添加到进攻路线,成功时返回 true。
bool kbBaseAddUnit( int playerID, int baseID, int unitID ) : Adds the given unit to the base.
bool kbBaseAddUnit( int playerID, int baseID, int unitID ): 将指定单位加入到某基地中。
int kbBaseCreate( int playerID, string name, vector position, float distance ) : Creates a base.
int kbBaseCreate( int playerID, string name, vector position, float distance ): 创建一个新的基地并返回其 ID。
bool kbBaseDestroy( int playerID, int baseID ) : Destroys the given base.
bool kbBaseDestroy( int playerID, int baseID ): 销毁指定基地。
void kbBaseDestroyAll( int playerID ) : Destroys all of the bases for the given player.
void kbBaseDestroyAll( int playerID ): 销毁该玩家的所有基地。
int kbBaseFindCreateResourceBase( int resourceType, int resourceSubType, int parentBaseID ) : Finds/Creates a resource base.
int kbBaseFindCreateResourceBase( int resourceType, int resourceSubType, int parentBaseID ): 查找或创建一个资源基地(隶属 parentBaseID)。
int kbBaseFindForwardMilitaryBase( int enemyPlayerID, int enemyBaseID ) : Finds/Creates a 'forward' military base against the given enemy base.
int kbBaseFindForwardMilitaryBase( int enemyPlayerID, int enemyBaseID ): 查找或创建针对此敌方基地的前线军事基地。
bool kbBaseGetActive( int playerID, int baseID ) : Gets the active flag of the base.
bool kbBaseGetActive( int playerID, int baseID ): 返回此基地是否处于激活状态。
vector kbBaseGetBackVector( int playerID, int baseID ) : Gets the back vector of the base.
vector kbBaseGetBackVector( int playerID, int baseID ): 返回此基地的背向向量(back vector)。
bool kbBaseGetEconomy( int playerID, int baseID ) : Gets the economy flag of the base.
bool kbBaseGetEconomy( int playerID, int baseID ): 查询此基地是否被标记为经济基地。
bool kbBaseGetForward( int playerID, int baseID ): Gets the forward flag of the base.
bool kbBaseGetForward( int playerID, int baseID ):获取基地是否被标记为前线(forward)的状态。
vector kbBaseGetFrontVector( int playerID, int baseID ): Gets the front vector of the base.
vector kbBaseGetFrontVector( int playerID, int baseID ):获取该基地的前方向量。
int kbBaseGetIDByIndex( int playerID, int index ): Returns the BaseID for the given base.
int kbBaseGetIDByIndex( int playerID, int index ):根据索引获取该玩家的某基地 ID。
vector kbBaseGetLastKnownDamageLocation( int playerID, int baseID ): Gets the last known damage location of the base.
vector kbBaseGetLastKnownDamageLocation( int playerID, int baseID ):获取该基地最近一次受伤害时的位置坐标。
vector kbBaseGetLocation( int playerID, int baseID ): Gets the location of the base.
vector kbBaseGetLocation( int playerID, int baseID ):获取该基地的坐标位置。
bool kbBaseGetMain( int playerID, int baseID ): Gets the main flag of the base.
bool kbBaseGetMain( int playerID, int baseID ):获取该基地是否被标记为主基地。
int kbBaseGetMainID( int playerID ): Gets the main base ID for the player.
int kbBaseGetMainID( int playerID ):获取指定玩家的主基地 ID。
float kbBaseGetMaximumResourceDistance( int playerID, int baseID ): Gets the maximum resource distance of the base.
float kbBaseGetMaximumResourceDistance( int playerID, int baseID ):获取该基地可采集资源的最大距离阈值。
bool kbBaseGetMilitary( int playerID, int baseID ): Gets the military flag of the base.
bool kbBaseGetMilitary( int playerID, int baseID ):获取该基地是否被标记为军事用途(military)。
vector kbBaseGetMilitaryGatherPoint( int playerID, int baseID ): Gets the military gather point of the base.
vector kbBaseGetMilitaryGatherPoint( int playerID, int baseID ):获取该基地的军事集结点坐标。
int kbBaseGetNextID( void ): Returns the ID of the next base that will be created.
int kbBaseGetNextID( void ):返回下一个即将被创建的基地 ID。
int kbBaseGetNumber( int playerID ): Returns the number of bases for the given player.
int kbBaseGetNumber( int playerID ):返回该玩家拥有的基地数量。
int kbBaseGetNumberUnits( int playerID, int baseID, int relation, int unitTypeID ): Returns the number of units that match the criteria.
int kbBaseGetNumberUnits( int playerID, int baseID, int relation, int unitTypeID ):返回此基地中符合指定关系与单位类型的单位数量。
int kbBaseGetOwner( int baseID ): Returns the player ID of the specified base's owner.
int kbBaseGetOwner( int baseID ):返回此基地所属玩家的 ID。
bool kbBaseGetSettlement( int playerID, int baseID ): Gets the settlement flag of the base.
bool kbBaseGetSettlement( int playerID, int baseID ):获取该基地是否被标记为城镇殖民点(settlement)。
int kbBaseGetTimeUnderAttack( int playerID, int baseID ): Returns the number of continuous seconds the base has been under attack.
int kbBaseGetTimeUnderAttack( int playerID, int baseID ):返回该基地持续被攻击的时间(秒)。
bool kbBaseGetUnderAttack( int playerID, int baseID ): Gets the under attack flag of the base.
bool kbBaseGetUnderAttack( int playerID, int baseID ):获取该基地是否正处于被攻击状态。
bool kbBaseRemoveUnit( int playerID, int baseID, int unitID ): Removes the given unit to the base.
bool kbBaseRemoveUnit( int playerID, int baseID, int unitID ):将指定单位从该基地中移除。
bool kbBaseSetActive( int playerID, int baseID, bool active ): Sets the active flag of the base.
bool kbBaseSetActive( int playerID, int baseID, bool active ):设置该基地是否处于激活状态。
bool kbBaseSetEconomy( int playerID, int baseID, bool Economy ): Sets the economy flag of the base.
bool kbBaseSetEconomy( int playerID, int baseID, bool Economy ):设置该基地是否用于经济用途(经济基地)。
bool kbBaseSetForward( int playerID, int baseID, bool forward ): Sets the forward flag of the base.
bool kbBaseSetForward( int playerID, int baseID, bool forward ):设置该基地是否为前线基地。
bool kbBaseSetFrontVector( int playerID, int baseID, vector frontVector ): Sets the front (and back) of the base.
bool kbBaseSetFrontVector( int playerID, int baseID, vector frontVector ):设置该基地的前向(与后向)向量。
bool kbBaseSetMain( int playerID, int baseID, bool main ): Sets the main flag of the base.
bool kbBaseSetMain( int playerID, int baseID, bool main ):设置该基地是否为主基地。
void kbBaseSetMaximumResourceDistance( int playerID, int baseID, float distance ): Sets the maximum resource distance of the base.
void kbBaseSetMaximumResourceDistance( int playerID, int baseID, float distance ):设置该基地的最大可采资源距离。
bool kbBaseSetMilitary( int playerID, int baseID, bool military ): Sets the military flag of the base.
bool kbBaseSetMilitary( int playerID, int baseID, bool military ):设置该基地是否为军事基地。
bool kbBaseSetMilitaryGatherPoint( int playerID, int baseID, vector gatherPoint ): Sets the military gather point of the base.
bool kbBaseSetMilitaryGatherPoint( int playerID, int baseID, vector gatherPoint ):设置该基地的军事集结点坐标。
bool kbBaseSetSettlement( int playerID, int baseID, bool settlement ): Sets the settlement flag of the base.
bool kbBaseSetSettlement( int playerID, int baseID, bool settlement ):设置该基地是否为城镇点(settlement)。
bool kbBuildingPlacementAddAreaGroupID( int areaGroupID ): Adds the AreaGroup ID to the current BP.
bool kbBuildingPlacementAddAreaGroupID( int areaGroupID ):将指定区域组 ID 添加到当前建筑放置(BP)配置中。
bool kbBuildingPlacementAddAreaID( int areaID, int numberBorderAreaLayers, bool addCenterInfluence ): Adds the Area ID to the current BP (with the given number of border area layers), addCenterInfluence - adds a positional influence from the area center.
bool kbBuildingPlacementAddAreaID( int areaID, int numberBorderAreaLayers, bool addCenterInfluence ):将指定区域 ID 添加到当前建筑放置配置,可设置边界区域层数,以及是否加入该区域中心位置的影响力。
bool kbBuildingPlacementAddPositionInfluence( vector position, float value, float distance ): Adds the position influence for the current building placement.
bool kbBuildingPlacementAddPositionInfluence( vector position, float value, float distance ):为当前建筑放置配置添加一条位置影响(坐标、影响值、影响距离)。
bool kbBuildingPlacementAddUnitInfluence( int typeID, float value, float distance, long kbResourceID ): Adds the unit influence for the current building placement.
bool kbBuildingPlacementAddUnitInfluence( int typeID, float value, float distance, long kbResourceID ):为当前建筑放置添加指定单位的影响力,可设置影响值与距离。
int kbBuildingPlacementCreate( string name ): Creates a building placement; returns the ID.
int kbBuildingPlacementCreate( string name ):创建一个建筑放置配置,并返回其 ID。
bool kbBuildingPlacementDestroy( int id ): Destroys the given building placement.
bool kbBuildingPlacementDestroy( int id ):销毁指定的建筑放置配置。
vector kbBuildingPlacementGetResultPosition( int bpID ): Returns the vector result position for given BP ID.
vector kbBuildingPlacementGetResultPosition( int bpID ):获取指定建筑放置配置(BP)的结果坐标向量。
float kbBuildingPlacementGetResultValue( int bpID ): Returns the result value for given BP ID.
float kbBuildingPlacementGetResultValue( int bpID ):获取指定建筑放置配置的评估结果值。
bool kbBuildingPlacementResetResults( void ): Resets the current building placement.
bool kbBuildingPlacementResetResults( void ):重置当前建筑放置配置的结果。
bool kbBuildingPlacementSelect( int id ): Selects the given building placement.
bool kbBuildingPlacementSelect( int id ):选中指定的建筑放置配置。
bool kbBuildingPlacementSetBaseID( int baseID, int locationPref ): Sets the base ID and location preference for the current building placement.
bool kbBuildingPlacementSetBaseID( int baseID, int locationPref ):为当前建筑放置配置设置基地 ID 及位置偏好。
bool kbBuildingPlacementSetBuildingType( int buildingTypeID ): Sets the building type for the current building placement.
bool kbBuildingPlacementSetBuildingType( int buildingTypeID ):为当前建筑放置配置指定建筑类型。
bool kbBuildingPlacementSetCenterPosition( vector position, float distance, float obstructionRadius ): Sets up center position-based BP.
bool kbBuildingPlacementSetCenterPosition( vector position, float distance, float obstructionRadius ):以给定坐标为中心设置建筑放置,包含最大距离与阻挡半径。
bool kbBuildingPlacementSetEventHandler( int eventType, string handlerName ): Sets event handler function for the current BP and event.
bool kbBuildingPlacementSetEventHandler( int eventType, string handlerName ):为当前建筑放置配置设定指定类型事件的处理函数。
bool kbBuildingPlacementSetMinimumValue( float minimumValue ): Sets the minimum acceptable value for evaluated spots in the BP.
bool kbBuildingPlacementSetMinimumValue( float minimumValue ):为建筑放置评估点设置最低可接受的数值阈值。
bool kbBuildingPlacementStart( void ): Starts the placement of current building.
bool kbBuildingPlacementStart( void ):开始执行当前建筑的放置评估。
bool kbCanAffordTech( int techID, int escrowID ): Returns true if the player can afford the tech.
bool kbCanAffordTech( int techID, int escrowID ):若玩家资金足以研究指定科技,则返回 true。
bool kbCanAffordUnit( int protoUnitTypeID, int escrowID ): Returns true if the player can afford the proto unit.
bool kbCanAffordUnit( int protoUnitTypeID, int escrowID ):若玩家资金足以训练此原型单位,则返回 true。
bool kbCanPath2( vector pointA, vector pointB, long protoUnitTypeID, float range ): Returns true if the given unit type can path from pointA to pointB.
bool kbCanPath2( vector pointA, vector pointB, long protoUnitTypeID, float range ):判断指定单位类型是否能在给定距离下,从 pointA 寻路至 pointB。
bool kbCanSimPath( vector pointA, vector pointB, long protoUnitTypeID, float range ): Returns true if the given unit type can path from pointA to pointB.
bool kbCanSimPath( vector pointA, vector pointB, long protoUnitTypeID, float range ):判断指定单位类型是否可模拟寻路从 pointA 到 pointB。
int kbCreateAttackRoute( string name, int startAreaID, int goalAreaID, int numInitialRoutes): Returns the Route ID if successful.
int kbCreateAttackRoute( string name, int startAreaID, int goalAreaID, int numInitialRoutes ):创建一条进攻路线并返回其 ID。
int kbCreateAttackRouteWithPath( string name, vector startPt, vector endPt): Returns the Route ID if successful.
int kbCreateAttackRouteWithPath( string name, vector startPt, vector endPt ):基于起始坐标与结束坐标创建进攻路线,并返回其 ID。
int kbCreateTechProgression( string techName, string name ): Creates a tech progression of the given name.
int kbCreateTechProgression( string techName, string name ):基于指定科技名称与自定义名称创建一条科技进程。
int kbCreateUnitProgression( string unitName, string name ): Creates a unit progression of the given name.
int kbCreateUnitProgression( string unitName, string name ):基于指定单位名称与自定义名称创建一条单位进程。
bool kbDestroyAttackRoute( int routeID ): Returns true if the route was deleted.
bool kbDestroyAttackRoute( int routeID ):销毁指定进攻路线,成功则返回 true。
void kbDump( int player1, int player2 ): KB dump for player2's units from player1's perspective.
void kbDump( int player1, int player2 ):从玩家 1 的视角,输出玩家 2 单位的知识库信息。
void kbDumpType( int player1, int player2, string typeName ): KB dump for player2's units of the given type from player1's perspective.
void kbDumpType( int player1, int player2, string typeName ):从玩家 1 的视角,输出玩家 2 指定类型单位的知识库信息。
void kbDumpVPSiteInfo(): blogs out info about all VP sites.
void kbDumpVPSiteInfo():输出所有 VP(胜利点)站点的信息。
bool kbEscrowAllocateCurrentResources( void ): Reallocates the current resource stockpile into the escrows.
bool kbEscrowAllocateCurrentResources( void ):重新分配当前资源储备至各个 escrow(资金账户)。
int kbEscrowCreate( string name, int resourceID, float percentage, int parentID ): Creates an escrow.
int kbEscrowCreate( string name, int resourceID, float percentage, int parentID ):创建一个新的资金账户并返回其 ID,可指定资源类型、资金比例及父账户。
bool kbEscrowDestroy( int escrowID, bool promoteChildren ): Destroys an escrow.
bool kbEscrowDestroy( int escrowID, bool promoteChildren ):销毁指定的资金账户,可选择是否提升其子账户。
bool kbEscrowFlush( int escrowID, int resourceID, bool flushChildren ): Removes all credits (and puts them into the root escrow) of the given resource type from the given escrow.
bool kbEscrowFlush( int escrowID, int resourceID, bool flushChildren ):将指定资源类型在该资金账户中的所有储量转移到根账户,可选择是否同时刷新子账户。
float kbEscrowGetAmount( int escrowID, int resourceID ): Returns the amount of credits in the given escrow for the given resource.
float kbEscrowGetAmount( int escrowID, int resourceID ):返回在此资金账户中指定资源所存的数额。
int kbEscrowGetID( string name ): Returns the ID of the named escrow.
int kbEscrowGetID( string name ):根据资金账户名称返回对应的 ID。
float kbEscrowGetPercentage( int escrowID, int resourceID ): Returns the percentage of the escrow.
float kbEscrowGetPercentage( int escrowID, int resourceID ):获取此资金账户在指定资源上的百分比占比。
bool kbEscrowSetCap( int escrowID, int resourceID, float cap ): Sets the cap of the escrow.
bool kbEscrowSetCap( int escrowID, int resourceID, float cap ):为此资金账户在指定资源上设置上限。
bool kbEscrowSetPercentage( int escrowID, int resourceID, float percentage ): Sets the percentage of the escrow.
bool kbEscrowSetPercentage( int escrowID, int resourceID, float percentage ):设置此资金账户在指定资源上的百分比占比。
int kbFindAreaGroup( int groupType, float surfaceAreaRatio, int compareAreaID) : returns the visible area group that matches the given criteria.
int kbFindAreaGroup( int groupType, float surfaceAreaRatio, int compareAreaID ):在可见区域中查找符合条件的区域组并返回其 ID。
int kbFindAreaGroupByLocation( int groupType, float relativeX, float relativeZ ) : returns the visible area group that matches the given criteria.
int kbFindAreaGroupByLocation( int groupType, float relativeX, float relativeZ ):基于坐标位置在可见区域查找符合条件的区域组。
int kbFindBestBuildingToRepair(vector position, float distance, float healthRatio, int repairUnderAttackUnitTypeID) : returns the id of the best building to repair.
int kbFindBestBuildingToRepair(vector position, float distance, float healthRatio, int repairUnderAttackUnitTypeID ):在指定范围内查找最合适的建筑进行修理并返回其 ID,可设置血量比与是否在被攻击时修理。
long kbFindClosestBase( long playerRelation, vector location ): gets the nearest base of player relation from the location.
long kbFindClosestBase( long playerRelation, vector location ):从给定坐标查找在指定关系(如自己、盟友、敌人等)的最近基地。
int kbGetAge( void ): Returns the current age for the current player.
int kbGetAge( void ):获取当前玩家所处的时代年龄。
int kbGetAgeForPlayer( int id ): Returns the current age for the player specified.
int kbGetAgeForPlayer( int id ):获取指定玩家所在的时代年龄。
float kbGetAICostWeight( int resourceID ): Returns the AI cost weight for the given resource.
float kbGetAICostWeight( int resourceID ):获取指定资源在 AI 计算中的权重值。
float kbGetAmountValidResources( int baseID, int resourceTypeID, int resourceSubTypeID, float distance ): Returns the resource amount of valid KB resources for the resource types.
float kbGetAmountValidResources( int baseID, int resourceTypeID, int resourceSubTypeID, float distance ):返回在指定距离内、符合特定资源类型及子类型的可用资源总量。
int kbGetAttackRouteID( long startAreaID, long goalAreaID): Returns the id of the routes from area1 to area2.
int kbGetAttackRouteID( long startAreaID, long goalAreaID ):获取从起始区域到目标区域的进攻路线 ID。
bool kbGetAutoBaseCreate( void ): Returns the auto base creation value.
bool kbGetAutoBaseCreate( void ):获取是否自动创建基地的设定。
float kbGetAutoBaseCreateDistance( void ): Returns the auto base creation distance.
float kbGetAutoBaseCreateDistance( void ):获取自动创建基地的距离阈值。
bool kbGetAutoBaseDetect( void ): Returns the auto base detection value.
bool kbGetAutoBaseDetect( void ):获取是否自动探测基地的设定。
float kbGetAutoBaseDetectDistance( void ): Returns the auto base creation distance.
float kbGetAutoBaseDetectDistance( void ):获取自动探测基地的距离阈值。
int kbGetBlockID( string blockName ): Returns the UnitID of the cinematic block.
int kbGetBlockID( string blockName ):获取场景动画块(cinematic block)的单位 ID。
vector kbGetBlockPosition( string blockName ): Returns the position of the cinematic block.
vector kbGetBlockPosition( string blockName ):获取场景动画块的坐标位置。
int kbGetBuildLimit(int player, int unitTypeID ): Returns the number of the unit type you are allowed to have (ONLY WORKS ON BASE UNIT TYPES); returns -1 if there is no limit.
int kbGetBuildLimit(int player, int unitTypeID ):获取该单位类型的建造上限(仅适用于基础单位类型),若无上限则返回 -1。
int kbGetCiv( void ): Returns the civilization for the player.
int kbGetCiv( void ):获取当前玩家所属文明的 ID。
int kbGetCivForPlayer( int playerID ): Returns the civ for the given player.
int kbGetCivForPlayer( int playerID ):获取指定玩家所使用的文明 ID。
string kbGetCivName( int civID ): Returns the civ name for the given civ.
string kbGetCivName( int civID ):获取指定文明 ID 的名称字符串。
float kbGetCombatEfficiency( int playerID1, int unitTypeID1, int playerID2, int unitTypeID2 ): Returns the combat efficiency of the comparison (in terms of playerID1's units).
float kbGetCombatEfficiency( int playerID1, int unitTypeID1, int playerID2, int unitTypeID2 ):返回玩家 1 单位与玩家 2 单位在战斗上的比较效率值(以玩家 1 的单位为基准)。
int kbGetCulture( void ): Returns the culture for the player.
int kbGetCulture( void ):获取当前玩家所属文化(culture)的 ID。
int kbGetCultureForPlayer( int playerID ): Returns the culture for the given player.
int kbGetCultureForPlayer( int playerID ):获取指定玩家所使用的文化 ID。
string kbGetCultureName( int cultureID ): Returns the culture name for the given culture.
string kbGetCultureName( int cultureID ):根据文化 ID 获取其名称。
long kbGetHCLevel( int playerID ): Returns the current HomeCity Level of the given player.
long kbGetHCLevel( int playerID ):返回指定玩家的主城等级(HomeCity Level)。
vector kbGetMapCenter( void ): Returns the center vector of the map.
vector kbGetMapCenter( void ):获取地图中心坐标。
float kbGetMapXSize( void ): Returns the X size of the map.
float kbGetMapXSize( void ):获取地图在 X 方向的大小。
float kbGetMapZSize( void ): Returns the Z size of the map.
float kbGetMapZSize( void ):获取地图在 Z 方向的大小。
int kbGetNumAttackRoutes( long startAreaID, long goalAreaID): Returns num paths from start to goal area.
int kbGetNumAttackRoutes( long startAreaID, long goalAreaID ):返回从起始区域到目标区域的可用进攻路线条数。
int kbGetNumberMutualAllies( void ): Returns the number of mutual allies.
int kbGetNumberMutualAllies( void ):获取当前玩家的互盟(mutual)盟友数量。
int kbGetNumberValidResources( int baseID, int resourceTypeID, int resourceSubTypeID, float distance ): Returns the number of valid KB resources for the resource types.
int kbGetNumberValidResources( int baseID, int resourceTypeID, int resourceSubTypeID, float distance ):返回在指定距离内、符合资源类型条件的可用资源数量。
int kbGetNumberValidResourcesByPlan( int planID, int baseID ): Returns the number of valid KB resources for the given plan/base.
int kbGetNumberValidResourcesByPlan( int planID, int baseID ):根据指定计划及基地,返回可用资源数量。
float kbGetPlayerHandicap( int playerID ): Returns the player's handicap multiplier (ie., 1.0 = no handicap).
float kbGetPlayerHandicap( int playerID ):获取玩家的难度修正系数(1.0 表示无修正)。
string kbGetPlayerName( <playerID> ): Returns the player's name.
string kbGetPlayerName( <playerID> ):获取指定玩家的名称字符串。
int kbGetPlayerTeam( <playerID> ): Returns the player's team number.
int kbGetPlayerTeam( <playerID> ):获取指定玩家所属的队伍编号。
int kbGetPop( void ): Returns the current population for the player.
int kbGetPop( void ):获取当前玩家的人口数量。
int kbGetPopCap( void ): Returns the current population cap for the player.
int kbGetPopCap( void ):获取当前玩家的人口上限。
int kbGetPopCapAddition(int player, int unitTypeID ): Returns amount of pop cap addition provided by the given unit type (ONLY WORKS ON BASE UNIT TYPES).
int kbGetPopCapAddition(int player, int unitTypeID ):获取指定基础单位类型所提供的人口上限增量。
int kbGetPopSlots(int player, int unitTypeID ): Returns the number of pop slots this unit takes (ONLY WORKS ON BASE UNIT TYPES).
int kbGetPopSlots(int player, int unitTypeID ):获取此基础单位类型占用的人口槽位数。
int kbGetPopulationSlotsByQueryID( int queryID ): Returns the number of pop slots currently occupied by the results in the given query.
int kbGetPopulationSlotsByQueryID( int queryID ):根据指定查询结果,获取当前占用的人口槽位总数。
int kbGetPopulationSlotsByUnitTypeID( int playerID, int unitTypeID ): Returns the number of pop slots currently occupied by this unit type.
int kbGetPopulationSlotsByUnitTypeID( int playerID, int unitTypeID ):获取该单位类型当前占用的人口槽位总数。
float kbGetProtoUnitAICost( int protoUnitTypeID ): Returns the AI cost for the given protoUnit type ID.
float kbGetProtoUnitAICost( int protoUnitTypeID ):获取指定原型单位的 AI 价值(cost)。
int kbGetProtoUnitID( string name ): Returns the ID of the protounit.
int kbGetProtoUnitID( string name ):根据单位名称获取其原型单位 ID。
string kbGetProtoUnitName( int protoUnitTypeID ): Returns the name of the protounit ID.
string kbGetProtoUnitName( int protoUnitTypeID ):获取该原型单位 ID 所对应的名称。
int kbGetRandomEnabledPUID( int unitTypeID, int escrowID ): Returns a random, valid PUID that's of the given type.
int kbGetRandomEnabledPUID( int unitTypeID, int escrowID ):返回符合指定类型且资金可支付的随机有效单位原型 ID(PUID)。
float kbGetResourceIncome( int resourceID, float seconds, bool relative ): Returns the resource income over the last X seconds.
float kbGetResourceIncome( int resourceID, float seconds, bool relative ):获取在最近 X 秒内的某资源收入量,可选择是否相对于当前值计算。
float kbGetTargetSelectorFactor(int type) : gets the TargetSelector Factor value.
float kbGetTargetSelectorFactor(int type ):获取指定类型的目标选择因子(TargetSelector Factor)数值。
float kbGetTechAICost( int techID ): Returns the AI cost for the given tech ID.
float kbGetTechAICost( int techID ):获取指定科技的 AI 价值。
string kbGetTechName( int techID ): Returns the name of the tech ID.
string kbGetTechName( int techID ):获取指定科技 ID 的名称。
float kbGetTechPercentComplete( int techID ): Returns the percent complete for the the requested tech of the current player.
float kbGetTechPercentComplete( int techID ):获取当前玩家正在研究的该科技完成度百分比。
int kbGetTownAreaID( void ): Returns the area ID of the main town.
int kbGetTownAreaID( void ):获取主城所在的区域 ID。
vector kbGetTownLocation( void ): Returns the location of the main town.
vector kbGetTownLocation( void ):获取主城的坐标位置。
int kbGetUnitBaseTypeID( int unitID ): Returns the base type ID of the unit.
int kbGetUnitBaseTypeID( int unitID ):获取此单位的基础类型 ID。
string kbGetUnitTypeName( int unitTypeID ): Returns the name of the unit type.
string kbGetUnitTypeName( int unitTypeID ):获取此单位类型 ID 对应的名称。
int kbGetVPGeneratorByScoreType(int siteType): returns the protounit ID for the VP generator that corresponds to this type of VP site.
int kbGetVPGeneratorByScoreType(int siteType):返回与此类型 VP 站点相对应的 VP 生成器原型单位 ID。
bool kbHasPlayerLost( <playerID> ): Returns the player's lost status.
bool kbHasPlayerLost( <playerID> ):判断该玩家是否已失败出局。
bool kbIsGameOver(): Returns whether the game is over or not.
bool kbIsGameOver():判断游戏是否已经结束。
bool kbIsPlayerAlly( int playerID ): Returns true if the given player is an ally.
bool kbIsPlayerAlly( int playerID ):若指定玩家是同盟,则返回 true。
bool kbIsPlayerEnemy( int playerID ): Returns true if the given player is an enemy.
bool kbIsPlayerEnemy( int playerID ):若指定玩家是敌对关系,则返回 true。
bool kbIsPlayerHuman( int playerID ): Returns true if the given player is a a human player.
bool kbIsPlayerHuman( int playerID ):若指定玩家为人类控制,则返回 true。
bool kbIsPlayerMutualAlly( int playerID ): Returns true if the given player is a mutual ally.
bool kbIsPlayerMutualAlly( int playerID ):若指定玩家与当前玩家是双向盟友,则返回 true。
bool kbIsPlayerNeutral( int playerID ): Returns true if the given player is a neutral player.
bool kbIsPlayerNeutral( int playerID ):若指定玩家为中立关系,则返回 true。
bool kbIsPlayerResigned( <playerID> ): Returns the player's resigned status.
bool kbIsPlayerResigned( <playerID> ):判断该玩家是否已投降。
bool kbIsPlayerValid( int playerID ): Returns true if the given player is a valid player (i.e. it exists in the game).
bool kbIsPlayerValid( int playerID ):判断该玩家 ID 在当前游戏中是否存在(有效)。
bool kbLocationVisible( vector location ): Returns true if the location is currently visible to the player.
bool kbLocationVisible( vector location ):若当前玩家能看见该坐标位置,则返回 true。
void kbLookAtAllUnitsOnMap( void ): Cheats and looks at all of the units on the map. This will format your harddrive if you're not authorized to use it.
void kbLookAtAllUnitsOnMap( void ):作弊指令,可查看地图上所有单位;(未经授权请勿使用,否则硬盘自带玩笑警告)。
bool kbMakeAttackRoutes(): find all the paths to the sector specified.
bool kbMakeAttackRoutes():查找通往指定区域的所有进攻路径。
float kbMaximumResourceGet( int resourceID ): Returns the maximum amount of the given resource you can have.
float kbMaximumResourceGet( int resourceID ):获取玩家在此资源上的最大可持有值。
bool kbPathAddWaypoint( int pathID, vector waypoint ): Adds the waypoint to the given path.
bool kbPathAddWaypoint( int pathID, vector waypoint ):向指定路径添加一个路径点。
int kbPathCreate( string name ): Creates a path with the given name.
int kbPathCreate( string name ):创建一条命名路径并返回其 ID。
bool kbPathDestroy( int pathID ): Destroys the given path.
bool kbPathDestroy( int pathID ):销毁指定路径。
int kbPathGetIDByIndex( long index ): Returns the index-th path ID.
int kbPathGetIDByIndex( long index ):返回第 index 条路径的路径 ID。
float kbPathGetLength( int pathID ): Returns the length of the given path.
float kbPathGetLength( int pathID ):获取指定路径的长度。
string kbPathGetName( int pathID ): Returns the name of the given path.
string kbPathGetName( int pathID ):获取指定路径的名称。
int kbPathGetNumber( void ): Returns the number of paths.
int kbPathGetNumber( void ):返回当前已有的路径总数。
int kbPathGetNumberWaypoints( int pathID ): Returns the number of waypoints in the given path.
int kbPathGetNumberWaypoints( int pathID ):获取指定路径包含的路径点总数。
vector kbPathGetWaypoint( int pathID, long waypointNumber ): Returns the appropriate waypoint from the given path.
vector kbPathGetWaypoint( int pathID, long waypointNumber ):获取指定路径的第 waypointNumber 个路径点坐标。
float kbProgessionGetTotalResourceCost( int progressionID, int resourceID ): Returns the total cost of the given resource for this progressionID. A resourceID of -1 will return the total Cost.
float kbProgessionGetTotalResourceCost( int progressionID, int resourceID ):返回此进程 ID 在指定资源上的总消耗;若 resourceID = -1,则返回所有资源的总消耗。
int kbProgressionGetNodeData( int progressionID, int nodeIndex ): Returns the data at nodeIndex, either UnitID or TechID, depending on the type.
int kbProgressionGetNodeData( int progressionID, int nodeIndex ):返回此进程在指定节点索引处的具体数据(可能是单位或科技的 ID)。
int kbProgressionGetNodeType( int progressionID, int nodeIndex ): Returns the type of node at the given index, either Unit type or Tech type.
int kbProgressionGetNodeType( int progressionID, int nodeIndex ):返回该进程在指定节点索引处的类型(单位或科技)。
int kbProgressionGetTotalNodes( int progressionID ): Returns the total number of steps to complete the progression.
int kbProgressionGetTotalNodes( int progressionID ):返回此进程的总节点数量(完成此进程的阶段数)。
bool kbProtoUnitAvailable( int protoUnitID ): Returns true if the protoUnit is currently available.
bool kbProtoUnitAvailable( int protoUnitID ):若该原型单位可用,则返回 true。
bool kbProtoUnitIsType( int playerID, int protoUnitID, int unitTypeID ): Returns true if the protounit is of the unitTypeID.
bool kbProtoUnitIsType( int playerID, int protoUnitID, int unitTypeID ):判断该原型单位是否属于给定的单位类型 ID。
float kbResourceGet( int resourceID ): Returns the current amount of the given resource.
float kbResourceGet( int resourceID ):获取玩家当前拥有的此资源数。
long kbResourceGetXP( int playerID ): Returns the current amount XP the given player has.
long kbResourceGetXP( int playerID ):获取指定玩家当前的 XP(经验值)数。
bool kbSetAICostWeight( int resourceID, float weight ): Sets the weight this resource type is given during AI cost calculuations.
bool kbSetAICostWeight( int resourceID, float weight ):为指定资源类型在 AI 成本计算中设置权重。
void kbSetAutoBaseCreate( bool v ): Sets the auto base creation value.
void kbSetAutoBaseCreate( bool v ):设置是否自动创建基地。
void kbSetAutoBaseCreateDistance( float v ): Sets the auto base creation distance.
void kbSetAutoBaseCreateDistance( float v ):设置自动创建基地的距离阈值。
void kbSetAutoBaseDetect( bool v ): Sets the auto base detection value.
void kbSetAutoBaseDetect( bool v ):设置是否自动探测基地。
void kbSetAutoBaseDetectDistance( float v ): Sets the auto base creation distance.
void kbSetAutoBaseDetectDistance( float v ):设置自动探测基地的距离阈值。
void kbSetForwardBasePosition(vector position):set the explicit position that every forward base will use.
void kbSetForwardBasePosition(vector position):指定所有前线基地将采用的固定位置。
void kbSetPlayerHandicap( int playerID, float handicap ): Sets the indicated player's handicap multiplier (ie., 1.0 = no handicap).
void kbSetPlayerHandicap( int playerID, float handicap ):为指定玩家设置难度修正系数(1.0 表示无修正)。
int kbSetTargetSelectorFactor(int type, float val) : sets the TargetSelector Factor value.
int kbSetTargetSelectorFactor(int type, float val ):设置指定类型的目标选择因子(TargetSelector Factor)的数值,返回更新结果。
bool kbSetTownLocation( vector location ): Sets the location of the main town.
bool kbSetTownLocation( vector location ):设置主城的坐标位置。
bool kbSetupForResource( int baseID, int resourceID, float distance, float amount ): Returns true if amount of resource is within distance of a dropsite.
bool kbSetupForResource( int baseID, int resourceID, float distance, float amount ):判断在指定距离内是否存在可满足该资源数额的资源点(包含可投递点)。
bool kbTargetSelectorAddQueryResults( int queryID ): Sets the list of potential targets to the results in the given query.
bool kbTargetSelectorAddQueryResults( int queryID ):将指定查询的结果列表加入到目标选择器的可选目标列表中。
bool kbTargetSelectorAddUnitType( int protoUnitTypeID ): Add the UAIT for the given BASE unit type as a filter.
bool kbTargetSelectorAddUnitType( int protoUnitTypeID ):将指定基础单位类型的过滤条件加入目标选择器。
int kbTargetSelectorCreate( string name ): Creates a target selector; returns the ID.
int kbTargetSelectorCreate( string name ):创建一个目标选择器并返回其 ID。
bool kbTargetSelectorDestroy( int id ): Destroys the given target selector.
bool kbTargetSelectorDestroy( int id ):销毁指定目标选择器。
int kbTargetSelectorGetNumberResults( void ): Returns the number of results in the given target selector.
int kbTargetSelectorGetNumberResults( void ):返回当前目标选择器中的结果数量。
int kbTargetSelectorGetResultValue( int index ): Returns the result value for given index of the current target selector.
int kbTargetSelectorGetResultValue( int index ):获取当前目标选择器内指定索引处的结果值。
bool kbTargetSelectorResetResults( void ): Resets the current target selector.
bool kbTargetSelectorResetResults( void ):重置当前目标选择器的结果。
bool kbTargetSelectorSelect( int id ): Selects the given target selector.
bool kbTargetSelectorSelect( int id ):选中指定的目标选择器。
bool kbTargetSelectorStart( void ): Starts the current target selector.
bool kbTargetSelectorStart( void ):启动当前目标选择器的计算。
float kbTechCostPerResource( int techID, int resourceID): returns the cost of the tech for the given resource.
float kbTechCostPerResource( int techID, int resourceID ):获取此科技在指定资源上的消耗数值。
int kbTechGetStatus( int techID ): Returns the current tech status for the current player of the requested tech.
int kbTechGetStatus( int techID ):返回该科技对当前玩家来说的研究状态。
void kbTechTreeDump( void ): Dumps the current state of the KBTT.
void kbTechTreeDump( void ):输出知识库科技树(KBTT)的当前状态信息。
int kbTechTreeGetCheapestEconUpgrade( int resourceUnitTypeID ): gets cheapest researchable econ upgrade, optionally for specified resource unit type.
int kbTechTreeGetCheapestEconUpgrade( int resourceUnitTypeID ):获取最廉价且可研究的经济升级,可指定资源单位类型。
int kbTechTreeGetCheapestUnitUpgrade( int unitTypeID ): gets cheapest researchable unit upgrade, optionally for specified unit/unit line.
int kbTechTreeGetCheapestUnitUpgrade( int unitTypeID ):获取最廉价且可研究的单位升级,可指定单位或系列。
float kbTotalResourceGet( int resourceID ): Returns the total amount of the given resource gathered to this point in the game.
float kbTotalResourceGet( int resourceID ):返回游戏进行至当前时点时,玩家在该资源上已累计获取的总量。
float kbUnitCostPerResource( int protoUnitID, int resourceID): returns the cost of the protounit for the given resource.
float kbUnitCostPerResource( int protoUnitID, int resourceID ):获取此原型单位在指定资源上的消耗数值。
int kbUnitCount(int player, int unitTypeID, int stateID ): Returns a quick unit count of units for a player.
int kbUnitCount(int player, int unitTypeID, int stateID ):快速返回某玩家在指定状态下(stateID)的此单位类型数量。
void kbUnitCountConsole(int playerID1, int playerID2, string unitType, string state(s) ): Returns a quick unit count of player2's units from player1's perspective.
void kbUnitCountConsole(int playerID1, int playerID2, string unitType, string state(s) ):在控制台输出玩家 2 单位类型及状态的数量(从玩家 1 的视角)。
int kbUnitGetActionType( int unitID ): Returns the actionTypeID of the unit.
int kbUnitGetActionType( int unitID ):获取此单位的动作类型 ID。
int kbUnitGetAreaID( int unitID ): Returns the area ID for this unit ID.
int kbUnitGetAreaID( int unitID ):获取此单位所在区域的 ID。
int kbUnitGetArmyID( int unitID ): Returns the army ID for this unit ID.
int kbUnitGetArmyID( int unitID ):获取此单位所隶属的军队 ID。
int kbUnitGetBaseID( int unitID ): Returns the base ID for this unit ID.
int kbUnitGetBaseID( int unitID ):获取此单位所属的基地 ID。
float kbUnitGetCurrentAICost( int unitID ): Returns the current AI cost (worth) for this unit ID.
float kbUnitGetCurrentAICost( int unitID ):获取此单位的当前 AI 价值(效益)。
float kbUnitGetCurrentHitpoints( int unitID ): Returns the current hitpoints for this unit ID.
float kbUnitGetCurrentHitpoints( int unitID ):获取此单位当前血量值。
float kbUnitGetHealth( int unitID ): Returns the health for this unit ID.
float kbUnitGetHealth( int unitID ):获取此单位的健康值(可与血量区分或同义)。
float kbUnitGetMaximumAICost( int unitID ): Returns the maximum AI cost (worth) for this unit ID.
float kbUnitGetMaximumAICost( int unitID ):获取此单位在 AI 逻辑下的最大价值。
float kbUnitGetMaximumHitpoints( int unitID ): Returns the maximum hitpoints for this unit ID.
float kbUnitGetMaximumHitpoints( int unitID ):获取此单位的最大血量上限。
int kbUnitGetMovementType( int unitTypeID ): Returns the movementType for this unitTypeID.
int kbUnitGetMovementType( int unitTypeID ):获取此单位类型的移动方式(movementType)。
int kbUnitGetNumberWorkers( int unitID ): Returns the number of units currently working on the given unit.
int kbUnitGetNumberWorkers( int unitID ):返回当前有多少单位在对该单位执行工作(建造/修理等)。
int kbUnitGetPlanID( int unitID ): Returns the plan ID for this unit ID.
int kbUnitGetPlanID( int unitID ):获取此单位所属的计划(plan)ID。
int kbUnitGetPlayerID(int unitID ): Returns the player ID for this unit ID.
int kbUnitGetPlayerID(int unitID ):获取此单位所属的玩家 ID。
vector kbUnitGetPosition( int unitID ): Returns the position for this unit ID.
vector kbUnitGetPosition( int unitID ):获取此单位的坐标位置。
int kbUnitGetProtoUnitID( int unitID ): Returns the unit's protounit ID.
int kbUnitGetProtoUnitID( int unitID ):获取此单位对应的原型单位 ID。
int kbUnitGetTargetUnitID( int unitID ): Returns the target unit ID of the given unit.
int kbUnitGetTargetUnitID( int unitID ):返回此单位当前目标对象的单位 ID。
int kbUnitGetWorkerID( int unitID, int index ): Returns the index-th worker unit ID.
int kbUnitGetWorkerID( int unitID, int index ):返回第 index 个正在对此单位进行工作(如修理、建造等)的单位 ID。
bool kbUnitIsType( int unitID, long unitTypeID ): Returns true if the unit is of the unitTypeID.
bool kbUnitIsType( int unitID, long unitTypeID ):判断该单位是否属于指定单位类型。
bool kbUnitPickAddCombatEfficiencyType( int upID, int typeID, float weight ) : Adds an enemy unit typeID to the unit pick combat efficiency calculation.
bool kbUnitPickAddCombatEfficiencyType( int upID, int typeID, float weight ):在此单位选择(unit pick)中,针对某敌方单位类型添加战斗效率计算条目并设置权重。
bool kbUnitPickAdjustPreferenceFactor( int upID, int unitTypeID, float baseFactorAdjustment ) : Adjusts the preferenceFactor for that unit type (uses 50.0 as the base if the UP doesn't exist yet).
bool kbUnitPickAdjustPreferenceFactor( int upID, int unitTypeID, float baseFactorAdjustment ):针对某单位类型调整其偏好因子(若不存在则以 50.0 为基准)。
int kbUnitPickCreate( string name ): Creates a unit pick.
int kbUnitPickCreate( string name ):创建一条单位选择(unit pick)并返回其 ID。
bool kbUnitPickDestroy( int upID ): Destroys the given unit pick.
bool kbUnitPickDestroy( int upID ):销毁指定的单位选择。
int kbUnitPickGetAttackUnitType( int upID ) : Gets the unit pick attack unit type.
int kbUnitPickGetAttackUnitType( int upID ):获取此单位选择中指定的进攻单位类型。
int kbUnitPickGetDesiredNumberBuildings( int upID, int index ) : gets the unit pick desired number buildings for the index-th unit type.
int kbUnitPickGetDesiredNumberBuildings( int upID, int index ):获取此单位选择在第 index 个单位类型下所期望的建筑数量。
int kbUnitPickGetDesiredNumberUnitTypes( int upID ) : Gets the unit pick desired number unit types.
int kbUnitPickGetDesiredNumberUnitTypes( int upID ):获取此单位选择期望的单位类型数量。
int kbUnitPickGetGoalCombatEfficiencyType( int upID ) : Gets the unit pick attack unit type.
int kbUnitPickGetGoalCombatEfficiencyType( int upID ):获取此单位选择的目标战斗效率单位类型。
int kbUnitPickGetMaximumNumberUnits( int upID ) : Gets the unit pick maximum number units.
int kbUnitPickGetMaximumNumberUnits( int upID ):获取此单位选择中的最大单位数限制。
int kbUnitPickGetMaximumPop( int upID ) : Gets the unit pick maximum pop.
int kbUnitPickGetMaximumPop( int upID ):获取此单位选择允许的最大人口数。
int kbUnitPickGetMinimumNumberUnits( int upID ) : Gets the unit pick minimum number units.
int kbUnitPickGetMinimumNumberUnits( int upID ):获取此单位选择所需的最少单位数。
int kbUnitPickGetMinimumPop( int upID ) : Gets the unit pick minimum pop.
int kbUnitPickGetMinimumPop( int upID ):获取此单位选择允许的最低人口数。
int kbUnitPickGetNumberResults( int upID ) : Returns the number of unit pick results.
int kbUnitPickGetNumberResults( int upID ):返回此单位选择计算后得到的结果数量。
float kbUnitPickGetPreferenceWeight( int upID ) : Gets the unit pick preference weight.
float kbUnitPickGetPreferenceWeight( int upID ):获取此单位选择的偏好权重。
int kbUnitPickGetResult( int upID, int index ) : Returns the index-th ProtoUnitID.
int kbUnitPickGetResult( int upID, int index ):返回此单位选择结果中第 index 个的原型单位 ID。
bool kbUnitPickResetAll( int upID ) : Resets all of the unit pick data.
bool kbUnitPickResetAll( int upID ):重置此单位选择的所有数据。
bool kbUnitPickResetCombatEfficiencyTypes( int upID ) : Resets the enemy unit typeIDs for the unit pick combat efficiency calculation.
bool kbUnitPickResetCombatEfficiencyTypes( int upID ):重置此单位选择在战斗效率计算时所使用的敌方单位类型列表。
bool kbUnitPickResetResults( int upID ) : Resets the unit pick results.
bool kbUnitPickResetResults( int upID ):重置此单位选择已生成的结果。
int kbUnitPickRun( int upID ) : Runs the unit pick.
int kbUnitPickRun( int upID ):执行此单位选择计算并返回完成后的结果。
bool kbUnitPickSetAttackUnitType( int upID, int type ) : Sets the unit pick attack unit type.
bool kbUnitPickSetAttackUnitType( int upID, int type ):为此单位选择设置进攻单位类型。
bool kbUnitPickSetCombatEfficiencyWeight( int upID ) : Sets the unit pick combat efficiency weight.
bool kbUnitPickSetCombatEfficiencyWeight( int upID ):为此单位选择启用战斗效率权重评估。
bool kbUnitPickSetCostWeight( int upID ) : Sets the unit pick cost weight.
bool kbUnitPickSetCostWeight( int upID ):启用基于费用的权重评估。
bool kbUnitPickSetDesiredNumberBuildings( int upID, int index, int numberBuildings ) : Sets the unit pick desired number buildings for the index-th unit type.
bool kbUnitPickSetDesiredNumberBuildings( int upID, int index, int numberBuildings ):为此单位选择的第 index 个单位类型设置期望的建筑数量。
bool kbUnitPickSetDesiredNumberUnitTypes( int upID, int number, int numberBuildings, bool degradeNumberBuildings ) : Sets the unit pick desired number unit types.
bool kbUnitPickSetDesiredNumberUnitTypes( int upID, int number, int numberBuildings, bool degradeNumberBuildings ):设置此单位选择期望的单位类型数量、对应建筑数量,并可选择是否递减建筑数量。
bool kbUnitPickSetEnemyPlayerID( int upID, int playerID ) : Sets the unit pick enemy player ID.
bool kbUnitPickSetEnemyPlayerID( int upID, int playerID ):为此单位选择指定目标敌对玩家 ID。
bool kbUnitPickSetGoalCombatEfficiencyType( int upID, int type ) : Sets the unit pick attack unit type.
bool kbUnitPickSetGoalCombatEfficiencyType( int upID, int type ):为此单位选择指定目标的战斗效率单位类型。
bool kbUnitPickSetMaximumNumberUnits( int upID, int number ) : Sets the unit pick desired number unit types.
bool kbUnitPickSetMaximumNumberUnits( int upID, int number ):设置此单位选择的最大可使用单位数量。
bool kbUnitPickSetMaximumPop( int upID, int number ) : Sets the unit pick desired max pop.
bool kbUnitPickSetMaximumPop( int upID, int number ):为此单位选择设置所允许的最大人口数。
bool kbUnitPickSetMinimumNumberUnits( int upID, int number ) : Sets the unit pick desired number unit types.
bool kbUnitPickSetMinimumNumberUnits( int upID, int number ):设置此单位选择的最少可使用单位数。
bool kbUnitPickSetMinimumPop( int upID, int number ) : Sets the unit pick desired min pop.
bool kbUnitPickSetMinimumPop( int upID, int number ):为此单位选择设置所需的最小人口数。
bool kbUnitPickSetMovementType( int upID, int movementType ) : Sets the unit pick movement type.
bool kbUnitPickSetMovementType( int upID, int movementType ):为此单位选择指定单位的移动类型。
bool kbUnitPickSetPreferenceFactor( int upID, int unitTypeID, float preferenceFactor ) : Sets the preferenceFactor for that unit type.
bool kbUnitPickSetPreferenceFactor( int upID, int unitTypeID, float preferenceFactor ):设置该单位类型的偏好因子数值。
bool kbUnitPickSetPreferenceWeight( int upID, float v ) : Sets the unit pick preference weight.
bool kbUnitPickSetPreferenceWeight( int upID, float v ):设置此单位选择的偏好加权系数。
int kbUnitQueryCreate( string name ): Creates a unit query, returns the query ID.
int kbUnitQueryCreate( string name ):创建一个单位查询,并返回该查询的 ID。
bool kbUnitQueryDestroy( long queryID ): Destroys the given unit query.
bool kbUnitQueryDestroy( long queryID ):销毁指定的单位查询。
int kbUnitQueryExecute( long queryID ): Executes the current query; returns number of results.
int kbUnitQueryExecute( long queryID ):执行当前查询,并返回结果数量。
int kbUnitQueryExecuteOnQuery( long currentQueryID, int previousQueryID ): Executes the current query on the previous query's results; returns the new number of results.
int kbUnitQueryExecuteOnQuery( long currentQueryID, int previousQueryID ):在先前查询结果上执行当前查询,并返回新的结果数量。
int kbUnitQueryExecuteOnQueryByName( long currentQueryID, string previousQueryName ): Executes the current query on the previous query's results; returns the new number of results.
int kbUnitQueryExecuteOnQueryByName( long currentQueryID, string previousQueryName ):在以名称标识的先前查询结果上执行当前查询,并返回新的结果数量。
int kbUnitQueryGetResult( long queryID, int index ): Returns the UnitID of the index-th result in the current query.
int kbUnitQueryGetResult( long queryID, int index ):返回当前查询中第 index 个结果对应的单位 ID。
float kbUnitQueryGetUnitCost( int queryID, bool considerHealth ): Gets total AI cost of query's units, weighted for HP if requested.
float kbUnitQueryGetUnitCost( int queryID, bool considerHealth ):获取当前查询中所有单位的 AI 价值总和,可按血量加权计算。
float kbUnitQueryGetUnitHitpoints( int queryID, bool considerHealth ): Gets HP of query's units, using current HP if requested.
float kbUnitQueryGetUnitHitpoints( int queryID, bool considerHealth ):获取当前查询中单位的血量,若 considerHealth 为 true,则使用当前血量计算。
int kbUnitQueryNumberResults( long queryID ): Returns the number of results in the current query.
int kbUnitQueryNumberResults( long queryID ):返回当前查询的结果数量。
bool kbUnitQueryResetData( long queryID ): Resets the given unit query data AND results.
bool kbUnitQueryResetData( long queryID ):重置指定单位查询的所有数据和结果。
bool kbUnitQueryResetResults( long queryID ): Resets the given unit query results.
bool kbUnitQueryResetResults( long queryID ):重置指定单位查询的结果。
bool kbUnitQuerySetActionType( long queryID, int actionTypeID ): Sets query data.
bool kbUnitQuerySetActionType( long queryID, int actionTypeID ):设置查询的数据——动作类型。
bool kbUnitQuerySetAreaGroupID( long queryID, int areaGroupID ): Sets query data.
bool kbUnitQuerySetAreaGroupID( long queryID, int areaGroupID ):设置查询的数据——区域组 ID。
bool kbUnitQuerySetAreaID( long queryID, int areaID ): Sets query data.
bool kbUnitQuerySetAreaID( long queryID, int areaID ):设置查询的数据——区域 ID。
bool kbUnitQuerySetArmyID( long queryID, int armyID ): Sets query data.
bool kbUnitQuerySetArmyID( long queryID, int armyID ):设置查询的数据——军队 ID。
bool kbUnitQuerySetAscendingSort( long queryID, bool v ): If parm is true, results are sorted in ascending distance order from the query position.
bool kbUnitQuerySetAscendingSort( long queryID, bool v ):若参数 v 为 true,则查询结果按照与查询位置的距离升序排列。
bool kbUnitQuerySetBaseID( long queryID, int baseID ): Sets query data.
bool kbUnitQuerySetBaseID( long queryID, int baseID ):设置查询的数据——基地 ID。
bool kbUnitQuerySetIgnoreKnockedOutUnits( long queryID, bool v ): Sets query data.
bool kbUnitQuerySetIgnoreKnockedOutUnits( long queryID, bool v ):设置查询的数据——是否忽略被击倒的单位。
bool kbUnitQuerySetMaximumDistance( long queryID, float distance ): Sets query data.
bool kbUnitQuerySetMaximumDistance( long queryID, float distance ):设置查询的数据——最大距离限制。
bool kbUnitQuerySetPlayerID( long queryID, int playerID, bool resetQueryData ): Sets query data.
bool kbUnitQuerySetPlayerID( long queryID, int playerID, bool resetQueryData ):设置查询的数据——玩家 ID,并可选择重置查询数据。
bool kbUnitQuerySetPlayerRelation( long queryID, int playerRelation ): Sets query data.
bool kbUnitQuerySetPlayerRelation( long queryID, int playerRelation ):设置查询的数据——玩家关系。
bool kbUnitQuerySetPosition( long queryID, vector v ): Sets query data.
bool kbUnitQuerySetPosition( long queryID, vector v ):设置查询的数据——查询位置向量。
bool kbUnitQuerySetSeeableOnly( long queryID, bool seeableOnly ): Sets query data.
bool kbUnitQuerySetSeeableOnly( long queryID, bool seeableOnly ):设置查询的数据——是否仅考虑可见单位。
bool kbUnitQuerySetState( long queryID, int state ): Sets query data.
bool kbUnitQuerySetState( long queryID, int state ):设置查询的数据——单位状态。
bool kbUnitQuerySetUnitType( long queryID, int unitTypeID ): Sets query data.
bool kbUnitQuerySetUnitType( long queryID, int unitTypeID ):设置查询的数据——单位类型 ID。
bool kbUnitVisible( int unitID ): Returns true if the unit is currently visible to the player.
bool kbUnitVisible( int unitID ):若该单位当前对玩家可见,则返回 true。
int kbVPSiteGetLocation( int siteID ): Returns the specified VP site's world location.
int kbVPSiteGetLocation( int siteID ):返回指定 VP 站点在世界中的位置(坐标)。
int kbVPSiteGetOwnerPlayerID( int siteID ): Returns the specified VP site's owning player.
int kbVPSiteGetOwnerPlayerID( int siteID ):返回指定 VP 站点所属玩家的 ID。
int kbVPSiteGetState( int siteID ): Returns the specified VP site's state.
int kbVPSiteGetState( int siteID ):返回指定 VP 站点的状态。
int kbVPSiteGetType( int siteID ): Returns the specified VP site's type (e.g., native, trade, etc).
int kbVPSiteGetType( int siteID ):返回指定 VP 站点的类型(例如:原住民、贸易等)。
int kbVPSiteQuery( int scoreType, int playerRelationOrID, int siteState ): Returns ID for an array containing VP site IDs that match the specified parameters.
int kbVPSiteQuery( int scoreType, int playerRelationOrID, int siteState ):根据指定的分数类型、玩家关系或 ID 以及站点状态,返回一个包含符合条件的 VP 站点 ID 的数组的 ID。