- Kasa of the Raj-in is now blessable with a Clothing Bless Deed
(http://www.uodemise.com/discussion/showthread.php?t=134491) - People who use Hiding skill will be put in peace mode (http://www.uodemise.com/discussion/showthread.php?t=133532) - Various fixes about plantgrowing: --> Seeds no longer have range or LOS checks. --> When clicking on the water button on the plant gump it attempts to find water in your backpack first and if it doesn't it will give you a target instead. --> Changed some old SVN messages that were using strings to use cliloc data instead. (http://www.uodemise.com/discussion/showthread.php?t=119004) - Player vendors will say the name of the buyer (http://www.uodemise.com/discussion/showthread.php?t=118363) - Books in bookshelves are now accessible to be read. They can't be taken away unless by using Stealing Skill (http://www.uodemise.com/discussion/showthread.php?t=120213) - Paragon metal chests now are turnable by using the Interior Decorator (http://www.uodemise.com/discussion/showthread.php?t=133863) - Runebooks can't be picked up if opened (http://www.uodemise.com/discussion/showthread.php?t=133723) - Runebook default location now is displayed as a red dot (http://www.uodemise.com/discussion/showthread.php?t=133914)
This commit is contained in:
parent
5cf819b644
commit
c98aa748b6
16 changed files with 168 additions and 24 deletions
|
|
@ -52,8 +52,14 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
Mobile from = sender.Mobile;
|
||||
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant || !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant )
|
||||
return;
|
||||
|
||||
if ( info.ButtonID == 3 && !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
{
|
||||
from.LocalOverheadMessage( MessageType.Regular, 0x3E9, 500446 ); // That is too far away.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( !m_Plant.IsUsableBy( from ) )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -226,8 +226,14 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
Mobile from = sender.Mobile;
|
||||
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant || !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant )
|
||||
return;
|
||||
|
||||
if ( ( ( info.ButtonID >= 6 && info.ButtonID <= 10 ) || info.ButtonID == 12 ) && !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
{
|
||||
from.LocalOverheadMessage( MessageType.Regular, 0x3E9, 500446 ); // That is too far away.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( !m_Plant.IsUsableBy( from ) )
|
||||
{
|
||||
|
|
@ -286,8 +292,30 @@ namespace Server.Engines.Plants
|
|||
}
|
||||
case 6: // Water
|
||||
{
|
||||
from.Target = new PlantPourTarget( m_Plant );
|
||||
from.SendLocalizedMessage( 1060808, "#" + m_Plant.GetLocalizedPlantStatus().ToString() ); // Target the container you wish to use to water the ~1_val~.
|
||||
Item[] item = from.Backpack.FindItemsByType( typeof( BaseBeverage ) );
|
||||
|
||||
bool foundUsableWater = false;
|
||||
|
||||
if ( item != null && item.Length > 0 )
|
||||
{
|
||||
for ( int i = 0; i < item.Length; ++i )
|
||||
{
|
||||
BaseBeverage beverage = (BaseBeverage)item[i];
|
||||
|
||||
if ( !beverage.IsEmpty && beverage.Pourable && beverage.Content == BeverageType.Water )
|
||||
{
|
||||
foundUsableWater = true;
|
||||
m_Plant.Pour( from, beverage );
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( !foundUsableWater )
|
||||
{
|
||||
from.Target = new PlantPourTarget( m_Plant );
|
||||
from.SendLocalizedMessage( 1060808, "#" + m_Plant.GetLocalizedPlantStatus().ToString() ); // Target the container you wish to use to water the ~1_val~.
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ using Server.Gumps;
|
|||
using Server.Items;
|
||||
using Server.Multis;
|
||||
using Server.ContextMenus;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Engines.Plants
|
||||
{
|
||||
|
|
@ -212,8 +213,10 @@ namespace Server.Engines.Plants
|
|||
return 1060812; // plant
|
||||
else if ( m_PlantStatus >= PlantStatus.Sapling )
|
||||
return 1023305; // sapling
|
||||
else
|
||||
else if ( m_PlantStatus >= PlantStatus.Seed )
|
||||
return 1060810; // seed
|
||||
else
|
||||
return 1026951; // dirt
|
||||
}
|
||||
|
||||
private void Update()
|
||||
|
|
@ -341,6 +344,14 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
if ( m_PlantStatus >= PlantStatus.DecorativePlant )
|
||||
return;
|
||||
|
||||
Point3D loc = this.GetWorldLocation();
|
||||
|
||||
if ( !from.InLOS( loc ) || !from.InRange( loc, 2 ) )
|
||||
{
|
||||
from.LocalOverheadMessage( MessageType.Regular, 0x3E9, 1019045 ); // I can't reach that.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( !IsUsableBy( from ) )
|
||||
{
|
||||
|
|
@ -363,12 +374,7 @@ namespace Server.Engines.Plants
|
|||
}
|
||||
else if ( m_PlantStatus != PlantStatus.BowlOfDirt )
|
||||
{
|
||||
if ( m_PlantStatus >= PlantStatus.Plant )
|
||||
LabelTo( from, "This bowl of dirt already has a plant in it!" );
|
||||
else if ( m_PlantStatus >= PlantStatus.Sapling )
|
||||
LabelTo( from, "This bowl of dirt already has a sapling in it!" );
|
||||
else
|
||||
LabelTo( from, "This bowl of dirt already has a seed in it!" );
|
||||
from.SendLocalizedMessage( 1080389, "#" + GetLocalizedPlantStatus().ToString() ); // This bowl of dirt already has a ~1_val~ in it!
|
||||
}
|
||||
else if ( m_PlantSystem.Water < 2 )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -116,9 +116,15 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
Mobile from = sender.Mobile;
|
||||
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant || m_Plant.PlantStatus == PlantStatus.BowlOfDirt || !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus >= PlantStatus.DecorativePlant || m_Plant.PlantStatus == PlantStatus.BowlOfDirt )
|
||||
return;
|
||||
|
||||
if ( ( info.ButtonID >= 6 && info.ButtonID <= 8 ) && !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
{
|
||||
from.LocalOverheadMessage( MessageType.Regular, 0x3E9, 500446 ); // That is too far away.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( !m_Plant.IsUsableBy( from ) )
|
||||
{
|
||||
m_Plant.LabelTo( from, 1061856 ); // You must have the item in your backpack or locked down in order to use it.
|
||||
|
|
|
|||
|
|
@ -140,9 +140,10 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
private Seed m_Seed;
|
||||
|
||||
public InternalTarget( Seed seed ) : base( 3, false, TargetFlags.None )
|
||||
public InternalTarget( Seed seed ) : base( -1, false, TargetFlags.None )
|
||||
{
|
||||
m_Seed = seed;
|
||||
CheckLOS = false;
|
||||
}
|
||||
|
||||
protected override void OnTarget( Mobile from, object targeted )
|
||||
|
|
|
|||
|
|
@ -41,8 +41,14 @@ namespace Server.Engines.Plants
|
|||
{
|
||||
Mobile from = sender.Mobile;
|
||||
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus != PlantStatus.Stage9 || !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
if ( info.ButtonID == 0 || m_Plant.Deleted || m_Plant.PlantStatus != PlantStatus.Stage9 )
|
||||
return;
|
||||
|
||||
if ( info.ButtonID == 3 && !from.InRange( m_Plant.GetWorldLocation(), 3 ) )
|
||||
{
|
||||
from.LocalOverheadMessage( MessageType.Regular, 0x3E9, 500446 ); // That is too far away.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( !m_Plant.IsUsableBy( from ) )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -56,8 +56,6 @@ namespace Server.Items
|
|||
public override int BasePoisonResistance { get { return 17; } }
|
||||
public override int BaseEnergyResistance { get { return 17; } }
|
||||
|
||||
public override bool CanBeBlessed { get { return false; } }
|
||||
|
||||
public override int InitMinHits { get { return 255; } }
|
||||
public override int InitMaxHits { get { return 255; } }
|
||||
|
||||
|
|
|
|||
|
|
@ -55,6 +55,8 @@ namespace Server.Gumps
|
|||
|
||||
if ( info.ButtonID == 1 )
|
||||
{
|
||||
m_Vendor.Say( from.Name );
|
||||
|
||||
if ( !m_VI.Valid || !m_VI.Item.IsChildOf( m_Vendor.Backpack ) )
|
||||
{
|
||||
m_Vendor.SayTo( from, 503216 ); // You can't buy that.
|
||||
|
|
|
|||
|
|
@ -149,12 +149,11 @@ namespace Server.Gumps
|
|||
AddButton( 135 + (half * 160), 115, 2437, 2438, 2 + (index * 6) + 1, GumpButtonType.Reply, 0 );
|
||||
AddHtmlLocalized( 150 + (half * 160), 115, 100, 18, 1011298, false, false ); // Drop rune
|
||||
|
||||
if ( e != m_Book.Default )
|
||||
{
|
||||
// Set as default button
|
||||
AddButton( 160 + (half * 140), 20, 2361, 2361, 2 + (index * 6) + 2, GumpButtonType.Reply, 0 );
|
||||
AddHtmlLocalized( 175 + (half * 140), 15, 100, 18, 1011300, false, false ); // Set default
|
||||
}
|
||||
// Set as default button
|
||||
int defButtonID = e != m_Book.Default ? 2361 : 2360;
|
||||
|
||||
AddButton( 160 + (half * 140), 20, defButtonID, defButtonID, 2 + (index * 6) + 2, GumpButtonType.Reply, 0 );
|
||||
AddHtmlLocalized( 175 + (half * 140), 15, 100, 18, 1011300, false, false ); // Set default
|
||||
|
||||
if ( Core.AOS )
|
||||
{
|
||||
|
|
@ -239,6 +238,8 @@ namespace Server.Gumps
|
|||
}
|
||||
else
|
||||
{
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
from.SendLocalizedMessage( 502416 ); // That cannot be done while the book is locked down.
|
||||
}
|
||||
}
|
||||
|
|
@ -260,7 +261,10 @@ namespace Server.Gumps
|
|||
Mobile from = state.Mobile;
|
||||
|
||||
if ( m_Book.Deleted || !from.InRange( m_Book.GetWorldLocation(), (Core.ML ? 3 : 1) ) || !Multis.DesignContext.Check( from ) )
|
||||
{
|
||||
m_Book.Openers.Remove( from );
|
||||
return;
|
||||
}
|
||||
|
||||
int buttonID = info.ButtonID;
|
||||
|
||||
|
|
@ -273,6 +277,8 @@ namespace Server.Gumps
|
|||
}
|
||||
else
|
||||
{
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
from.SendLocalizedMessage( 502413, null, 0x35 ); // That cannot be done while the book is locked down.
|
||||
}
|
||||
}
|
||||
|
|
@ -311,8 +317,9 @@ namespace Server.Gumps
|
|||
}
|
||||
|
||||
m_Book.OnTravel();
|
||||
|
||||
new RecallSpell( from, m_Book, e, m_Book ).Cast();
|
||||
|
||||
m_Book.Openers.Remove( from );
|
||||
}
|
||||
|
||||
break;
|
||||
|
|
@ -328,6 +335,8 @@ namespace Server.Gumps
|
|||
}
|
||||
else
|
||||
{
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
from.SendLocalizedMessage( 502413, null, 0x35 ); // That cannot be done while the book is locked down.
|
||||
}
|
||||
|
||||
|
|
@ -368,6 +377,8 @@ namespace Server.Gumps
|
|||
{
|
||||
from.SendLocalizedMessage( 500015 ); // You do not have that spell!
|
||||
}
|
||||
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
@ -392,6 +403,8 @@ namespace Server.Gumps
|
|||
{
|
||||
from.SendLocalizedMessage( 500015 ); // You do not have that spell!
|
||||
}
|
||||
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
@ -419,11 +432,15 @@ namespace Server.Gumps
|
|||
from.SendLocalizedMessage( 500015 ); // You do not have that spell!
|
||||
}
|
||||
}
|
||||
|
||||
m_Book.Openers.Remove( from );
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
m_Book.Openers.Remove( from );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,6 +40,14 @@ namespace Server.Items
|
|||
return base.CheckHold( m, item, message, checkItems, plusItems, plusWeight );
|
||||
}
|
||||
|
||||
public override bool CheckItemUse( Mobile from, Item item )
|
||||
{
|
||||
if ( IsDecoContainer && item is BaseBook )
|
||||
return true;
|
||||
|
||||
return base.CheckItemUse( from, item );
|
||||
}
|
||||
|
||||
public override void GetContextMenuEntries( Mobile from, List<ContextMenuEntry> list )
|
||||
{
|
||||
base.GetContextMenuEntries( from, list );
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ using Server.Engines.PartySystem;
|
|||
|
||||
namespace Server.Items
|
||||
{
|
||||
[Flipable]
|
||||
public class ParagonChest : LockableContainer
|
||||
{
|
||||
public override int LabelNumber{ get{ return 3000541; } }
|
||||
|
|
@ -21,7 +22,7 @@ namespace Server.Items
|
|||
private static int[] m_Hues = new int[]
|
||||
{
|
||||
0x0, 0x455, 0x47E, 0x89F, 0x8A5, 0x8AB,
|
||||
0x966, 0x96D, 0x972, 0x973, 0x979,
|
||||
0x966, 0x96D, 0x972, 0x973, 0x979
|
||||
};
|
||||
|
||||
private string m_Name;
|
||||
|
|
@ -76,6 +77,18 @@ namespace Server.Items
|
|||
min = 10; max = 20;
|
||||
}
|
||||
}
|
||||
|
||||
public void Flip()
|
||||
{
|
||||
switch ( ItemID )
|
||||
{
|
||||
case 0x9AB : ItemID = 0xE7C; break;
|
||||
case 0xE7C : ItemID = 0x9AB; break;
|
||||
|
||||
case 0xE40 : ItemID = 0xE41; break;
|
||||
case 0xE41 : ItemID = 0xE40; break;
|
||||
}
|
||||
}
|
||||
|
||||
private void Fill( int level )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ using System.Collections.Generic;
|
|||
using Server;
|
||||
using Server.Gumps;
|
||||
using Server.Network;
|
||||
using Server.Mobiles;
|
||||
using Server.Multis;
|
||||
using Server.Engines.Craft;
|
||||
using Server.ContextMenus;
|
||||
|
|
@ -22,6 +23,8 @@ namespace Server.Items
|
|||
private Mobile m_Crafter;
|
||||
|
||||
private DateTime m_NextUse;
|
||||
|
||||
private List<Mobile> m_Openers = new List<Mobile>();
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public DateTime NextUse
|
||||
|
|
@ -83,6 +86,18 @@ namespace Server.Items
|
|||
m_MaxCharges = value;
|
||||
}
|
||||
}
|
||||
|
||||
public List<Mobile> Openers
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Openers;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Openers = value;
|
||||
}
|
||||
}
|
||||
|
||||
public override int LabelNumber{ get{ return 1041267; } } // runebook
|
||||
|
||||
|
|
@ -264,6 +279,23 @@ namespace Server.Items
|
|||
if ( m_Description != null && m_Description.Length > 0 )
|
||||
list.Add( m_Description );
|
||||
}
|
||||
|
||||
public override bool OnDragLift( Mobile from )
|
||||
{
|
||||
if ( from.HasGump( typeof( RunebookGump ) ) )
|
||||
{
|
||||
from.SendLocalizedMessage( 500169 ); // You cannot pick that up.
|
||||
return false;
|
||||
}
|
||||
|
||||
foreach ( Mobile m in m_Openers )
|
||||
if ( IsOpen( m ) )
|
||||
m.CloseGump( typeof( RunebookGump ) );
|
||||
|
||||
m_Openers.Clear();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public override void OnSingleClick( Mobile from )
|
||||
{
|
||||
|
|
@ -280,6 +312,12 @@ namespace Server.Items
|
|||
{
|
||||
if ( from.InRange( GetWorldLocation(), (Core.ML ? 3 : 1) ) && CheckAccess( from ) )
|
||||
{
|
||||
if ( RootParent is BaseCreature )
|
||||
{
|
||||
from.SendLocalizedMessage( 502402 ); // That is inaccessible.
|
||||
return;
|
||||
}
|
||||
|
||||
if ( DateTime.Now < NextUse )
|
||||
{
|
||||
from.SendLocalizedMessage( 502406 ); // This book needs time to recharge.
|
||||
|
|
@ -288,6 +326,8 @@ namespace Server.Items
|
|||
|
||||
from.CloseGump( typeof( RunebookGump ) );
|
||||
from.SendGump( new RunebookGump( from, this ) );
|
||||
|
||||
m_Openers.Add( from );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -97,6 +97,7 @@ namespace Server.SkillHandlers
|
|||
if ( ok )
|
||||
{
|
||||
m.Hidden = true;
|
||||
m.Warmode = false;
|
||||
m.LocalOverheadMessage( MessageType.Regular, 0x1F4, 501240 ); // You have hidden yourself well.
|
||||
}
|
||||
else
|
||||
|
|
|
|||
|
|
@ -180,6 +180,10 @@ namespace Server.Spells.Chivalry
|
|||
from.Send( new MessageLocalized( from.Serial, from.Body, MessageType.Regular, 0x3B2, 3, 502357, from.Name, "" ) ); // I can not recall from that object.
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnNonlocalTarget( Mobile from, object o )
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnTargetFinish( Mobile from )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -187,6 +187,10 @@ namespace Server.Spells.Fourth
|
|||
from.Send( new MessageLocalized( from.Serial, from.Body, MessageType.Regular, 0x3B2, 3, 502357, from.Name, "" ) ); // I can not recall from that object.
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnNonlocalTarget( Mobile from, object o )
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnTargetFinish( Mobile from )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -238,6 +238,10 @@ namespace Server.Spells.Seventh
|
|||
from.Send( new MessageLocalized( from.Serial, from.Body, MessageType.Regular, 0x3B2, 3, 501030, from.Name, "" ) ); // I can not gate travel from that object.
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnNonlocalTarget( Mobile from, object o )
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnTargetFinish( Mobile from )
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue