12sealed
class WorldEditorAPI
14 private void WorldEditorAPI();
15 private void ~WorldEditorAPI();
18 proto external
bool BeginEntityAction(
string historyPointName =
string.Empty,
string historyPointIcon =
string.Empty,
void userData =
NULL);
20 proto external
bool EndEntityAction(
string historyPointName =
string.Empty);
21 proto external
bool IsDoingEditAction();
27 proto external
bool IsEditSequenceActive(
IEntitySource entSrc);
29 proto external
bool UndoOrRedoIsRestoring();
31 proto external
bool IsCreatingEntityInWindow();
32 proto external
bool IsModifyingData();
34 proto external
bool IsPrefabEditMode();
40 proto external
int GetEditorEntityCount();
43 proto external
int GetEntityCount(
int subScene);
46 proto external
bool HasCopiedEntities();
48 proto external
bool CopySelectedEntities();
50 proto external
bool PasteEntities();
52 proto external
bool PasteEntitiesAtMouseCursorPos();
54 proto external
bool DuplicateSelectedEntities();
56 proto external
bool CutSelectedEntities();
59 proto external
bool RemoveEntityFromParent(notnull
IEntitySource child);
62 proto external
int GetSelectedEntitiesCount();
64 proto external
void ClearEntitySelection();
65 proto external
void RemoveFromEntitySelection(notnull
IEntitySource ent);
66 proto external
void SetPropertySelection(
string id);
67 proto external
void UpdateSelectionGui();
68 proto external
bool CreateEntityTemplate(
IEntitySource entitySrc,
string templateFileAbs);
72 proto external
bool RenameEntity(notnull
IEntitySource ent,
string newName);
73 proto external
int GetCurrentSubScene();
74 proto external
int GetNumSubScenes();
76 proto external
int GetScreenWidth();
78 proto external
int GetScreenHeight();
83 proto external
int GetMousePosX(
bool clamped);
88 proto external
int GetMousePosY(
bool clamped);
90 proto external
void ToggleGeneratorEvents(
bool isEnabled);
91 proto external
bool AreGeneratorEventsEnabled();
132 proto external
bool BeginTerrainAction(
TerrainToolType toolType,
string historyPointName =
string.Empty,
string historyPointIcon =
string.Empty);
133 proto external
void EndTerrainAction(
string historyPointName =
string.Empty);
135 proto external
float GetTerrainSurfaceY(
float x,
float z);
155 proto external
bool GetTerrainSurfaceTile(
int terrainIndex,
int tileX,
int tileY, out notnull array<float> surfaceY);
176 proto external
bool SetTerrainSurfaceTile(
int terrainIndex,
int tileX,
int tileY, notnull array<float> surfaceY);
178 proto external
int GetTerrainResolutionX(
int terrainIndex = 0);
180 proto external
int GetTerrainResolutionY(
int terrainIndex = 0);
182 proto external
int GetTerrainTilesX(
int terrainIndex = 0);
184 proto external
int GetTerrainTilesY(
int terrainIndex = 0);
186 proto external
float GetTerrainUnitScale(
int terrainIndex = 0);
188 proto external
void RemoveTerrainFlatterEntity(
IEntity entity,
bool bUpdateTerrain =
true);
189 proto external
void RemoveCommentEntity(
IEntity entity);
191 proto external
void RegenerateFlowMaps(
bool preview =
true,
bool save =
true,
bool asyncReturn =
true,
bool noWarning =
false);
196 proto external
void SetEntityVisible(
IEntitySource entity,
bool isVisible,
bool recursive);
200 proto external
bool IsEntitySelectedAsMain(
IEntitySource entity);
201 proto external
bool IsEditMode();
202 proto external
bool IsGameMode();
205 proto external
void AddTerrainFlatterEntity(
IEntity entity,
vector mins,
vector maxs,
int iPriority,
float fFalloffStart,
float fFalloff,
bool bForceUpdate =
true, array<vector> updateMins = null, array<vector> updateMaxes = null);
206 proto external
void AddCommentEntity(
IEntity entity,
string comment,
Color commentColor =
Color.White);
208 proto external
bool TryGetTerrainSurfaceY(
float x,
float z, out
float y);
209 proto external
void AddToEntitySelection(notnull
IEntitySource ent);
210 proto external
void SetEntitySelection(notnull
IEntitySource ent);
211 [
Obsolete(
"Use SetVariableValue instead!")]
212 proto external
bool ModifyEntityKey(notnull
IEntitySource ent,
string key,
string value);
213 [
Obsolete(
"Use SetVariableValue instead!")]
214 proto external
bool ModifyComponentKey(notnull
IEntitySource ent,
string componentName,
string key,
string value);
220 proto external
IEntitySource CreateEntityInWindowEx(
int windowType,
int winX,
int winY,
string className,
string name,
int layerID);
222 proto external
bool ParentEntities(notnull
IEntitySource parent, notnull array<IEntitySource> childs,
bool transformChildToParentSpace);
224 proto external
bool DeleteEntities(notnull array<IEntitySource> ents);
227 proto external
void GetWorldPath(out
string path);
228 proto external
string GetEntityNiceName(
IEntitySource entSrc);
230 proto external
string GenerateDefaultEntityName(
IEntitySource entSrc);
252 proto external
bool SetVariableValue(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string key,
string value);
260 proto external
bool ClearVariableValue(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string key);
269 proto external
bool CreateObjectVariableMember(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string key,
string baseClassName);
279 proto external
bool CreateObjectArrayVariableMember(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string key,
string baseClassName,
int memberIndex);
288 proto external
bool RemoveObjectArrayVariableMember(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string key,
int memberIndex);
289 proto external
bool ChangeObjectClass(notnull
BaseContainer topLevel, array<ref ContainerIdPathEntry> containerIdPath,
string baseClassName);
300 proto external
int ShowItemListDialog(
string title,
string message,
int width,
int height, notnull array<string> items, notnull out array<int> selectedItems,
int currentItem);
302 proto external
bool AddPrefabMembers(
IEntitySource prefabMember, notnull array<IEntitySource> members);
303 proto external
bool RemovePrefabMembers(notnull array<IEntitySource> members);
311 proto external
bool MoveEntitiesToPrefab(
IEntitySource newParentInMap,
IEntitySource newParentInPrefab, notnull array<IEntitySource> entitiesInMap,
bool convertTransformations =
true);
312 proto external
string GetCurrentToolName();
314 proto external
string CreateSubsceneLayer(
int subScene,
string name,
string parentPath =
string.Empty);
315 proto external
string CreateSubsceneFolder(
int subScene,
string name,
string parentPath =
string.Empty);
316 proto external
bool RenameSubsceneFolder(
int subScene,
string itemPath,
string newItemName);
317 proto external
bool DeleteSubsceneFolder(
int subScene,
string itemPath);
318 proto external
bool SetSubsceneFolderParent(
int subScene,
string itemPath,
string parentPath);
319 proto external
void GetSubsceneFolders(
int subscene, out notnull array<string> outItemPaths);
320 proto external
bool SetEntitySubsceneLayer(
int subScene,
IEntitySource pEntitySource,
string itemPath);
321 proto external
string GetEntitySubsceneLayer(
int subScene,
IEntitySource pEntitySource);
322 proto external
string GetActiveSubsceneLayer(
int subScene);
323 proto external
void SetActiveSubsceneLayer(
int subScene,
string layerPath);
324 proto external
int GetSubsceneLayerId(
int subscene,
string layerPath);
325 proto external
string GetSubsceneLayerPath(
int subscene,
int layerId);
326 proto external
bool IsSubsceneLayerVisible(
int subscene,
string layerPath);
327 proto external
bool IsEntityLayerVisible(
int subscene,
int layerId);
329 proto external
bool IsEntityLayerLocked(
int subscene,
int layerId);
331 proto external
bool IsEntityLayerLockedHierarchy(
int subscene,
int layerId);
332 proto external
void LockEntityLayer(
int subscene,
int layerId);
333 proto external
void UnlockEntityLayer(
int subscene,
int layerId);
334 proto external
int GetCurrentEntityLayerId();