new command: EstateParcelReclaim
This commit is contained in:
parent
fc7405d0f4
commit
c22190aab6
1 changed files with 32 additions and 0 deletions
32
Core/Commands/Estate/EstateParcelReclaim.cs
Normal file
32
Core/Commands/Estate/EstateParcelReclaim.cs
Normal file
|
|
@ -0,0 +1,32 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Text;
|
||||||
|
using BetterSecondBotShared.logs;
|
||||||
|
using BetterSecondBotShared.Static;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
|
namespace BSB.Commands.Estate
|
||||||
|
{
|
||||||
|
public class EstateParcelReclaim : CoreCommand
|
||||||
|
{
|
||||||
|
public override string Helpfile { get { return "Reclaims ownership of the current parcel"; } }
|
||||||
|
|
||||||
|
public override bool CallFunction(string[] args)
|
||||||
|
{
|
||||||
|
if (base.CallFunction(args) == true)
|
||||||
|
{
|
||||||
|
if (bot.GetClient.Network.CurrentSim.IsEstateManager == true)
|
||||||
|
{
|
||||||
|
int localid = bot.GetClient.Parcels.GetParcelLocalID(bot.GetClient.Network.CurrentSim, bot.GetClient.Self.SimPosition);
|
||||||
|
bot.GetClient.Parcels.Reclaim(bot.GetClient.Network.CurrentSim, localid);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return Failed("Not an estate manager here");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Reference in a new issue