#W# Notoriety tweaks. Hostiles are always red, Peaceful are orange, animals are gray.
This commit is contained in:
parent
97cac07f8b
commit
4a466009a0
2 changed files with 23 additions and 18 deletions
|
|
@ -20,7 +20,7 @@
|
||||||
Kaltivel, Anshu, Maliel, Baratoz, Almonjin
|
Kaltivel, Anshu, Maliel, Baratoz, Almonjin
|
||||||
</namelist>
|
</namelist>
|
||||||
<namelist type="balron">
|
<namelist type="balron">
|
||||||
the Lord of the Abyss, the Collector of Souls, the Slayer
|
the Lord of the Abyss, the Collector of Souls, the Slayer, the Breaker of Bodies, the Bone Splinterer
|
||||||
</namelist>
|
</namelist>
|
||||||
<namelist type="darknight creeper">
|
<namelist type="darknight creeper">
|
||||||
Pariah, Ydoc Llessue, Zhaan, Lorbna, Gragok, Thranger, Krygar,
|
Pariah, Ydoc Llessue, Zhaan, Lorbna, Gragok, Thranger, Krygar,
|
||||||
|
|
@ -651,4 +651,4 @@
|
||||||
Nandrien, Olonal, Peorilien, Regornolas, Rylvarn, Silnaliel, Talendeor, Uomo,
|
Nandrien, Olonal, Peorilien, Regornolas, Rylvarn, Silnaliel, Talendeor, Uomo,
|
||||||
Verlolas
|
Verlolas
|
||||||
</namelist>
|
</namelist>
|
||||||
</names>
|
</names>
|
||||||
|
|
|
||||||
|
|
@ -416,22 +416,27 @@ namespace Server.Misc
|
||||||
return Notoriety.Criminal;
|
return Notoriety.Criminal;
|
||||||
|
|
||||||
// --- CUSTOM: Hostiles are always red. Peaceful mobs are orange ---
|
// --- CUSTOM: Hostiles are always red. Peaceful mobs are orange ---
|
||||||
if ( target is BaseCreature )
|
if ( target is BaseCreature )
|
||||||
{
|
{
|
||||||
BaseCreature bc = (BaseCreature)target;
|
BaseCreature bc = (BaseCreature)target;
|
||||||
|
|
||||||
// If it is wild (not tamed), not a summon, and has negative Karma (hostile)
|
// Protects player pets and summons from changing color
|
||||||
if ( bc.AI != AIType.AI_Animal && !bc.Controlled && !bc.Summoned && bc.Karma < 0 )
|
if ( !bc.Controlled && !bc.Summoned )
|
||||||
{
|
{
|
||||||
return Notoriety.Murderer;
|
// Hostiles: Negative Karma shows as Red
|
||||||
}
|
if ( bc.AI != AIType.AI_Animal && bc.Karma < 0 )
|
||||||
// Defensive/Neutral: Aggressor FightMode or 0 Karma shows as Orange
|
{
|
||||||
if ( !target.Body.IsHuman && bc.AI != AIType.AI_Animal && ( bc.FightMode == FightMode.Aggressor || bc.Karma >= 0 ) )
|
return Notoriety.Murderer;
|
||||||
{
|
}
|
||||||
return Notoriety.Enemy;
|
|
||||||
}
|
// Defensive/Neutral: Aggressor FightMode or >= 0 Karma shows as Orange
|
||||||
}
|
if ( !target.Body.IsHuman && bc.AI != AIType.AI_Animal && ( bc.FightMode == FightMode.Aggressor || bc.Karma >= 0 ) )
|
||||||
// ---------------------------------------------
|
{
|
||||||
|
return Notoriety.Enemy;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// ---------------------------------------------
|
||||||
|
|
||||||
Guild sourceGuild = GetGuildFor( source.Guild as Guild, source );
|
Guild sourceGuild = GetGuildFor( source.Guild as Guild, source );
|
||||||
Guild targetGuild = GetGuildFor( target.Guild as Guild, target );
|
Guild targetGuild = GetGuildFor( target.Guild as Guild, target );
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue