Iomega0318

Member
ServUO Version
Publish 57
Ultima Expansion
Endless Journey
So I have creatures in the NoLevelCreatures list and they're still getting levels attached to them and I can't figure out why. Has anyone else messed with this before? Things like Mercenaries don't need to be more powerful haha.. am I just missing a bool somewhere, if so I can't find it?
 
So I have creatures in the NoLevelCreatures list and they're still getting levels attached to them and I can't figure out why. Has anyone else messed with this before? Things like Mercenaries don't need to be more powerful haha.. am I just missing a bool somewhere, if so I can't find it?
it looks like it's only checking for the mobile name, try renaming a merc to the same name as the class name and see if that stops it
C#:
public static void CheckLevel(Mobile defender, BaseCreature attacker, int count)
        {
            bool nolevel = false;
            Type typ = attacker.GetType();
            string nam = attacker.Name;

            foreach (string check in FSATS.NoLevelCreatures)
            {
                if (check == nam)
                    nolevel = true;
            }

            if (nolevel != false)
                return;

suggested fix is in BaseCreature.OnBeforeDeath

change this
C#:
foreach (var bc in toCheck)
                    PetLeveling.CheckLevel(this, bc, toCheck.Count);

to this
C#:
foreach (var bc in toCheck)
                {   
                    if(this is EvoMerc)
                        continue;
                        
                    PetLeveling.CheckLevel(this, bc, toCheck.Count);
                }
 
Why OnBeforeDeath? Also you'd have to do this for each creature in the list would you not? I tried renaming one and it still gave him levels.

C#:
        //Add all creatures you do not wish to level / breed
        public static string[] NoLevelCreatures = new string[]
        {
            "Golem",
            "CoMWarHorse",
            "MinaxWarHorse",
            "SLWarHorse",
            "TBWarHorse",
            "FactionWarHorse",
            "BBC",
            "BaseBioCreature",
            "BioCreature",
            "BaseEvo",
            "DaemonEvo",
            "DragonEvo",
            "GolemEvo",
            "HiryuEvo",
            "LionEvo",
            "MareEvo",
            "Mercenary",
            "RatEvo",
            "ChiefEvo",
            "WispEvo",
            "BeetleEvo",
            "ChargerOfTheFallenEvo",
            "CuSidheEvo",
            "DesertOstardEvo",
            "ForestOstardEvo",
            "FrenziedOstardEvo",
            "HellSteedEvo",
            "KirinEvo",
            "LlamaEvo",
            "PolarBearEvo",
            "RidgebackEvo",
            "SavageRidgebackEvo",
            "ScaledSwampDragonEvo",
            "SteedEvo",
            "SwampDragonEvo",
            "UnicornEvo"
        };
 
So an update on this, also I found where it is adding the menu in BaseCreature.cs and it looks like it is correct in how it pulls the list is it not? If so why is the no level list not being pulled..
C#:
            #region FS:ATS Edits
            if (this is BaseBioCreature || this is BioCreature || this is BioMount)
            {
            }
            else if (from.Alive && this.Alive && this.Controlled == true && this.Summoned == false && FSATS.EnablePetLeveling == true)
            {
                bool nolevel = false;
                Type typ = this.GetType();
                string nam = typ.Name;

                foreach ( string check in FSATS.NoLevelCreatures )
                {
                      if ( check == nam )
                            nolevel = true;
                }

                if ( nolevel != true )
                    list.Add( new ContextMenus.PetMenu( from, this ) );
            }
            #endregion


Even tried this.. still not working..
C#:
                if (this is Mercenary)
                    nolevel = true;

Everything I can find looks correct but they are still getting and gaining levels.
 
Last edited:

Active Shards

Donations

Total amount
$0.00
Goal
$1,000.00
Back