| scardoc;World |
| Functions |
| Marker_CleanUpTheDead( PlayerID player, MarkerID marker ) | |
|
清除标记半径内指定玩家的尸体(输入ALL清除所有)。【功能:清理标记范围内的死亡单位】 |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2187) | |
| Vector_Length( Position pos ) | |
|
计算所提供向量的长度。【功能:向量长度计算】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (440) | |
| Vector_Lerp( Real factor, Position pos1, Position pos2 ) | |
|
根据所提供的因子在两个向量之间进行线性插值。【功能:向量线性插值】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (446) | |
| Vector_Normalize( Position pos ) | |
|
返回所提供向量的归一化版本。【功能:向量归一化】 Returns a vector pointing the same direction as the provided vector, but shortened/elongated to a length of 1. Don't pass in a vector of length 0, or you'll get a divide-by-zero error! |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (434) | |
| World_CalculateEntitiesAveragePositionInArea( PlayerID player, Position pos, Real radius, OwnerType ownerType, Boolean onlyEntitiesInSquads ) | |
|
返回区域内实体的平均位置。【功能:计算区域内实体平均位置】 Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral It filters out entities not belonging to a squad, when onlyEntitiesInSquads is true |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1449) | |
| World_ChangeZoneInteractivity( Integer targetInteractivity, Integer adjustedInteractivity ) | |
|
将目标交互区域更改为调整后的交互性(最大255),可能仅在NIS(非交互序列)后使用才安全。【功能:修改区域交互性】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1722) | |
| World_CleanUpTheDead( PlayerID player ) | |
|
清除指定玩家的尸体(输入ALL清除所有)。【功能:全局清理死亡单位】 |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2162) | |
| World_DestroyWallsNearMarker( MarkerID marker ) | |
|
摧毁标记附近的墙壁(带有wall_ext组件的实体)。【功能:摧毁标记附近的城墙】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1729) | |
| World_DistanceEGroupToPoint( EGroupID egroup, Position p1, Boolean closest ) | |
|
获取实体组与点之间的距离。【功能:计算实体组到点的距离】 Pass in true for 3rd parameter to get the closest point and pass in false to get the furthest point. The closest/furthest point is calculated on a per entity basis. So the closest distance would be that of the closest entity.\n Also note, it is an error to call this function with an empty group.\n |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (187) | |
| World_DistancePointToPoint( Position p1, Position p2 ) | |
|
获取两点之间的距离。【功能:计算两点间距离】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (171) | |
| World_DistanceSGroupToPoint( SGroupID sgroup, Position p1, Boolean closest ) | |
|
获取小队组与点之间的距离。【功能:计算小队组到点的距离】 Pass in true for 3rd parameter to get the closest point and pass in false to get the furthest point. The closest/furthest point is calculated on a per squadron basis. So the closest distance would be that of the closest squadron.\n It is an error to call this function with an empty group. Check the group size with SquadGroup_Count( ) first. |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (234) | |
| World_DistanceSquaredPointToPoint( Position p1, Position p2 ) | |
|
获取两点之间距离的平方。【功能:计算两点间距离的平方值】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (177) | |
| World_EnableReplacementObjectForEmptyPlayers( Boolean enable ) | |
|
确定空玩家是否转换为空资源点。【功能:设置空玩家资源点转换】 *** You must call this from OnGameSetup, otherwise it's too late *** see Attribute Editor under tuning/player/empty_player_replacement_object |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1780) | |
| World_EnableSharedLineOfSight( PlayerID p0, PlayerID p1, Boolean enableSharedVision ) | |
|
启用或禁用这两个玩家之间的共享视野。【功能:设置玩家间共享视野】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (757) | |
| World_GetAllEntities( EGroupID egroup ) | |
|
清空实体组,然后查找并将所有实体添加到其中。【功能:获取所有实体】 Returns the number of entities found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1197) | |
| World_GetAllEntitiesOfType( EGroupID egroup, String type ) | |
|
清空实体组,然后查找并将指定类型的所有实体添加到其中。【功能:获取指定类型的所有实体】 Returns the number of entities found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1216) | |
| World_GetAllNeutralEntities( EGroupID egroup ) | |
|
清空实体组,然后查找并将所有中立实体添加到其中。【功能:获取所有中立实体】 Returns the number of entities found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1252) | |
| World_GetAllNeutralSquads( SGroupID sgroup ) | |
|
清空小队组,然后查找并将所有中立小队添加到其中。【功能:获取所有中立小队】 Returns the number of squads found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1276) | |
| World_GetAllSquads( SGroupID sgroup ) | |
|
清空小队组,然后查找并将所有小队添加到其中。【功能:获取所有小队】 Returns the number of squads found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1301) | |
| World_GetAllSquadsOfType( SGroupID sgroup, String type ) | |
|
清空小队组,然后查找并将指定类型的所有小队添加到其中。【功能:获取指定类型的所有小队】 Returns the number of squads found |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1321) | |
| World_GetBlueprintEntities( ScarEntityPBG pbg, EGroupID outEntities ) | |
|
返回具有此蓝图的所有实体。警告:此函数遍历所有实体,因此速度较慢。【功能:获取指定蓝图的所有实体】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (551) | |
| World_GetClosest( Variable var, EGroupID items ) | |
|
从标记/位置/实体组/小队组的表中返回距离指定标记/位置/实体组/小队组最近的对象。【功能:获取最近的对象】 The table may mix together objects of different types. |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2063) | |
| World_GetCoverPoints( EGroupID group ) | |
|
将所有掩体点追加到实体组。【功能:获取所有掩体点】 Takes an egroup where you want to put the points. If this 'group' already contains a cover point, this cover point will not be added a second time. This function does not clear the contents of 'group'.\n |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (660) | |
| World_GetEntitiesNearMarker( PlayerID player, EGroupID egroup, MarkerID marker, OwnerType ownerType ) | |
|
清空实体组,然后查找并将标记附近的实体添加到实体组。【功能:获取标记附近的实体】 Returns the number of entities found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1405) | |
| World_GetEntitiesNearPoint( PlayerID player, EGroupID egroup, Position pos, Real radius, OwnerType ownerType ) | |
|
清空实体组,然后查找并将点附近的实体添加到实体组。【功能:获取点附近的实体】 Returns the number of entities found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1047) | |
| World_GetEntitiesWithinTerritorySector( PlayerID player, EGroupID egroup, Integer inSectorID, OwnerType ownerType ) | |
|
清空实体组,然后查找并将领土区域内的实体添加到实体组。【功能:获取领土区域内的实体】 Returns the number of entities found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1596) | |
| World_GetFurthest( Variable var, LuaTable items ) | |
|
从标记/位置/实体组/小队组的表中返回距离指定标记/位置/实体组/小队组最远的对象。【功能:获取最远的对象】 The table may mix together objects of different types. |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2115) | |
| World_GetGameTicks( ) | |
|
返回已流逝的游戏(模拟)时钟周期总数。【功能:获取游戏时钟周期数】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (97) | |
| World_GetGameTime( ) | |
|
返回总游戏时间(秒)。【功能:获取游戏总时长】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (103) | |
| World_GetHeightAt( Real x, Real y ) | |
|
返回2D坐标x,y处的地面高度。【功能:获取地面高度】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (409) | |
| World_GetInteractionStageAtPoint( Position position ) | |
|
返回所提供位置的单元格交互阶段。【功能:获取位置交互阶段】 Returns a value between 0 - 63 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (426) | |
| World_GetLength( ) | |
|
返回游戏世界的总可玩长度(z坐标)。【功能:获取地图可玩长度】 Since the center of the map is 0,0 the world z range is (-l/2 -> l/2) |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (403) | |
| World_GetMetadataBiomePBGName( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的生物群系PBG名称。【功能:获取生物群系名称】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1876) | |
| World_GetMetadataLayerBoolean( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的布尔值。【功能:获取地形布尔元数据】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1806) | |
| World_GetMetadataLayerInteger( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的整数值。【功能:获取地形整数元数据】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1820) | |
| World_GetMetadataLayerNumber( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的数值。【功能:获取地形数值元数据】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1834) | |
| World_GetMetadataLayerPBG( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的PBG。【功能:获取地形PBG元数据】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1862) | |
| World_GetMetadataLayerString( String layerName, Real x, Real y ) | |
|
获取指定地形元数据层和指定坐标的字符串。【功能:获取地形字符串元数据】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1848) | |
| World_GetNearestInteractablePoint( Position position ) | |
|
返回距离所提供位置最近的交互位置。【功能:获取最近交互点】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (415) | |
| World_GetNeutralEntitiesNearMarker( EGroupID egroup, MarkerID marker ) | |
|
查找并将标记附近的中立实体添加到实体组。【功能:获取标记附近的中立实体】 Returns the number of entities found Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1436) | |
| World_GetNeutralEntitiesNearPoint( EGroupID egroup, Position pos, Real radius ) | |
|
查找并将点附近的中立实体添加到实体组。【功能:获取点附近的中立实体】 Returns the number of entities found Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1084) | |
| World_GetNeutralEntitiesWithinTerritorySector( EGroupID egroup, Integer sectorID ) | |
|
查找并将领土区域内的中立实体添加到实体组。【功能:获取领土区域内的中立实体】 Returns the number of entities found Entities belonging to a squad would not be added to the egroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1672) | |
| World_GetNumEntitiesNearPoint( ScarEntityPBG ebp, Position pos, Real radius ) | |
|
返回球体体积内相同实体蓝图(ebp)的实体数量。【功能:统计球体内实体数量】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (925) | |
| World_GetNumStrategicPoints( ) | |
|
返回此地图上的战略点数量(不包括战略目标)。【功能:获取地图战略点数量】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (581) | |
| World_GetOffsetPosition( Position position, Position heading, Integer offset, Real distance ) | |
|
返回从传入的位置/朝向偏移一定距离的位置。有关'offset'参数的说明,请参阅ScarUtil.scar。【功能:获取偏移位置】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (277) | |
| World_GetOffsetPositionRelativeToFacingTarget( Position position, Position facingTarget, Real offset ) | |
|
相对于朝向目标偏移输入位置。【功能:获取相对朝向的偏移位置】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (308) | |
| World_GetOffsetVectorPosition( Position position, Position heading, Position offset ) | |
|
返回从输入位置偏移的位置,偏移量由所提供方向旋转偏移向量得到。【功能:获取向量偏移位置】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (294) | |
| World_GetPlayerAt( Integer index ) | |
|
返回给定索引处的玩家,索引从1开始。【功能:获取指定索引的玩家】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (125) | |
| World_GetPlayerCount( ) | |
|
返回世界中的玩家总数。【功能:获取玩家总数】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (109) | |
| World_GetPlayerIndex( PlayerID player ) | |
|
根据玩家指针(Player*)返回玩家索引。【功能:获取玩家索引】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (148) | |
| World_GetPossibleSquadsBlueprint( ScarRacePBG racePBG, Integer index ) | |
|
返回种族所选小队的蓝图。【功能:获取种族可用小队蓝图】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (535) | |
| World_GetPossibleSquadsCount( ScarRacePBG racePBG ) | |
|
返回种族可建造的小队类型数量。【功能:获取种族可造小队类型数】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (523) | |
| World_GetRaceBlueprint( String racename ) | |
|
根据名称返回种族的种族索引(来自地图编辑器ME)。【功能:获取种族索引】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (712) | |
| World_GetRand( Integer min, Integer max ) | |
|
返回[min, max]范围内的随机整数。【功能:生成随机整数】 It is recommended you use this instead of luas math.random function |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (352) | |
| World_GetScenarioMaxPlayers( ) | |
|
返回本局比赛的最大玩家数。【功能:获取比赛最大玩家数】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (165) | |
| World_GetSpawnablePosition( Position around, EntityID entity ) | |
|
给定世界中的任意位置,此函数将返回适合生成指定实体的安全位置。【功能:获取可生成位置】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (458) | |
| World_GetSquadsNearMarker( PlayerID player, SGroupID sgroup, MarkerID marker, OwnerType ownerType ) | |
|
清空小队组,然后查找并将标记附近的小队添加到小队组。【功能:获取标记附近的小队】 Returns the number of squads found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral This function is faster if radius is small and/or number of squads to search for is large |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1368) | |
| World_GetSquadsNearPoint( PlayerID player, SGroupID sgroup, Position pos, Real radius, OwnerType ownerType ) | |
|
清空小队组,然后查找并将点附近的小队添加到小队组。【功能:获取点附近的小队】 Returns the number of squads found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral This function is faster if radius is small and/or number of squads to search for is large |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (997) | |
| World_GetSquadsWithinTerritorySector( PlayerID player, SGroupID sgroup, Integer inSectorID, OwnerType ownerType ) | |
|
清空小队组,然后查找并将区域ID标识的领土区域内的小队添加到小队组。【功能:获取领土区域内的小队】 Returns the number of squads found Owner type could be OT_Player, OT_Ally, OT_Enemy or OT_Neutral |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1511) | |
| World_GetStrategyPoints( EGroupID group, Boolean bIncludeVP ) | |
|
将所有战略资源点追加到实体组。【功能:获取所有战略资源点】 takes the egroup where you want to put the points, and 2nd parameter is a bool which indicates if you want to include VPs or not If 'group' already contains an entity from 'grouptoadd' it will not be added.\n This function does not clear the contents of 'group'.\n Example: World_GetStrategyPoints(mypointgroup, true) --puts all the points including vps into mypointgroup |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (608) | |
| World_GetTeamTerritoryGaps( Integer sectorID1, Integer sectorID2, StackVarTable results ) | |
|
返回可连接两块不连续领土的一个或多个区域ID。返回值通过表传递(因为可能存在多种连接领土的方式)- 此表中的每个条目都是一个区域ID表。【功能:获取领土连接缺口】 Currently only finds single gaps - i.e. if two territories are 'almost' connected. |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (811) | |
| World_GetTerrainCellType( Real x, Real y ) | |
|
返回指定坐标处单元格的单元格类型。0=天空,1=陆地,2=水域。【功能:获取地形单元格类型】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1800) | |
| World_GetTerritorySectorID( Position pos ) | |
|
根据位置返回区域ID。【功能:获取领土区域ID】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1678) | |
| World_GetTerritorySectorPosition( Integer inSectorID ) | |
|
返回区域生成点的位置。【功能:获取领土区域生成点位置】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1685) | |
| World_GetWidth( ) | |
|
返回游戏世界的总可玩宽度(x坐标)。【功能:获取地图可玩宽度】 Since the center of the map is 0,0 the world x range is (-w/2 -> w/2) |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (396) | |
| World_IsCurrentInteractionStageActive( Integer stage ) | |
|
返回当前交互阶段是否处于活动状态。【功能:检查交互阶段是否激活】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1698) | |
| World_IsInSupply( PlayerID player, Position pos ) | |
|
如果位置在给定玩家的补给范围内,则返回true。【功能:检查位置是否在补给范围内】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (886) | |
| World_IsMultiplayerGame( ) | |
|
返回此世界的游戏类型是否为多人游戏。【功能:检查是否为多人游戏】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (91) | |
| World_IsPointInPlayerTerritory( PlayerID player, Position position ) | |
|
如果位置属于实体领土的一部分,则返回true。【功能:检查位置是否在玩家领土内】 Note that this does not care if territory is in supply or not |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (913) | |
| World_IsPosOnWalkableWall( Position p ) | |
|
返回位置是否在可行走墙壁上。【功能:检查位置是否在可行走城墙上】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1908) | |
| World_IsReplay( ) | |
|
如果游戏当前处于回放状态,则返回TRUE。【功能:检查是否为回放模式】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (115) | |
| World_IsTerritorySectorOwnedByPlayer( PlayerID player, Integer inSectorID ) | |
|
查找玩家是否拥有此领土区域。【功能:检查领土区域所有权】 Other players on the same team would also have the ownership to the sector |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1494) | |
| World_OwnsEGroup( EGroupID egroup, Boolean all ) | |
|
返回组中是否有任意(ANY)或全部(ALL)实体由世界拥有(即中立)。【功能:检查实体组所有权归属】 |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2149) | |
| World_OwnsEntity( EntityID entity ) | |
|
如果实体由世界拥有,则返回true。【功能:检查实体是否为中立】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (339) | |
| World_OwnsSGroup( SGroupID sgroup, Boolean all ) | |
|
返回组中是否有任意(ANY)或全部(ALL)小队由世界拥有(即中立)。【功能:检查小队组所有权归属】 |
|
| Source: [E:\P4Share\engine\assets\engine\scar\scarutil.scar] (2136) | |
| World_OwnsSquad( SquadID squad ) | |
|
如果小队由世界拥有,则返回true。【功能:检查小队是否为中立】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (345) | |
| World_PointPointProx( Position p1, Position p2, Real prox ) | |
|
如果两个世界位置彼此接近,则返回true。【功能:检查两点是否邻近】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (792) | |
| World_Pos( Real x, Real y, Real z ) | |
|
创建一个新的位置对象。【功能:创建位置对象】 A position object is basically a table with an x, y, and z attribute. You can directly access the individual components in the same way that you would access a field in a table.\n\n Example:\n --* lua script snip\n local pos = World_Pos(2, 0, 0)\n pos.x = pos.x + 1\n print pos.x -- this will print 3\n --* lua script snip\n |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (327) | |
| World_PosInBounds( Position pos ) | |
|
返回给定位置是否在可玩区域内。【功能:检查位置是否在可玩区域内】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (333) | |
| World_Reset( ) | |
|
请勿调用,除非您正在进行自动化测试。【功能:重置世界(仅限自动化测试)】 This resets the world into a state comparable to a fresh scenario start. Used in automated testing to avoid tests being dependent on each other. |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (385) | |
| World_SetAllInteractiveStagesVisibility( Boolean visibilityStatus ) | |
|
解锁所有交互阶段。【功能:解锁所有交互阶段】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1715) | |
| World_SetDesignerSupply( Position point, Boolean bSupply ) | |
|
将世界中的特定区域设置为补给提供者(或取消设置)。【功能:设置区域补给提供者状态】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (902) | |
| World_SetInteractionStage( Integer stage ) | |
|
将当前交互阶段设置为所提供的值,必须>=0。【功能:设置交互阶段】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1704) | |
| World_SetSharedLineOfSightEnabledAndMergeExploredMaps( PlayerID p0, PlayerID p1, Boolean enableSharedVision ) | |
|
启用或禁用这两个玩家之间的共享视野,并在需要时合并已探索地图。【功能:设置共享视野并合并探索地图】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (766) | |
| World_SpawnDemolitionCharge( PlayerID player, Position pos ) | |
|
在指定位置生成爆破炸药,'player'是拥有炸药并可以引爆它们的一方。【功能:生成爆破炸药】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (1359) | |
| World_TeamTerritoryPointsConnected( Integer team_index, Position p1, Position p2 ) | |
|
如果两点在同一领土区域内且由指定的领土团队拥有,则返回true,否则返回false。【功能:检查两点领土连接状态】 |
|
| Source: [E:\P4Share\engine\source\runtime\presentation\public\presentation\lua\lualibs\unsorted\luaworld.cpp] (800) | |