a few more fixes.
This commit is contained in:
parent
1f788d60d9
commit
53d92a9e4e
3 changed files with 45 additions and 19 deletions
|
|
@ -17,6 +17,9 @@
|
|||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public virtual int currItemID { get { return ( IsEmpty ) ? voidItem_ID : fullItem_ID; } }
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public virtual bool CanFill { get { return ( !IsFull && !IsLockedDown() ); } }
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public int Quantity
|
||||
{
|
||||
|
|
@ -26,7 +29,7 @@
|
|||
}
|
||||
set
|
||||
{
|
||||
if( value != m_Quantity )
|
||||
if( value != m_Quantity && CanFill )
|
||||
{
|
||||
UpdateContainer( value );
|
||||
|
||||
|
|
@ -43,6 +46,20 @@
|
|||
m_Quantity = ( filled ) ? MaxQuantity : 0;
|
||||
}
|
||||
|
||||
public virtual bool IsLockedDown()
|
||||
{
|
||||
Multis.BaseHouse house = Multis.BaseHouse.FindHouseAt( this );
|
||||
|
||||
if( house == null || !house.IsLockedDown( this ) )
|
||||
{
|
||||
if( Parent == null )
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnDoubleClick( Mobile from )
|
||||
{
|
||||
if( IsEmpty )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue