Full Version : Kills/Deaths problem
xmlspawner >>XMLPoint's Troubleshooting >>Kills/Deaths problem


<< Prev | Next >>

ArteGordon- 08-03-2006
good to hear. I think that I must have changed the order of evaluating the OnKill and OnKilled methods in one of the recent xmlspawner updates when I added support for the new OnBeforeKill and OnBeforeKilled methods. Those calls are handled by the base xmlspawner attachment system.

The Jedi- 08-03-2006
Ah, okay. It all makes more sense now. Thanks again Arte.

DreadfullyDespized- 11-13-2007
does it matter if the players are young status or not?...just wondering because no points gained or lost while testing the system with players in young status.

ArteGordon- 11-13-2007
QUOTE (DreadfullyDespized @ November 13, 2007 04:45 am)
does it matter if the players are young status or not?...just wondering because no points gained or lost while testing the system with players in young status.

by default there is young protection for challenges that can be modified in xmlpoints.cs

CODE

       public static bool YoungProtection(Mobile from, Mobile target)
       {
           // newbie protection
           if (((target.SkillsTotal < 6000 && (from.SkillsTotal - target.SkillsTotal) > 1000) ||
               (target.RawStatTotal <= 200 && (from.RawStatTotal - target.RawStatTotal) > 20)))
               return true;

           // dont allow young players to be challenged by experienced players
           // note, this will allow young players to challenge other young players
           if (from is PlayerMobile && target is PlayerMobile)
           {
               if (((PlayerMobile)target).Young && !((PlayerMobile)from).Young)
                   return true;
           }

           return false;

       }


there is also a test that is commented out by default that will block all points for newbie players. If you uncommented that, then it would prevent points from being given for newbie kills.

CODE

       public bool CanAffectPoints(Mobile from, Mobile killer, Mobile killed, bool assumechallenge)
       {
           // uncomment this for newbie protection
           //if( ((killed.SkillsTotal < 6000 && (killer.SkillsTotal - killed.SkillsTotal ) > 1000) ||
           //(killed.RawStatTotal <= 200 && (killer.RawStatTotal - killed.RawStatTotal) > 20 ) ) && m_Challenger != killer && m_Challenger != killed) return false;