本文整理匯總了C#中WCell.RealmServer.NPCs.NPCEntry.SetResistance方法的典型用法代碼示例。如果您正苦於以下問題:C# NPCEntry.SetResistance方法的具體用法?C# NPCEntry.SetResistance怎麽用?C# NPCEntry.SetResistance使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類WCell.RealmServer.NPCs.NPCEntry
的用法示例。
在下文中一共展示了NPCEntry.SetResistance方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: SetupGrizzly
static void SetupGrizzly()
{
// default settings
GrizzlyBear = new NPCEntry
{
Id = BearId,
DefaultName = "Sample Grizzly",
EntryFlags = NPCEntryFlags.Tamable,
Type = CreatureType.Humanoid,
DisplayIds = new[] { 21635u },
Scale = 1,
MinLevel = 73,
MaxLevel = 74,
HordeFactionId = FactionTemplateId.Monster_2,
MinHealth = 100000,
MaxHealth = 500000,
AttackPower = 314,
AttackTime = 1500,
MinDamage = 250,
MaxDamage = 360,
WalkSpeed = 2.5f,
RunSpeed = 8f,
FlySpeed = 14f,
MinMana = 2000
};
GrizzlyBear.SetResistance(DamageSchool.Physical, 7600);
// AOE damage spell
GrizzlyBear.AddSpell(SpellId.ConeOfFire);
// A spell with a freeze debuff
GrizzlyBear.AddSpell(SpellId.Chilled);
// Sample gossip menu
GossipMgr.AddText(sampleGossipTextId, new GossipText
{
Probability = 1,
TextMale = "Sample Gossip Menu",
TextFemale = "Take a good look"
});
GrizzlyBear.DefaultGossip = CreateSampleGossipMenu();
GrizzlyBear.FinalizeDataHolder();
//NPCMgr.AddEntry(BearId, GrizzlyBear);
}