mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-24 05:35:51 +12:00
Move to islehorse
This commit is contained in:
parent
f74d6a7834
commit
d18338151f
1069 changed files with 53 additions and 10714 deletions
|
@ -1,117 +0,0 @@
|
|||
using HISP.Game;
|
||||
using HISP.Server;
|
||||
using HISP.Game.Items;
|
||||
|
||||
namespace HISP.Player.Equips
|
||||
{
|
||||
public class CompetitionGear
|
||||
{
|
||||
public const int MISC_FLAG_HEAD = 1;
|
||||
public const int MISC_FLAG_BODY = 2;
|
||||
public const int MISC_FLAG_LEGS = 3;
|
||||
public const int MISC_FLAG_FEET = 4;
|
||||
|
||||
private int playerId;
|
||||
public CompetitionGear(int PlayerId)
|
||||
{
|
||||
playerId = PlayerId;
|
||||
if (!Database.HasCompetitionGear(PlayerId))
|
||||
Database.InitCompetitionGear(PlayerId);
|
||||
int itemId = Database.GetCompetitionGearHeadPeice(PlayerId);
|
||||
if (itemId != 0)
|
||||
head = Item.GetItemById(itemId);
|
||||
|
||||
itemId = Database.GetCompetitionGearBodyPeice(PlayerId);
|
||||
if (itemId != 0)
|
||||
body = Item.GetItemById(itemId);
|
||||
|
||||
itemId = Database.GetCompetitionGearLegPeice(PlayerId);
|
||||
if (itemId != 0)
|
||||
legs = Item.GetItemById(itemId);
|
||||
|
||||
itemId = Database.GetCompetitionGearFeetPeice(PlayerId);
|
||||
if (itemId != 0)
|
||||
feet = Item.GetItemById(itemId);
|
||||
|
||||
}
|
||||
public Item.ItemInformation Head
|
||||
{
|
||||
get
|
||||
{
|
||||
return head;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
head = null;
|
||||
Database.SetCompetitionGearHeadPeice(playerId, 0);
|
||||
return;
|
||||
}
|
||||
Database.SetCompetitionGearHeadPeice(playerId, value.Id);
|
||||
head = value;
|
||||
}
|
||||
}
|
||||
public Item.ItemInformation Body
|
||||
{
|
||||
get
|
||||
{
|
||||
return body;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
body = null;
|
||||
Database.SetCompetitionGearBodyPeice(playerId, 0);
|
||||
return;
|
||||
}
|
||||
Database.SetCompetitionGearBodyPeice(playerId, value.Id);
|
||||
body = value;
|
||||
}
|
||||
}
|
||||
public Item.ItemInformation Legs
|
||||
{
|
||||
get
|
||||
{
|
||||
return legs;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
legs = null;
|
||||
Database.SetCompetitionGearLegPeice(playerId, 0);
|
||||
return;
|
||||
}
|
||||
Database.SetCompetitionGearLegPeice(playerId, value.Id);
|
||||
legs = value;
|
||||
}
|
||||
}
|
||||
public Item.ItemInformation Feet
|
||||
{
|
||||
get
|
||||
{
|
||||
return feet;
|
||||
}
|
||||
set
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
feet = null;
|
||||
Database.SetCompetitionGearFeetPeice(playerId, 0);
|
||||
return;
|
||||
}
|
||||
Database.SetCompetitionGearFeetPeice(playerId, value.Id);
|
||||
feet = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private Item.ItemInformation head;
|
||||
private Item.ItemInformation body;
|
||||
private Item.ItemInformation legs;
|
||||
private Item.ItemInformation feet;
|
||||
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue