C# Class TowerAnimator.ColorPalette

Afficher le fichier Open project: uiacm/tower_creator

Méthodes publiques

Méthode Description
ColorPalette ( int squarePixelWidth, int numColumns ) : System
GetColor ( ) : Color

Gets the color of the currently hovered cell.

GetColor ( int row, int col ) : Color
GetImage ( ) : Image
SetColor ( Color c ) : void

Sets the color of the currently hovered cell.

SetColor ( int row, int col, Color c ) : void
SetHover ( int x, int y ) : void

This function assumes the canvas has not been scaled on screen, or that (x, y) has been appropriately scaled.

UnHover ( ) : void

Private Methods

Méthode Description
GenerateCanvas ( ) : void
GenerateSwatches ( ) : void

Method Details

ColorPalette() public méthode

public ColorPalette ( int squarePixelWidth, int numColumns ) : System
squarePixelWidth int
numColumns int
Résultat System

GetColor() public méthode

Gets the color of the currently hovered cell.
public GetColor ( ) : Color
Résultat Color

GetColor() public méthode

public GetColor ( int row, int col ) : Color
row int
col int
Résultat Color

GetImage() public méthode

public GetImage ( ) : Image
Résultat Image

SetColor() public méthode

Sets the color of the currently hovered cell.
public SetColor ( Color c ) : void
c Color
Résultat void

SetColor() public méthode

public SetColor ( int row, int col, Color c ) : void
row int
col int
c Color
Résultat void

SetHover() public méthode

This function assumes the canvas has not been scaled on screen, or that (x, y) has been appropriately scaled.
public SetHover ( int x, int y ) : void
x int Mouse location x.
y int Mouse location y.
Résultat void

UnHover() public méthode

public UnHover ( ) : void
Résultat void