ModernUO/Projects/UOContent/Items/Special
Kamron Batman f77dd91811
fix: Overhauls virtue system (#1376)
## MAJOR CHANGE (API BREAKING)

Moved the virtues to it's own system _VirtueSystem_. This should make it easier to extend or remove the virtue system. Virtues will be saved to a new folder called _Virtues_.

### Motivation

The motivation was also two-fold, performance/stability, and to fix bugs.

First, virtues is the second system (first is murders), that has a pre-world-save check on _every mobile in the game_ to atrophy virtue stats. This is taxing since it freexes the world and makes world saves take longer. Every mobile had Gain/Loss dates for each virtue, whether they needed them or not. Most players don't even use the virtue system, so this will increase performance considerably.

Second, when I tried to optimize/refactor the code, I found several bugs that needed to be fixed.

### Major API Changes

- [X] The properties on players related to virtues are gone. Use `pm.GetVirtues()?.<PropertyName>` instead.
- [X] Virtues were removed from non-player Mobiles.
- [X] `pm.JusticeProtectors` was removed. Use `JusticeVirtue.GetProtector()` or `JusticeVirtue.GetProtected()` instead.

### Screenshots

<img width="221" alt="Props-1" src="https://github.com/modernuo/ModernUO/assets/3953314/5c09cb83-b8d5-44a2-b899-a7ed7cd736ac">
<img width="220" alt="props-2" src="https://github.com/modernuo/ModernUO/assets/3953314/aeade4d3-8df0-47bd-955a-a864d0946cf7">
2023-07-19 21:43:47 -07:00
..
8th Anniversary Items fix: Codegens promo items (#1355) 2023-02-26 00:48:27 -08:00
11th Year promo fix: Codegens promo items (#1355) 2023-02-26 00:48:27 -08:00
AoS Promotional fix: Codegens promo items (#1355) 2023-02-26 00:48:27 -08:00
Broken Furniture Collection fix: Fixes broken chair (#1356) 2023-02-27 09:01:50 -08:00
Bulk Order Rewards/Blacksmithy fix: Codegens BOD rewards. (#1361) 2023-03-06 19:01:14 -08:00
Community Collection fix: Codegens BOD rewards. (#1361) 2023-03-06 19:01:14 -08:00
Evil Home Decor Collection fix: Codegens evil decor. Fixes trash items (#1362) 2023-03-06 19:28:58 -08:00
Gifts fix: Codegens gifts (#1363) 2023-03-07 21:07:45 -08:00
Heritage Items fix: Fixes scales, heritage items, and codegens holiday items (#1365) 2023-03-07 22:38:35 -08:00
Holiday fix: Fixes scales, heritage items, and codegens holiday items (#1365) 2023-03-07 22:38:35 -08:00
House Raffle fix: Fixes leaking/errors caused by categorization (#1404) 2023-05-19 18:41:31 -07:00
ML fix: Codegens mutation core (#1370) 2023-03-11 17:33:31 -08:00
Mutation Core fix: Codegens mutation core (#1370) 2023-03-11 17:33:31 -08:00
Rares fix: Codegens rares and solen items (#1371) 2023-03-11 19:25:48 -08:00
Solen Items fix: Overhauls virtue system (#1376) 2023-07-19 21:43:47 -07:00
Special Scrolls fix: Fixes special scrolls (#1373) 2023-03-12 13:47:12 -07:00
Valentines/2007 fix: Fixes veteran rewards (#1374) 2023-03-12 17:28:51 -07:00
Veteran Rewards fix: Fixes veteran rewards (#1374) 2023-03-12 17:28:51 -07:00
HeritageToken.cs fix: Fixes localization corner cases with OPL (#1050) 2022-06-12 21:17:42 -07:00
MiniHouses.cs fix: Optimizes OPL using string interpolation (#1041) 2022-06-02 10:09:53 -07:00
MonsterStatuette.cs fix: Optimizes OPL using string interpolation (#1041) 2022-06-02 10:09:53 -07:00
RewardCake.cs fix: Fixes crafter deserialize, cleans up bandages, and codegens misc items (#1350) 2023-02-25 00:54:12 -08:00
SoulStone.cs fix: Fixes special scrolls (#1373) 2023-03-12 13:47:12 -07:00