C# Class Sphere.Core.Zone

A Sphere Zone object.
Show file Open project: Radnen/spherestudio Class Usage Examples

Public Methods

Method Description
Clone ( ) : Zone

Creates a perfect copy of this Zone.

Draw ( Graphics map, Point offset, int lighted, int zoom ) : void

Draws the zone to a System.drawing.Graphics.

FromBinary ( BinaryReader reader ) : Zone

Creates a zone from a filestream.

IsMouseWithin ( Point mouse ) : bool

Gets if whather or not the mouse is in a zone.

Save ( BinaryWriter writer ) : void

Stores the zone into a filestream.

Zone ( ) : System.Drawing

Creates a new, blank zone.

Method Details

Clone() public method

Creates a perfect copy of this Zone.
public Clone ( ) : Zone
return Zone

Draw() public method

Draws the zone to a System.drawing.Graphics.
public Draw ( Graphics map, Point offset, int lighted, int zoom ) : void
map System.Drawing.Graphics The System.Drawing.Graphics to use.
offset System.Drawing.Point The x/y offset of the zone.
lighted int The state the zone is in.
zoom int The zoom factor.
return void

FromBinary() public static method

Creates a zone from a filestream.
public static FromBinary ( BinaryReader reader ) : Zone
reader System.IO.BinaryReader The System.IO.BinrayReader to use.
return Zone

IsMouseWithin() public method

Gets if whather or not the mouse is in a zone.
public IsMouseWithin ( Point mouse ) : bool
mouse System.Drawing.Point The System.Drawing.Point of the mouses location.
return bool

Save() public method

Stores the zone into a filestream.
public Save ( BinaryWriter writer ) : void
writer System.IO.BinaryWriter The System.IO.BinaryWriter to use.
return void

Zone() public method

Creates a new, blank zone.
public Zone ( ) : System.Drawing
return System.Drawing