-
Member
Help me! How to eliminate affix labels from rare minions!
I've struggled to remove rare minion's affix labels, but I'm not able to do it yet.
Please instruct me! how to edit or folk scripts in the EliteMonsterAffixPlugin.cs
-
Contributor
Originally Posted by
Asparz
I've struggled to remove rare minion's affix labels, but I'm not able to do it yet.
Please instruct me! how to edit or folk scripts in the EliteMonsterAffixPlugin.cs
This is my own change, but KJ doesn't recommend modifying the default plugin. You should create a new plugin and disable the default plugin.
Code:
public void PaintWorld(WorldLayer layer)
{
var monsters = Hud.Game.AliveMonsters;
foreach (var monster in monsters)
{
bool illusionist = false;
if(monster.SummonerAcdDynamicId == 0)
{
illusionist = false;
}
else
{
illusionist = true;
}
if (monster.Rarity == ActorRarity.Normal || monster.Rarity == ActorRarity.Unique || monster.Rarity == ActorRarity.Boss) {
foreach (var snoMonsterAffix in monster.AffixSnoList)
{
WorldDecoratorCollection decorator;
if (!AffixDecorators.TryGetValue(snoMonsterAffix.Affix, out decorator)) continue;
string affixName = null;
if (CustomAffixNames.ContainsKey(snoMonsterAffix.Affix))
{
affixName = CustomAffixNames[snoMonsterAffix.Affix];
}
else affixName = snoMonsterAffix.NameLocalized;
decorator.Paint(layer, monster, monster.FloorCoordinate, affixName);
}
}
if (monster.Rarity == ActorRarity.Champion)
{
if (illusionist == false)
{
foreach (var snoMonsterAffix in monster.AffixSnoList)
{
WorldDecoratorCollection decorator;
if (!AffixDecorators.TryGetValue(snoMonsterAffix.Affix, out decorator)) continue;
string affixName = null;
if (CustomAffixNames.ContainsKey(snoMonsterAffix.Affix))
{
affixName = CustomAffixNames[snoMonsterAffix.Affix];
}
else affixName = snoMonsterAffix.NameLocalized;
decorator.Paint(layer, monster, monster.FloorCoordinate, affixName);
}
}
}
if (monster.Rarity == ActorRarity.Rare)
{
if (illusionist == false)
{
foreach (var snoMonsterAffix in monster.AffixSnoList)
{
WorldDecoratorCollection decorator;
if (!AffixDecorators.TryGetValue(snoMonsterAffix.Affix, out decorator)) continue;
string affixName = null;
if (CustomAffixNames.ContainsKey(snoMonsterAffix.Affix))
{
affixName = CustomAffixNames[snoMonsterAffix.Affix];
}
else affixName = snoMonsterAffix.NameLocalized;
decorator.Paint(layer, monster, monster.FloorCoordinate, affixName);
}
}
}
}
}
-
Post Thanks / Like - 1 Thanks
Asparz (1 members gave Thanks to SeaDragon for this useful post)
-
Member
Thank you for your help...
but I still don't know how to create a new plugin for using the code that you provided.
I'm sorry. Could you give me information in detail?
p.s. I just want to remove rare minion's affix as modifying the default plugin.
Last edited by Asparz; 04-08-2018 at 04:57 AM.
-
Contributor
GLQ_EliteMonsterAffixPlugin.cs - Pastebin.com
This is the plugin for my own use
It is also a modification from the default plugin
To use it, you need to disable the default plugin first, otherwise they will repeat.
I modified the style of the affix, if you don't like it, you can modify the code yourself.
-
Post Thanks / Like - 1 Thanks
Asparz (1 members gave Thanks to SeaDragon for this useful post)
-
Member
Thank you very much. This is what I wanted.
-
Member
Originally Posted by
SeaDragon
GLQ_EliteMonsterAffixPlugin.cs - Pastebin.com
This is the plugin for my own use
It is also a modification from the default plugin
To use it, you need to disable the default plugin first, otherwise they will repeat.
I modified the style of the affix, if you don't like it, you can modify the code yourself.
How to disable default