SceneEditorRegionPlaceholderEdit
Package: Libraries.Interface.Undo · Inherits from: Libraries.Language.Object, Libraries.Interface.Undo.Edit
The SceneEditorRegionPlaceholderEdit is one step with the placeholder of the Add region and Remove region tools, in the scene editor's undo list: placing it, moving or resizing it, dropping it, or committing it. It keeps the placeholder's rectangle before and after the step, where there may be no placeholder. A commit also keeps the terrain stroke that added or removed the regions, so undoing a commit takes the regions back out, or puts them back, and brings the placeholder back so it can be changed and committed again. If the terrain no longer has a region tool chosen, undo and redo only change the ground; the placeholder is left alone.
Actions
CanRedo()
Returns
boolean
CanUndo()
Sets up the edit with what the step does and the terrain stroke of a commit, or undefined for a step that only changes the placeholder.
Returns
boolean
Create(Libraries.Interface.Controls.Scenes.SceneEditor controller, Libraries.Interface.Controls.Scenes.Items.EditorTerrain terrain, text name, Libraries.Game.Graphics.Worlds.TerrainStrokeEdit strokeEdit)
Sets up the edit with what the step does and the terrain stroke of a commit, or undefined for a step that only changes the placeholder.
Parameters
controllerLibraries.Interface.Controls.Scenes.SceneEditor: The scene editorterrainLibraries.Interface.Controls.Scenes.Items.EditorTerrain: The terrain the placeholder is onnametext: What the step does, such as "resize region placeholder", for the undo namestrokeEditLibraries.Game.Graphics.Worlds.TerrainStrokeEdit: The commit's terrain stroke, or undefined
Dispose()
GetRedoName()
Returns
text
GetUndoName()
Returns
text
Redo()
Sets the placeholder before the step.
SetAfter(boolean shown, integer firstX, integer firstZ, integer lastX, integer lastZ)
Sets the placeholder after the step.
Parameters
shownboolean: True if there is a placeholderfirstXinteger: Its first region location along xfirstZinteger: Its first region location along zlastXinteger: Its last region location along xlastZinteger: Its last region location along z
SetBefore(boolean shown, integer firstX, integer firstZ, integer lastX, integer lastZ)
Sets the placeholder before the step.
Parameters
shownboolean: True if there was a placeholderfirstXinteger: Its first region location along xfirstZinteger: Its first region location along zlastXinteger: Its last region location along xlastZinteger: Its last region location along z
Undo()
Sets the placeholder after the step.