Highly Performant & Scalable Ultima Online Server Emulator https://www.modernuo.com
Find a file
Kamron Batman 0f2870e94a
feat: Adds Stamina System to overhaul overweight. (#1465)
## Overhaul to Stamina (Overweight) System

### Added configurations

```json
{
  "settings": {
    "stamina.enableMountStamina": "True",
    "stamina.cannotMoveWhenFatigued": "True",
    "stamina.stonesPerOverweightLoss": "25",
    "stamina.stonesOverweightAllowance": "4",
    "stamina.baseOverweightLoss": "5",
    "stamina.additionalLossWhenBelow": "0.1",
    "stamina.mountLastMoveStepsReset": "01:00:00:00",
    "stamina.enableMountStamina": "True",
    "stamina.useMountStaminaOnlyWhenOverloaded": "False",
  },
}
```
- `stamina.cannotMoveWhenFatigued` - By default, Pre-AOS expansions will outright block a player if they are fatigued. A player is fatigued when they run out of stamina by any mechanism.
- `stamina.stonesPerOverweightLoss` - The amount of stamina lost for every X stones above overweight. Example, if a person is overweight 28 stones overweight, then there there is 1 additional stamina. 28 / 25 = 1 (no decimals, no rounding)
- `stamina.stonesOverweightAllowance` - The number of stones allowed before overweight penalties take affect. This _does not_ substract from the overweight stones calculation.
- `stamina.baseOverweightLoss` - The base amount of stamina loss for being overweight. While running, the final amount is multiplied by 2. If mount stamina is turned off, then the final amount is divided by 3 while mounted. 

### Mount stamina

Mounts have a new property `StepsMax` to determine the maximum steps they can take before being fatigued. To regain steps, the player _must stay on the mount and not move_ (per OSI). The gain rates are configurable. If a mount is dismounted, or the player logs off, the mount is considered inactive and mounts regain all of their steps after _24 hours_.

### Changes to player stamina

Players now have a proper inactivity time reset for their steps. If a player is idle for 16 seconds (including logging off, or the server being offline), then the steps counter is rest.

### Developer Notes

- `StepsTaken` - This field has been removed. It was not serialized and could not be used reliably. If a developer was using it, then the recommendation is to build a mechanism to track total steps another way.
- `IHasStamina` - This new interface was added and currently `IMount` and `PlayerMobile` are valid types.

Important: Entities that are sent to the StaminaSystem for tracking (mounts, players, or something else), must be an `ISerializable` to be serialized properly. If they are not, then the serialization system will record a null, and nothing will be deserialized upon world load. No errors will be given.
2023-09-16 17:52:54 -07:00
.config fix: Codegens talismans - Fixes memory leak (#1469) 2023-08-23 22:41:48 -07:00
.github fix: Bumps PollGroup to fix NPE error (#1497) 2023-09-13 12:51:12 -07:00
Distribution/Data fix: Fixes expansions.json to correctly reflect name of supported feature flags (#1471) 2023-08-25 11:55:36 -07:00
docs docs: Adds starting a server notes and tips. (#1487) 2023-09-03 09:49:42 -07:00
Projects feat: Adds Stamina System to overhaul overweight. (#1465) 2023-09-16 17:52:54 -07:00
.editorconfig Adds ModernUO docs skeleton (#243) 2020-09-13 15:21:28 -07:00
.gitattributes fix: Adds migration checks to CICD, updates dependencies, adds Fedora 37, alpine 3.17 support (#1309) 2022-12-22 12:12:47 -08:00
.gitignore feat: Customize expansion and set maps on first boot (#1425) 2023-07-31 20:46:49 -07:00
azure-pipelines.yml fix: Bumps PollGroup to fix NPE error (#1497) 2023-09-13 12:51:12 -07:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md 2020-05-05 08:51:39 -07:00
CONTRIBUTING.md chore: Updates discord links (#394) 2021-01-07 01:04:05 -08:00
Directory.Build.props fix: Changes C# version to 11 (#1461) 2023-08-16 20:12:56 -07:00
FAQ.md docs: Updates FAQ for time zone issues. (#1368) 2023-03-10 00:18:36 -08:00
global.json chore: Update from .NET 7 preview to release. (#1234) 2022-11-08 09:46:48 -08:00
LICENSE Fixes more line ending issues (#267) 2020-09-27 13:54:56 -07:00
mkdocs.yml docs: Updates serialization docs (#1327) 2023-02-02 19:37:18 -08:00
ModernUO.sln fix: Replaces FindItem(s)ByType(s) implementation with BFS strategy (#1454) 2023-08-18 22:05:28 -07:00
publish.cmd fix: Removes echo in publish that is not needed (#1477) 2023-08-29 07:53:10 -07:00
publish.sh feat: Adds .NET 7 & Arm64 support (#1229) 2022-11-06 09:59:11 -08:00
README.md chore: Adds VC++ Redist 17 to README (#1498) 2023-09-13 22:54:32 -07:00
rider-settings.zip Cleanup/Housekeeping (#242) 2020-09-12 15:31:21 -07:00
Rules.ruleset Cleanup & Fixes for .NET 5 (#309) 2020-11-15 10:03:50 -08:00
RUNUO_TO_MODERNUO.md chore: Adds changed mechanics (#1117) 2022-07-14 21:13:03 -07:00
SPONSORS.md Adds Chia to sponsors page 2023-02-24 19:16:27 -08:00
stylecop.json Updates formatting rules (#199) 2020-08-25 18:00:51 -07:00
THIRD-PARTY-NOTICES chore: Updates 3rd party notices (#1042) 2022-06-01 09:42:11 -07:00
version.json feat: Adds Stamina System to overhaul overweight. (#1465) 2023-09-16 17:52:54 -07:00

ModernUO Discord Subreddit subscribers Twitter Follow Gitter

Ultima Online Server Emulator for the modern era!

GitHub license GitHub stars GitHub issues
GitHub build AzurePipelines build

Requirements

Supported Operating Systems

Windows 10/11/2019/2022 MacOS 11+ Debian 10+ Ubuntu 16+ LTS
Alpine 3.18+ Fedora 33+ RedHat 7/8 CentOS 7/8/9 openSUSE 15+ SUSE Enterprise 12 SP2+ Linux Mint 17+ Arch

Required Frameworks

All Operating Systems

.NET

Windows

VC++ Redistributable 17

Development

git .NET

Supported IDEs

Jetbrains Rider 2023.2+spaceVSCodespaceVisual Studio 2022 v17.7+

Getting Started

  • Install prerequisite requirements
  • Clone this repository (or download the latest):
    • git clone https://github.com/modernuo/ModernUO.git
  • Open ModernUO.sln to start developing

Building/Publishing

  • Run ./publish.cmd [release|debug (default: release)] [os] [arch (default: x64)]
    • os - Supported operating systems
      • win - Windows 10/11/2019/2022
      • osx - MacOS 11/12/13 (Big Sur, Monterey, Ventura)
      • linux - Linux
    • arch
      • x64 - Intel 64-bit
      • arm64 - ARM 64-bit (Windows Arm64 not supported)

Linux Prerequisites

Fedora, CentOS, RHEL, etc

dnf upgrade --refresh -y
# CentOS does not come with EPEL enabled
dnf install -y epel-release epel-next-release
dnf install -y findutils libicu zlib-devel zstd libargon2-devel tzdata

Ubuntu, Debian, etc

apt-get update -y
apt-get install -y libicu-dev libz-dev zstd libargon2-dev tzdata

Running the Server

  • Follow the publish instructions
  • Run ModernUO.exe or dotnet ModernUO.dll from the Distribution directory on the

Troubleshooting / FAQ

Want to sponsor?

Thank you for supporting us! You can find out how by visiting the sponsors page.

Collaborators

Kamron Batman Mark1145

Thanks

  • RunUO Team & Community
  • Voxpire, the ServUO Team & Community
  • Karasho, Jaedan and the ClassicUO Community



Development Tools & Plugins provided with ♥ by
JetBrains Material Theme