Table of Contents

Class ModifyTextureMap

Namespace
AlphaFramework.Editor.World.Commands
Assembly
AlphaFramework.Editor.dll

Modifies texture-map data in a ITerrain.

public class ModifyTextureMap : PreExecutedCommand, IUndoCommand
Inheritance
ModifyTextureMap
Implements
Inherited Members
Extension Methods

Constructors

ModifyTextureMap(ITerrain, Point, byte[,], byte[,], Action)

Creates a new command for modifying a rectangular area of the texture-map in a ITerrain.

public ModifyTextureMap(ITerrain terrain, Point offset, byte[,] oldPartialData, byte[,] newPartialData, Action refreshHandler)

Parameters

terrain ITerrain

The ITerrain to modify.

offset Point

The top-left coordinates of the area to modify.

oldPartialData byte[,]

The texture-map data of the area before it was modified. Do not modify this array after calling this method!

newPartialData byte[,]

The texture-map data of the area after it was modified. Do not modify this array after calling this method!

refreshHandler Action

Called when the Terrain needs to be reset.

Methods

OnRedo()

Applies the AlphaFramework.Editor.World.Commands.ModifyTextureMap._newPartialData to TextureMap.

protected override void OnRedo()

OnUndo()

Applies the AlphaFramework.Editor.World.Commands.ModifyTextureMap._oldPartialData to TextureMap.

protected override void OnUndo()