1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Custom Loyalty - Kill - Death - & Rank system removal?

Discussion in 'Windows Support' started by WarFace, Nov 28, 2013.

  1. WarFace
    Offline

    WarFace Member

    Joined:
    Nov 25, 2013
    Messages:
    27
    Likes Received:
    5
    ai1328.photobucket.com_albums_w535_Robertbrownmo_title_zpsd77de3a9.jpg

    How would i go about removing this rank, kill, death, & loyalty rep system from players names. Thanks for all those who devote there time to servuo you guys are just great people.
     
  2. cmileto
    Online

    cmileto Member

    Joined:
    Nov 18, 2013
    Messages:
    173
    Likes Received:
    7
    I think you can remove it by commenting this in playermobile.cs (not sure if this has other effects though....)
    Code (C#):
    1.  /*#region QueensLoyaltySystem            // Queens Loyalty System
    2.  
    3.             if (m_Exp >= m_LevelExp)
    4.             {
    5.                 while (m_Exp >= m_LevelExp)
    6.                 {
    7.                     m_Exp -= m_LevelExp;
    8.                     m_Level += 1;
    9.                     m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level)));
    10.                 }
    11.             }
    12.  
    13.             if (m_Exp < 0)
    14.             {
    15.                 while (m_Exp < 0)
    16.                 {
    17.                     if (m_Level == 0) m_Exp = 0;
    18.                     else
    19.                     {
    20.                         m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level - 1)));
    21.                         m_Exp += (long)(m_LevelExp);
    22.                         m_Level -= 1;
    23.                     }
    24.                 }
    25.         }
    26.  
    27.             m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level)));
    28.  
    29.             if (AccessLevel == AccessLevel.Player || AccessLevel == AccessLevel.Counselor)
    30.             {
    31.                 if (m_Level == 0) m_ExpTitle = "TerMur-guest";
    32.                 else if (m_Level >= 1 && m_Level <= 5) m_ExpTitle = "Friend of TerMur";
    33.                 else if (m_Level >= 6 && m_Level <= 10) m_ExpTitle = "Friend of TerMur";
    34.                 else if (m_Level >= 11 && m_Level <= 15) m_ExpTitle = "Friend of TerMur";
    35.                 else if (m_Level >= 16 && m_Level <= 20) m_ExpTitle = "Friend of TerMur";
    36.                 else if (m_Level >= 21 && m_Level <= 25) m_ExpTitle = "Friend of TerMur";
    37.                 else if (m_Level >= 26 && m_Level <= 30) m_ExpTitle = "A Citizen of TerMur";
    38.                 else if (m_Level >= 31 && m_Level <= 35) m_ExpTitle = "A Citizen of TerMur";
    39.                 else if (m_Level >= 36 && m_Level <= 40) m_ExpTitle = "A Citizen of TerMur";
    40.                 else if (m_Level >= 41 && m_Level <= 45) m_ExpTitle = "A Citizen of TerMur";
    41.                 else if (m_Level >= 46 && m_Level <= 50) m_ExpTitle = "A Citizen of TerMur";
    42.                 else if (m_Level >= 51 && m_Level <= 60) m_ExpTitle = "A Citizen of TerMur";
    43.                 else if (m_Level >= 61 && m_Level <= 70) m_ExpTitle = "A Noble of Termur";
    44.                 else if (m_Level >= 71 && m_Level <= 80) m_ExpTitle = "A Noble of Termur";
    45.                 else if (m_Level >= 80 && m_Level <= 100) m_ExpTitle = "A Noble of Termur";
    46.                 else if (m_Level >= 101) m_ExpTitle = "A Noble of Termur";
    47.             }
    48.             else
    49.             {
    50.                 m_ExpTitle = "Staff: ";
    51.                 if (AccessLevel == AccessLevel.GameMaster) m_ExpTitle += "GameMaster";
    52.                 else if (AccessLevel == AccessLevel.Seer) m_ExpTitle += "Seer";
    53.                 else if (AccessLevel == AccessLevel.Administrator) m_ExpTitle += "Administrator";
    54.                 else if (AccessLevel == AccessLevel.Developer) m_ExpTitle += "Developer";
    55.                 else if (AccessLevel == AccessLevel.Owner) m_ExpTitle += "Owner";
    56.             }
    57.  
    58.             list.Add(String.Concat("Queens Loyalty Level: ", String.Format("<BASEFONT COLOR={0}>{1}", "#FF0000", m_Level), "  ", String.Format("<BASEFONT COLOR={0}>{1}", "#000FFF", (int)(100 * m_Exp / m_LevelExp)), " %  ", String.Format("<BASEFONT COLOR={0}>{1}", "#0FFF00", m_ExpTitle))); InvalidateMyRunUO();
    59.             #endregion*/
     
  3. WarFace
    Offline

    WarFace Member

    Joined:
    Nov 25, 2013
    Messages:
    27
    Likes Received:
    5
    Yes thank you it did have some errors i had to bypass but got though them, your playersmobile.cs file is way diffrent then mine hmm.

    the things i had to do & this is for future server owners that want to fix this problem do this

    On line 4109: jot out this
    Code (C#):
    1. else if (IsPlayer())
    2. {
    3. //list.Add(1070722, "Kills {0} / Deaths {1} : Rank={2}", a.Kills, a.Deaths, a.Rank);
    4. }
    5. }
    then on line 4196 - 4310
    Code (C#):
    1. if (IsPlayer())
    2. {
    3. //#region QueensLoyaltySystem
    4. //if (m_Exp >= m_LevelExp)
    5. //{
    6. // while (m_Exp >= m_LevelExp)
    7. // {
    8. // m_Exp -= m_LevelExp;
    9. // m_Level += 1;
    10. // m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level)));
    11. // }
    12. //}
    13. //
    14. //if (m_Exp < 0)
    15. //{
    16. // while (m_Exp < 0)
    17. // {
    18. // if (m_Level == 0)
    19. // {
    20. // m_Exp = 0;
    21. // }
    22. // else
    23. // {
    24. // m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level - 1)));
    25. // m_Exp += (m_LevelExp);
    26. // m_Level -= 1;
    27. // }
    28. // }
    29. //}
    30. //
    31. //m_LevelExp = (long)(1000 * (Math.Pow(1.4, m_Level)));
    32. //if (m_Level == 0)
    33. //{
    34. // m_ExpTitle = "TerMur-guest";
    35. //}
    36. //else if (m_Level >= 1 && m_Level <= 5)
    37. //{
    38. // m_ExpTitle = "Friend of TerMur";
    39. //}
    40. //else if (m_Level >= 6 && m_Level <= 10)
    41. //{
    42. // m_ExpTitle = "Friend of TerMur";
    43. //}
    44. //else if (m_Level >= 11 && m_Level <= 15)
    45. //{
    46. // m_ExpTitle = "Friend of TerMur";
    47. //}
    48. //else if (m_Level >= 16 && m_Level <= 20)
    49. //{
    50. // m_ExpTitle = "Friend of TerMur";
    51. //}
    52. //else if (m_Level >= 21 && m_Level <= 25)
    53. //{
    54. // m_ExpTitle = "Friend of TerMur";
    55. //}
    56. //else if (m_Level >= 26 && m_Level <= 30)
    57. //{
    58. // m_ExpTitle = "A Citizen of TerMur";
    59. //}
    60. //else if (m_Level >= 31 && m_Level <= 35)
    61. //{
    62. // m_ExpTitle = "A Citizen of TerMur";
    63. //}
    64. //else if (m_Level >= 36 && m_Level <= 40)
    65. //{
    66. // m_ExpTitle = "A Citizen of TerMur";
    67. //}
    68. //else if (m_Level >= 41 && m_Level <= 45)
    69. //{
    70. // m_ExpTitle = "A Citizen of TerMur";
    71. //}
    72. //else if (m_Level >= 46 && m_Level <= 50)
    73. //{
    74. // m_ExpTitle = "A Citizen of TerMur";
    75. //}
    76. //else if (m_Level >= 51 && m_Level <= 60)
    77. //{
    78. // m_ExpTitle = "A Citizen of TerMur";
    79. //}
    80. //else if (m_Level >= 61 && m_Level <= 70)
    81. //{
    82. // m_ExpTitle = "A Noble of Termur";
    83. //}
    84. //else if (m_Level >= 71 && m_Level <= 80)
    85. //{
    86. // m_ExpTitle = "A Noble of Termur";
    87. //}
    88. //else if (m_Level >= 80 && m_Level <= 100)
    89. //{
    90. // m_ExpTitle = "A Noble of Termur";
    91. //}
    92. //else if (m_Level >= 101)
    93. //{
    94. // m_ExpTitle = "A Noble of Termur";
    95. //}
    96.  
    97.  
    98.  
    99.  
    100. // Xml spawner 3.26c QueensLoyaltyTitle
    101. //XmlData QueenTitle = (XmlData)XmlAttach.FindAttachment(this, typeof(XmlData), "QueenTitle");
    102. //
    103. //if (QueenTitle != null && QueenTitle.Data == "True")
    104. //{
    105. // return;
    106. //}
    107. //else
    108. //{
    109. // list.Add(
    110. // String.Concat(
    111. // "Queens Loyalty Level: ",
    112. // String.Format("<BASEFONT COLOR={0}>{1}", "#FF0000", m_Level),
    113. // "  ",
    114. // String.Format("<BASEFONT COLOR={0}>{1}", "#000FFF", (int)(100 * m_Exp / m_LevelExp)),
    115. // " %  ",
    116. // String.Format("<BASEFONT COLOR={0}>{1}", "#0FFF00", m_ExpTitle)));
    117. // InvalidateMyRunUO();
    118. //}
    119. // Xml Spawner 3.26c QueensLoyaltyTitle
    120. //#endregion
    This will allow you to successfully remove the kil death & rank along with the loyalty title below your players name.

    Im trying to match OSI base because OSI dont have this in there game.
     
    • Two Thumbs Up Two Thumbs Up x 1
  4. cmileto
    Online

    cmileto Member

    Joined:
    Nov 18, 2013
    Messages:
    173
    Likes Received:
    7
    Actually UO does (or at least did). I think it came in publish 60.
    http://www.uoguide.com/Publish_60

    i think you needed certain amount of loyalty points to place a house in termur and other stuff.
    I think Gargolyes are supposed to start with 2000 points, not sure if this part works.
     
    #4 cmileto, Nov 28, 2013
    Last edited: Nov 28, 2013
  5. WarFace
    Offline

    WarFace Member

    Joined:
    Nov 25, 2013
    Messages:
    27
    Likes Received:
    5
    I know the loyalty part is osi correct just not the title below your name. I play OSI till this day and there is no title system below your character name.
     
    • Like Like x 1
  6. Hank
    Offline

    Hank Active Member

    Joined:
    Nov 14, 2013
    Messages:
    972
    Likes Received:
    152
    *hic* I remember first seeing it this way on orb 3.0
    Could be something that wasn't finished when trying to replicate a OSI/EA quest but I'm not sure.
    *hic*
     
  7. Ravenwolfe
    Offline

    Moderator ServUO Developer

    Joined:
    Sep 7, 2013
    Messages:
    1,146
    Likes Received:
    123
    I would suggest just commenting the list.Add part of the queens loyalty system instead of commenting that whole block. I know that title is stored on playermobile and some of that code may have use now or in the future.

    On my shard, I just commented out the list.Add in both places you mentioned. Its not needed to comment it all.
     
    • Like Like x 1
  8. tass23
    Offline

    Moderator

    Joined:
    Aug 28, 2013
    Messages:
    1,012
    Likes Received:
    131
    Zagros designed the Queen's Loyalty system to be used as an XmlAttachment. That is why it is displayed as you see it hovering over players. Raven is correct, just commenting the list.Add in the above mentioned places will remove the title display on players, but the system itself will still be in effect.
     
    • Informative Informative x 1
  9. Dexter_Lexia
    Offline

    Moderator ServUO Developer

    Joined:
    Jul 3, 2014
    Messages:
    2,207
    Likes Received:
    102
    Thread successfully necrod. I worked on this system a bit, mostly the housing portion and a table for the monsters/quests in the recent commit. After reading the link above, EA will introduce other types of loyalty systems. This makes me wonder if the entire system should be rewritten to support adding new loyalties in the future. In doing so, I would get rid of the title on the player from mouse over (not EA accurate) and remove all code from PlayerMobile.cs and have the system keep its data internally. Removing the serialize/deserialize would be easy but an eye sore, which is why I don't like serializing stuff like this is major base classes like PlayerMobile.
     
  10. Hank
    Offline

    Hank Active Member

    Joined:
    Nov 14, 2013
    Messages:
    972
    Likes Received:
    152
    @Ravenwolfe over on JustUO spent some time reworking the queen's loyalty system in the code. Maybe if he is willing and has time he could fill us in.
    I started working on a pull request with his work but never finished.
     
Similar Threads: Custom Loyalty
Forum Title Date
Script Support Questions about levelable/customizable weapons Oct 10, 2017
ServUO Discussion How to update my version of Serv-UO without losing my customs Oct 4, 2017
Tutorials Creating Custom Paintings Oct 3, 2017
General Discussion Customizable House Plots Oct 1, 2017
Donor only scripts Custom Skills Gump Sep 29, 2017
Script Support Custom Skills Gump Sep 21, 2017
Art Era's Custom Clothing Sep 7, 2017