C# Class Aura.Channel.Skills.Life.Campfire

Inheritance: ISkillHandler, IPreparable, IReadyable, IUseable, ICompletable, ICancelable
Exibir arquivo Open project: aura-project/aura

Public Methods

Method Description
Cancel ( Creature creature, Skill skill ) : void

Canceles skill (no special actions required)

Complete ( Creature creature, Skill skill, Packet packet ) : void

Completes skill, placing the campfire.

GetNearbyCampfire ( Creature creature, int range ) : Prop

Returns a campfire in range of creature, or null if there is none.

IsValidPosition ( Creature creature, Position pos ) : bool

Returns true if a campfire can be built at the given position.

IsValidRegion ( Region region ) : bool

Returns true if a campfire can be built at the given position.

Prepare ( Creature creature, Skill skill, Packet packet ) : bool

Prepares skill (effectively does nothing)

Ready ( Creature creature, Skill skill, Packet packet ) : bool

Readies skill, saving the item id to use for later.

Use ( Creature creature, Skill skill, Packet packet ) : void

Uses skill, checking if the campfire can be built at the given position.

Private Methods

Method Description
GetDuration ( SkillRank rank, int regionId ) : int

Returns duration for rank in minutes.

GetPropId ( Item item ) : int

Gets the prop ID

Method Details

Cancel() public method

Canceles skill (no special actions required)
public Cancel ( Creature creature, Skill skill ) : void
creature Aura.Channel.World.Entities.Creature
skill Skill
return void

Complete() public method

Completes skill, placing the campfire.
public Complete ( Creature creature, Skill skill, Packet packet ) : void
creature Aura.Channel.World.Entities.Creature
skill Skill
packet Packet
return void

GetNearbyCampfire() public static method

Returns a campfire in range of creature, or null if there is none.
public static GetNearbyCampfire ( Creature creature, int range ) : Prop
creature Aura.Channel.World.Entities.Creature
range int
return Aura.Channel.World.Entities.Prop

IsValidPosition() public static method

Returns true if a campfire can be built at the given position.
public static IsValidPosition ( Creature creature, Position pos ) : bool
creature Aura.Channel.World.Entities.Creature
pos Aura.Channel.World.Position
return bool

IsValidRegion() public static method

Returns true if a campfire can be built at the given position.
public static IsValidRegion ( Region region ) : bool
region Aura.Channel.World.Region
return bool

Prepare() public method

Prepares skill (effectively does nothing)
public Prepare ( Creature creature, Skill skill, Packet packet ) : bool
creature Aura.Channel.World.Entities.Creature
skill Skill
packet Packet
return bool

Ready() public method

Readies skill, saving the item id to use for later.
public Ready ( Creature creature, Skill skill, Packet packet ) : bool
creature Aura.Channel.World.Entities.Creature
skill Skill
packet Packet
return bool

Use() public method

Uses skill, checking if the campfire can be built at the given position.
public Use ( Creature creature, Skill skill, Packet packet ) : void
creature Aura.Channel.World.Entities.Creature
skill Skill
packet Packet
return void