Lots of fixes, changes, rewrites of various things, including but not limited to:
Logging of staff crafting items, Fixes for the OSI client changes The potion stacking stuff BaseWeapon fix, so that damage increase things don't multiply themselves. admin gump fixes for Firewall Various display tweaks for weight SoS no longer spawn in Tokuno Hiryu hues happified to OSI standards staff now see alliance chat correctly Play barkeeper text increased per OSI Various other OSI skill requirement changes Various unimplemented features of the SE moves EventSink for when the client version is received from client. Client validation moved out of the core. Client version validation now has options to ignore/kick/warn/annoy. Automagically tries to detect current client. Reverted the delayeddamagecontext back to OSI standards. Can no longer use bags of sending in jail. MagerySpell implemented. Now only Magery spells have a circle, and various other properties of 'em. TransformationSpellHelper now implemented. Things moved around for this. Spells now need a Timespan for the cast delay, instead of arbitrarily based on Circle. Circle doesn't make sense for non-Magery spells! Alot of the spellweaving spells added to OSI standards.
This commit is contained in:
parent
f12e9745c6
commit
2ad37d54aa
214 changed files with 4881 additions and 1243 deletions
|
|
@ -11,10 +11,10 @@ namespace Server.Gumps
|
|||
{
|
||||
public enum ResurrectMessage
|
||||
{
|
||||
ChaosShrine = 0,
|
||||
VirtueShrine = 1,
|
||||
Healer = 2,
|
||||
Generic = 3,
|
||||
ChaosShrine=0,
|
||||
VirtueShrine=1,
|
||||
Healer=2,
|
||||
Generic=3,
|
||||
}
|
||||
|
||||
public class ResurrectGump : Gump
|
||||
|
|
@ -22,28 +22,44 @@ namespace Server.Gumps
|
|||
private Mobile m_Healer;
|
||||
private int m_Price;
|
||||
private bool m_FromSacrifice;
|
||||
private double m_HitsScalar;
|
||||
|
||||
public ResurrectGump( Mobile owner ) : this( owner, owner, ResurrectMessage.Generic, false )
|
||||
public ResurrectGump( Mobile owner )
|
||||
: this( owner, owner, ResurrectMessage.Generic, false )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, bool fromSacrifice ) : this( owner, owner, ResurrectMessage.Generic, fromSacrifice )
|
||||
public ResurrectGump( Mobile owner, double hitsScalar )
|
||||
: this( owner, owner, ResurrectMessage.Generic, false, hitsScalar )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, Mobile healer ) : this( owner, healer, ResurrectMessage.Generic, false )
|
||||
public ResurrectGump( Mobile owner, bool fromSacrifice )
|
||||
: this( owner, owner, ResurrectMessage.Generic, fromSacrifice )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, ResurrectMessage msg ) : this( owner, owner, msg, false )
|
||||
public ResurrectGump( Mobile owner, Mobile healer )
|
||||
: this( owner, healer, ResurrectMessage.Generic, false )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, Mobile healer, ResurrectMessage msg, bool fromSacrifice ) : base( 100, 0 )
|
||||
public ResurrectGump( Mobile owner, ResurrectMessage msg )
|
||||
: this( owner, owner, msg, false )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, Mobile healer, ResurrectMessage msg, bool fromSacrifice )
|
||||
: this( owner, healer, msg, fromSacrifice, 0.0 )
|
||||
{
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, Mobile healer, ResurrectMessage msg, bool fromSacrifice, double hitsScalar )
|
||||
: base( 100, 0 )
|
||||
{
|
||||
m_Healer = healer;
|
||||
|
||||
m_FromSacrifice = fromSacrifice;
|
||||
m_HitsScalar = hitsScalar;
|
||||
|
||||
AddPage( 0 );
|
||||
|
||||
|
|
@ -63,7 +79,8 @@ namespace Server.Gumps
|
|||
AddHtmlLocalized( 100, 230, 110, 35, 1011011, false, false ); // CONTINUE
|
||||
}
|
||||
|
||||
public ResurrectGump( Mobile owner, Mobile healer, int price ) : base( 150, 50 )
|
||||
public ResurrectGump( Mobile owner, Mobile healer, int price )
|
||||
: base( 150, 50 )
|
||||
{
|
||||
m_Healer = healer;
|
||||
m_Price = price;
|
||||
|
|
@ -122,19 +139,19 @@ namespace Server.Gumps
|
|||
{
|
||||
Mobile from = state.Mobile;
|
||||
|
||||
if ( info.ButtonID == 1 || info.ButtonID == 2 )
|
||||
if( info.ButtonID == 1 || info.ButtonID == 2 )
|
||||
{
|
||||
if ( from.Map == null || !from.Map.CanFit( from.Location, 16, false, false ) )
|
||||
if( from.Map == null || !from.Map.CanFit( from.Location, 16, false, false ) )
|
||||
{
|
||||
from.SendLocalizedMessage( 502391 ); // Thou can not be resurrected there!
|
||||
return;
|
||||
}
|
||||
|
||||
if ( m_Price > 0 )
|
||||
if( m_Price > 0 )
|
||||
{
|
||||
if ( info.IsSwitched( 1 ) )
|
||||
if( info.IsSwitched( 1 ) )
|
||||
{
|
||||
if ( Banker.Withdraw( from, m_Price ) )
|
||||
if( Banker.Withdraw( from, m_Price ) )
|
||||
{
|
||||
from.SendLocalizedMessage( 1060398, m_Price.ToString() ); // ~1_AMOUNT~ gold has been withdrawn from your bank box.
|
||||
from.SendLocalizedMessage( 1060022, Banker.GetBalance( from ).ToString() ); // You have ~1_AMOUNT~ gold in cash remaining in your bank box.
|
||||
|
|
@ -157,11 +174,11 @@ namespace Server.Gumps
|
|||
|
||||
from.Resurrect();
|
||||
|
||||
if ( m_Healer != null && from != m_Healer )
|
||||
if( m_Healer != null && from != m_Healer )
|
||||
{
|
||||
VirtueLevel level = VirtueHelper.GetLevel( m_Healer, VirtueName.Compassion );
|
||||
|
||||
switch ( level )
|
||||
switch( level )
|
||||
{
|
||||
case VirtueLevel.Seeker: from.Hits = AOS.Scale( from.HitsMax, 20 ); break;
|
||||
case VirtueLevel.Follower: from.Hits = AOS.Scale( from.HitsMax, 40 ); break;
|
||||
|
|
@ -169,56 +186,60 @@ namespace Server.Gumps
|
|||
}
|
||||
}
|
||||
|
||||
if ( m_FromSacrifice && !from.Criminal && from is PlayerMobile )
|
||||
if( m_FromSacrifice && !from.Criminal && from is PlayerMobile )
|
||||
{
|
||||
((PlayerMobile)from).AvailableResurrects -= 1;
|
||||
|
||||
Container pack = from.Backpack;
|
||||
Container corpse = from.Corpse;
|
||||
|
||||
if ( pack != null && corpse != null )
|
||||
if( pack != null && corpse != null )
|
||||
{
|
||||
List<Item> items = new List<Item>( corpse.Items );
|
||||
|
||||
for ( int i = 0; i < items.Count; ++i )
|
||||
for( int i = 0; i < items.Count; ++i )
|
||||
{
|
||||
Item item = items[i];
|
||||
|
||||
if ( item.Layer != Layer.Hair && item.Layer != Layer.FacialHair && item.Movable )
|
||||
if( item.Layer != Layer.Hair && item.Layer != Layer.FacialHair && item.Movable )
|
||||
pack.DropItem( item );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( from.Fame > 0 )
|
||||
if( from.Fame > 0 )
|
||||
{
|
||||
int amount = from.Fame / 10;
|
||||
|
||||
Misc.Titles.AwardFame( from, -amount, true );
|
||||
}
|
||||
|
||||
if ( !Core.AOS && from.ShortTermMurders >= 5 )
|
||||
if( !Core.AOS && from.ShortTermMurders >= 5 )
|
||||
{
|
||||
double loss = (100.0 - ( 4.0 + (from.ShortTermMurders / 5.0))) / 100.0; // 5 to 15% loss
|
||||
double loss = (100.0 - (4.0 + (from.ShortTermMurders / 5.0))) / 100.0; // 5 to 15% loss
|
||||
|
||||
if ( loss < 0.85 )
|
||||
if( loss < 0.85 )
|
||||
loss = 0.85;
|
||||
else if ( loss > 0.95 )
|
||||
else if( loss > 0.95 )
|
||||
loss = 0.95;
|
||||
|
||||
if ( from.RawStr * loss > 10 )
|
||||
if( from.RawStr * loss > 10 )
|
||||
from.RawStr = (int)(from.RawStr * loss);
|
||||
if ( from.RawInt * loss > 10 )
|
||||
if( from.RawInt * loss > 10 )
|
||||
from.RawInt = (int)(from.RawInt * loss);
|
||||
if ( from.RawDex * loss > 10 )
|
||||
if( from.RawDex * loss > 10 )
|
||||
from.RawDex = (int)(from.RawDex * loss);
|
||||
|
||||
for ( int s = 0; s < from.Skills.Length; s++ )
|
||||
for( int s = 0; s < from.Skills.Length; s++ )
|
||||
{
|
||||
if ( from.Skills[s].Base * loss > 35 )
|
||||
if( from.Skills[s].Base * loss > 35 )
|
||||
from.Skills[s].Base *= loss;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if( from.Alive && m_HitsScalar > 0 )
|
||||
from.Hits = (int)(from.HitsMax * m_HitsScalar);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue