mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-10 23:25:41 +12:00
add %GIVE HORSE
This commit is contained in:
parent
bb458bfd7c
commit
084cf658d2
1 changed files with 24 additions and 0 deletions
|
@ -59,6 +59,30 @@ namespace HISP.Game.Chat
|
|||
return false;
|
||||
}
|
||||
}
|
||||
if (args[0].ToUpper() == "HORSE")
|
||||
{
|
||||
int horseId = 0;
|
||||
try
|
||||
{
|
||||
horseId = int.Parse(args[1]);
|
||||
HorseInstance horse = new HorseInstance(HorseInfo.GetBreedById(horseId));
|
||||
|
||||
if (args.Length >= 3)
|
||||
{
|
||||
findNamePartial(args[2]).HorseInventory.AddHorse(horse);
|
||||
}
|
||||
else
|
||||
{
|
||||
user.HorseInventory.AddHorse(horse);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else if (args[0].ToUpper() == "MONEY")
|
||||
{
|
||||
int money = 0;
|
||||
|
|
Loading…
Add table
Reference in a new issue