#W# Can now use static water troughs and water barrels to fill pitchers/cups with water.
This commit is contained in:
parent
50731a5ed5
commit
e6b60a799a
1 changed files with 28 additions and 1 deletions
|
|
@ -794,6 +794,33 @@ namespace Server.Items
|
||||||
from.SendLocalizedMessage( 1080197 ); // You fill the container with milk.
|
from.SendLocalizedMessage( 1080197 ); // You fill the container with milk.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if ( targ is StaticTarget )
|
||||||
|
{
|
||||||
|
StaticTarget stat = (StaticTarget)targ;
|
||||||
|
// Strip the artwork ID down to its base number
|
||||||
|
int itemID = stat.ItemID & 0x3FFF;
|
||||||
|
|
||||||
|
// 0xB41 to 0xB44 are standard water troughs. 0xE7B and 0x154D are water barrels.
|
||||||
|
if ( itemID == 0xB41 || itemID == 0xB42 || itemID == 0xB43 || itemID == 0xB44 || itemID == 0xE7B || itemID == 0x154D || itemID == 0x154D )
|
||||||
|
{
|
||||||
|
if( !from.InRange( stat.Location, 2 ) || !from.InLOS( stat ) )
|
||||||
|
{
|
||||||
|
from.LocalOverheadMessage( MessageType.Regular, 0x3B2, 1019045 ); // I can't reach that.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.Content = BeverageType.Water;
|
||||||
|
this.Poison = null;
|
||||||
|
this.Poisoner = null;
|
||||||
|
this.Quantity = this.MaxQuantity;
|
||||||
|
|
||||||
|
from.SendLocalizedMessage( 1010089 ); // You fill the container with water.
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
from.SendMessage( "You cannot fill the container from that." );
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static int[] m_SwampTiles = new int[]
|
private static int[] m_SwampTiles = new int[]
|
||||||
|
|
@ -1188,4 +1215,4 @@ namespace Server.Items
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue