本文整理汇总了C#中Server.Mobile.CheckTargetSkill方法的典型用法代码示例。如果您正苦于以下问题:C# Mobile.CheckTargetSkill方法的具体用法?C# Mobile.CheckTargetSkill怎么用?C# Mobile.CheckTargetSkill使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server.Mobile
的用法示例。
在下文中一共展示了Mobile.CheckTargetSkill方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnTarget
protected override void OnTarget( Mobile from, object target )
{
if ( target is Mobile )
{
if ( from.CheckTargetSkill( SkillName.Forensics, target, 40.0, 100.0 ) )
{
if ( target is PlayerMobile && ((PlayerMobile)target).NpcGuild == NpcGuild.ThievesGuild )
from.SendLocalizedMessage( 501004 );//That individual is a thief!
else
from.SendLocalizedMessage( 501003 );//You notice nothing unusual.
}
else
{
from.SendLocalizedMessage( 501001 );//You cannot determain anything useful.
}
}
else if ( target is Corpse )
{
if ( from.CheckTargetSkill( SkillName.Forensics, target, 0.0, 100.0 ) )
{
Corpse c = (Corpse)target;
if ( ((Body)c.Amount).IsHuman )
c.LabelTo( from, 1042751, ( c.Killer == null ? "no one" : c.Killer.Name ) );//This person was killed by ~1_KILLER_NAME~
if ( c.Looters.Count > 0 )
{
StringBuilder sb = new StringBuilder();
for (int i=0;i<c.Looters.Count;i++)
{
if ( i>0 )
sb.Append( ", " );
sb.Append( ((Mobile)c.Looters[i]).Name );
}
c.LabelTo( from, 1042752, sb.ToString() );//This body has been distrubed by ~1_PLAYER_NAMES~
}
else
{
c.LabelTo( from, 501002 );//The corpse has not be desecrated.
}
}
else
{
from.SendLocalizedMessage( 501001 );//You cannot determain anything useful.
}
}
else if ( target is ILockpickable )
{
ILockpickable p = (ILockpickable)target;
if ( p.Picker != null )
from.SendLocalizedMessage( 1042749, p.Picker.Name );//This lock was opened by ~1_PICKER_NAME~
else
from.SendLocalizedMessage( 501003 );//You notice nothing unusual.
}
}
示例2: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is BaseWeapon )
((BaseWeapon)o).Attributes.NightSight = 1;
else if ( o is BaseArmor )
((BaseArmor)o).Attributes.NightSight = 1;
else if ( o is BaseJewel )
((BaseJewel)o).Attributes.NightSight = 1;
else if ( o is BaseClothing )
((BaseClothing)o).Attributes.NightSight = 1;
if ( !Core.AOS )
((Item)o).OnSingleClick( from );
from.SendMessage( "You Successfully enhance the Item." );
from.PlaySound( Utility.Random( 0x520, 0 ) );
m_nsOrb.Delete();
}
else
from.SendMessage( "You fail to enhance the item." ); // You cannot augment that...
}
else if ( o is Mobile )
((Mobile)o).OnSingleClick( from );
else
from.SendMessage( "You cannot do that." );
}
示例3: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is BaseWeapon )
((BaseWeapon)o).Identified = true;
else if ( o is BaseArmor )
((BaseArmor)o).Identified = true;
if ( !Core.AOS )
((Item)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
//allows the identify skill to reveal attachments
Server.Engines.XmlSpawner2.XmlAttach.RevealAttachments(from,o);
}
示例4: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is BaseWeapon )
((BaseWeapon)o).Identified = true;
else if ( o is BaseArmor )
((BaseArmor)o).Identified = true;
else if ( o is BaseTreasureChest )
{
BaseTreasureChest tchest = (BaseTreasureChest)o;
from.SendMessage( "{0} container with {1} treasure.", tchest.Locked ? "a locked" : "an unlocked", m_TreasureValue[(int)tchest.Level] );
}
if ( !Core.AOS )
((Item)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
示例5: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( !m_CheckSkill || from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is IIdentifiable )
((IIdentifiable)o).OnIdentify( from );
else if ( o is Spellbook )
from.SendAsciiMessage( "You guess it contains about {0} spells....", Math.Max( 0, ((Spellbook)o).SpellCount + Utility.RandomMinMax( -8, 8 ) ) );
((Item)o).OnSingleClick( from );
if ( m_OK != null )
m_OK( from, o );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
示例6: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is BaseWeapon )
((BaseWeapon)o).Identified = true;
else if ( o is BaseArmor )
((BaseArmor)o).Identified = true;
else if ( o is BaseJewel )
((BaseJewel)o).Identified = true;
if ( !Core.AOS )
((Item)o).OnSingleClick( from );
}
else
{
from.SendAsciiMessage( "You are not certain..." );
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendAsciiMessage( "You are not certain..." );
}
}
示例7: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if ( from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
if ( o is BaseWeapon )
((BaseWeapon)o).Identified = true;
else if ( o is BaseArmor )
((BaseArmor)o).Identified = true;
//ItemID Mods Begin
else if ( o is BaseClothing)
((BaseClothing)o).Identified = true;
else if ( o is BaseJewel)
((BaseJewel)o).Identified = true;
//ItemID Mods End
if ( !Core.AOS )
((Item)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
示例8: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
IEntity entity = targeted as IEntity;
if (XmlScript.HasTrigger(entity, TriggerName.onTargeted) && UberScriptTriggers.Trigger(entity, from, TriggerName.onTargeted, null, null, null, 0, null, SkillName.Anatomy, from.Skills[SkillName.Anatomy].Value))
{
return;
}
if ( from == targeted )
from.LocalOverheadMessage( MessageType.Regular, 0x3B2, 500324 ); // You know yourself quite well enough already.
else if ( targeted is TownCrier )
((TownCrier)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500322, from.NetState ); // This person looks fine to me, though he may have some news...
else if ( targeted is BaseVendor /*&& ((BaseVendor)targeted).IsInvulnerable*/ )
((BaseVendor)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500326, from.NetState ); // That can not be inspected.
else if ( targeted is BaseGuard )
((BaseGuard)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, false, "That person looks strong enough to find criminals and apprehend them.", from.NetState );
else if ( targeted is Mobile )
{
Mobile targ = (Mobile)targeted;
if ( targ.AccessLevel > AccessLevel.Player )
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, false, "That entity is clearly beyond mortal understanding.", from.NetState );
else
{
int marginOfError = Math.Max( 0, 25 - (int)(from.Skills[SkillName.Anatomy].Value / 1) );// 4
int str = targ.Str + Utility.RandomMinMax( -marginOfError, +marginOfError );
int dex = targ.Dex + Utility.RandomMinMax( -marginOfError, +marginOfError );
int stm = ((targ.Stam * 100) / Math.Max( targ.StamMax, 1 )) + Utility.RandomMinMax( -marginOfError, +marginOfError );
int strMod = str / 10;
int dexMod = dex / 10;
int stmMod = stm / 10;
if ( strMod < 0 ) strMod = 0;
else if ( strMod > 10 ) strMod = 10;
if ( dexMod < 0 ) dexMod = 0;
else if ( dexMod > 10 ) dexMod = 10;
if ( stmMod > 10 ) stmMod = 10;
else if ( stmMod < 0 ) stmMod = 0;
if ( from.CheckTargetSkill( SkillName.Anatomy, targ, 0, 100 ) )
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038045 + (strMod * 11) + dexMod, from.NetState ); // That looks [strong] and [dexterous].
if ( from.Skills[SkillName.Anatomy].Base >= 65.0 )
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038303 + stmMod, from.NetState ); // That being is at [10,20,...] percent endurance.
}
else
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1042666, from.NetState ); // You can not quite get a sense of their physical characteristics.
}
}
else if ( targeted is Item )
{
((Item)targeted).SendLocalizedMessageTo( from, 500323, "" ); // Only living things have anatomies!
}
}
示例9: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
if ( from == targeted )
{
from.LocalOverheadMessage( MessageType.Regular, 0x3B2, 500910 ); // Hmm, that person looks really silly.
}
else if ( targeted is TownCrier )
{
((TownCrier)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500907, from.NetState ); // He looks smart enough to remember the news. Ask him about it.
}
else if ( targeted is BaseVendor && ((BaseVendor)targeted).IsInvulnerable )
{
((BaseVendor)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500909, from.NetState ); // That person could probably calculate the cost of what you buy from them.
}
else if ( targeted is Mobile )
{
Mobile targ = (Mobile)targeted;
int marginOfError = Math.Max( 0, 20 - (int)(from.Skills[SkillName.EvalInt].Value / 5) );
int intel = targ.Int + Utility.RandomMinMax( -marginOfError, +marginOfError );
int mana = ((targ.Mana * 100) / Math.Max( targ.ManaMax, 1 )) + Utility.RandomMinMax( -marginOfError, +marginOfError );
int intMod = intel / 10;
int mnMod = mana / 10;
if ( intMod > 10 ) intMod = 10;
else if ( intMod < 0 ) intMod = 0;
if ( mnMod > 10 ) mnMod = 10;
else if ( mnMod < 0 ) mnMod = 0;
int body;
if ( targ.Body.IsHuman )
body = targ.Female ? 11 : 0;
else
body = 22;
if ( from.CheckTargetSkill( SkillName.EvalInt, targ, 0.0, 120.0 ) )
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038169 + intMod + body, from.NetState ); // He/She/It looks [slighly less intelligent than a rock.] [Of Average intellect] [etc...]
if ( from.Skills[SkillName.EvalInt].Base >= 76.0 )
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038202 + mnMod, from.NetState ); // That being is at [10,20,...] percent mental strength.
}
else
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038166 + (body / 11), from.NetState ); // You cannot judge his/her/its mental abilities.
}
}
else if ( targeted is Item )
{
((Item)targeted).SendLocalizedMessageTo( from, 500908, "" ); // It looks smarter than a rock, but dumber than a piece of wood.
}
}
示例10: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Item )
{
if (from.CheckTargetSkill(SkillName.ItemID, o, 0, 100))
{
bool inlist = false;
if (o is BaseWeapon)
inlist = ((BaseWeapon)o).IsInIDList(from);
else if (o is BaseArmor)
inlist = ((BaseArmor)o).IsInIDList(from);
else if (o is BaseClothing)
inlist = ((BaseClothing)o).IsInIDList(from);
else if (o is BaseJewel)
inlist = ((BaseJewel)o).IsInIDList(from);
if (o is BaseWeapon)
((BaseWeapon)o).AddToIDList(from);
else if (o is BaseArmor)
((BaseArmor)o).AddToIDList(from);
else if (o is BaseClothing)
((BaseClothing)o).AddToIDList(from);
else if (o is BaseJewel)
((BaseJewel)o).AddToIDList(from);
if (!Core.AOS)
((Item)o).OnSingleClick(from);
if (o is BaseWeapon && (((BaseWeapon)o).IDList.Count > 50 && !inlist || from.AccessLevel > AccessLevel.Player))
((BaseWeapon)o).RemoveFromIDList(from);
else if (o is BaseArmor && (((BaseArmor)o).IDList.Count > 50 && !inlist || from.AccessLevel > AccessLevel.Player))
((BaseArmor)o).RemoveFromIDList(from);
else if (o is BaseClothing && (((BaseClothing)o).IDList.Count > 50 && !inlist || from.AccessLevel > AccessLevel.Player))
((BaseClothing)o).RemoveFromIDList(from);
else if (o is BaseJewel && (((BaseJewel)o).IDList.Count > 50 && !inlist || from.AccessLevel > AccessLevel.Player))
((BaseJewel)o).RemoveFromIDList(from);
}
else
{
from.SendAsciiMessage("You are not certain...");
//from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
else if ( o is Mobile )
{
((Mobile)o).OnSingleClick( from );
}
else
{
from.SendAsciiMessage("You are not certain...");
//from.SendLocalizedMessage( 500353 ); // You are not certain...
}
}
示例11: OnTarget
protected override void OnTarget( Mobile from, object o )
{
if ( o is Mobile )
{
// It appears to be:
from.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1041349, ( (Mobile) o ).Name, from.Client );
}
else if ( !from.CheckTargetSkill( SkillName.ItemID, o, 0, 100 ) )
{
// You have no idea how much it might be worth.
from.SendLocalizedMessage( 1041352 );
}
else if ( o is Item )
{
Item item = o as Item;
// TODO (SA): Display the value of the item
// TODO (SA): When should we show this message? "You conclude that item cannot be magically unraveled. The magic in that item has been weakened due to either low durability or the imbuing process." (1111877)
if ( item is IImbuable )
{
UnravelInfo info = Unraveling.GetUnravelInfo( from, item );
if ( info == null )
{
// You conclude that item cannot be magically unraveled. It appears to possess little to no magic.
from.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1111876, from.Client );
}
else
{
if ( from.Skills[SkillName.Imbuing].Value >= info.MinSkill )
{
// You conclude that item will magically unravel into: ~1_ingredient~
from.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1111874, String.Format( "#{0}", info.Name.ToString() ), from.Client );
}
else
{
// Your Imbuing skill is not high enough to identify the imbuing ingredient.
from.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1111875, from.Client );
}
}
}
else
{
// You conclude that item cannot be magically unraveled.
from.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1111878, from.Client );
}
}
else
{
// You have no idea how much it might be worth.
from.SendLocalizedMessage( 1041352 );
}
}
示例12: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
if ( from == targeted )
{
from.LocalOverheadMessage( MessageType.Regular, 0x3B2, false, "Vous vous connaissez suffisamment ainsi..." ); // You know yourself quite well enough already.
}
else if ( targeted is TownCrier )
{
((TownCrier)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, false, "Cette personne parait bien portante. Peut-être même a-t-elle des nouvelles pour vous?", from.NetState ); // This person looks fine to me, though he may have some news...
}
else if ( targeted is BaseVendor && ((BaseVendor)targeted).IsInvulnerable )
{
((BaseVendor)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, false, "Cette personne semble trop occupée pour être examinée", from.NetState ); // That can not be inspected.
}
else if ( targeted is Mobile )
{
Mobile targ = (Mobile)targeted;
int marginOfError = Math.Max( 0, 25 - (int)(from.Skills[SkillName.Anatomy].Value / 4) );
int str = targ.Str + Utility.RandomMinMax( -marginOfError, +marginOfError );
int dex = targ.Dex + Utility.RandomMinMax( -marginOfError, +marginOfError );
int stm = ((targ.Stam * 100) / Math.Max( targ.StamMax, 1 )) + Utility.RandomMinMax( -marginOfError, +marginOfError );
int strMod = str / 10;
int dexMod = dex / 10;
int stmMod = stm / 10;
if ( strMod < 0 ) strMod = 0;
else if ( strMod > 10 ) strMod = 10;
if ( dexMod < 0 ) dexMod = 0;
else if ( dexMod > 10 ) dexMod = 10;
if ( stmMod > 10 ) stmMod = 10;
else if ( stmMod < 0 ) stmMod = 0;
if ( from.CheckTargetSkill( SkillName.Anatomy, targ, 0, 100 ) )
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038045 + (strMod * 11) + dexMod, from.NetState ); // That looks [strong] and [dexterous].
if ( from.Skills[SkillName.Anatomy].Base >= 65.0 )
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038303 + stmMod, from.NetState ); // That being is at [10,20,...] percent endurance.
}
else
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, false, "Vous ne parvenez pas poser un diagnostic complet", from.NetState ); // You can not quite get a sense of their physical characteristics.
}
}
else if ( targeted is Item )
{
from.SendMessage( "Seuls les êtres vivants ont une anatomie!"); // Only living things have anatomies!
}
}
示例13: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
if ( !from.Alive )
{
from.SendAsciiMessage("The spirits of the dead are not the province of animal lore.");
//from.SendLocalizedMessage( 500331 ); // The spirits of the dead are not the province of animal lore.
}
else if ( targeted is BaseCreature )
{
BaseCreature c = (BaseCreature)targeted;
if ( !c.IsDeadPet )
{
if ( c.Body.IsAnimal || c.Body.IsMonster || c.Body.IsSea )
{
if ( (!c.Controlled || !c.Tamable) && from.Skills[SkillName.AnimalLore].Base < 100.0 )
{
from.SendAsciiMessage("At your skill level, you can only lore tamed creatures.");
//from.SendLocalizedMessage( 1049674 ); // At your skill level, you can only lore tamed creatures.
}
else if ( !c.Tamable && from.Skills[SkillName.AnimalLore].Base < 110.0 )
{
from.SendAsciiMessage("At your skill level, you can only lore tamed or tameable creatures.");
//from.SendLocalizedMessage( 1049675 ); // At your skill level, you can only lore tamed or tameable creatures.
}
else if ( !from.CheckTargetSkill( SkillName.AnimalLore, c, 0.0, 100.0 ) )
{
from.SendAsciiMessage("You can't think of anything you know offhand.");
//from.SendLocalizedMessage( 500334 ); // You can't think of anything you know offhand.
}
else
{
from.CloseGump( typeof( AnimalLoreGump ) );
from.SendGump( new AnimalLoreGump( c ) );
}
}
else
{
from.SendAsciiMessage("That's not an animal!");
//from.SendLocalizedMessage( 500329 ); // That's not an animal!
}
}
else
{
from.SendAsciiMessage("The spirits of the dead are not the province of animal lore.");
//from.SendLocalizedMessage( 500331 ); // The spirits of the dead are not the province of animal lore.
}
}
else
{
from.SendAsciiMessage("That's not an animal!");
//from.SendLocalizedMessage( 500329 ); // That's not an animal!
}
}
示例14: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
if ( from == targeted )
{
from.LocalOverheadMessage( MessageType.Regular, 0x3B2, 500324 ); // You know yourself quite well enough already.
}
else if ( targeted is TownCrier )
{
((TownCrier)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500322, from.NetState ); // This person looks fine to me, though he may have some news...
}
else if ( targeted is BaseVendor && ((BaseVendor)targeted).IsInvulnerable )
{
((BaseVendor)targeted).PrivateOverheadMessage( MessageType.Regular, 0x3B2, 500326, from.NetState ); // That can not be inspected.
}
else if ( targeted is Mobile )
{
Mobile targ = (Mobile)targeted;
int marginOfError = Math.Max( 0, 25 - (int)(from.Skills[SkillName.Anatomy].Value / 4) );
int str = targ.Str + Utility.RandomMinMax( -marginOfError, +marginOfError );
int dex = targ.Dex + Utility.RandomMinMax( -marginOfError, +marginOfError );
int stm = ((targ.Stam * 100) / Math.Max( targ.StamMax, 1 )) + Utility.RandomMinMax( -marginOfError, +marginOfError );
int strMod = str / 10;
int dexMod = dex / 10;
int stmMod = stm / 10;
if ( strMod < 0 ) strMod = 0;
else if ( strMod > 10 ) strMod = 10;
if ( dexMod < 0 ) dexMod = 0;
else if ( dexMod > 10 ) dexMod = 10;
if ( stmMod > 10 ) stmMod = 10;
else if ( stmMod < 0 ) stmMod = 0;
if ( from.CheckTargetSkill( SkillName.Anatomy, targ, 0, 100 ) )
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038045 + (strMod * 11) + dexMod, from.NetState ); // That looks [strong] and [dexterous].
if ( from.Skills[SkillName.Anatomy].Base >= 65.0 )
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1038303 + stmMod, from.NetState ); // That being is at [10,20,...] percent endurance.
}
else
{
targ.PrivateOverheadMessage( MessageType.Regular, 0x3B2, 1042666, from.NetState ); // You can not quite get a sense of their physical characteristics.
}
}
else if ( targeted is Item )
{
((Item)targeted).SendAsciiMessageTo( from, "Only living things have anatomies!" );
}
}
示例15: CheckSuccess
public override bool CheckSuccess( Mobile from, ILockpickable target )
{
// Skeleton key gives +10.0 virtual bonus to Lockpicking skill
double value = from.Skills[SkillName.Lockpicking].Value + 10.0;
double minSkill = target.LockLevel;
double maxSkill = target.MaxLockLevel;
double chance = ( value - minSkill ) / ( maxSkill - minSkill );
return from.CheckTargetSkill( SkillName.Lockpicking, target, chance );
}