跳到主要内容

OblivionMP SDK 1.2.0 released

· 阅读需 5 分钟
ReadyM 团队
WukongMP 和 OblivionMP 的开发者

1.2.0 is out, and the biggest change is that the server keeps the time: everyone on it is in the same hour of the same day. Bans, kicks and whitelists hold where they used to let people through. Your level and your skills survive a logout, and poison stays on the weapon you put it on.

There is nothing to install if you play. The launcher updates your game when you join a server that has moved to 1.2.0, and until a server updates you stay on 1.1.1 there.

Mods need rebuilding, and most need editing, so read Upgrading before you start.

What's new​

One clock for the server​

The server keeps the time of day and the date, and every player's game follows it, so you no longer walk through a door into a different hour.

Waiting and sleeping are off as a result, since one player's six-hour nap would be everyone's six hours. The wait key, T by default, does nothing. A bed opens the level-up menu if you have a level-up ready, and otherwise does nothing. A server owner who wants them back turns AllowTimeSkip on in mods/OblivionMp.Sdk/server/config.json and HideWaitMenu off in mods/OblivionMp.Sdk/client/config.json, which the server hands out to players.

Connections, bans and whitelists​

A banned or kicked player stays out, and so does one who is not on the whitelist. A handful of ways around them are closed. One account also plays from one PC at a time: a second machine no longer takes over a session that is already running.

A dropped connection keeps retrying now, where the game used to try once and give up. It stops when you quit, or when the server gives a reason that no retry will fix, such as a kick or a ban.

Fixed​

  • Logging out no longer costs you the level and skill progress you made since your last level-up.
  • A fortify effect from a spell or potion wears off when it should. Quitting while one was running used to make it part of your character for good.
  • Poison belongs to the weapon now, not to your character, so a poisoned blade you trade, store or drop stays poisoned. Poison a second weapon and both keep their own.
  • Looting a dead archer gives you their whole stack of arrows, instead of one arrow per pickup.
  • A ring on an NPC's left hand comes off again, instead of staying worn.
  • Loading screens show your name and level instead of “level 0”. The one at startup shows no player line, since your character is not known until the server sends it.
  • An NPC killed in the middle of a swing no longer repeats that swing for as long as the body lies there.
  • Summons no longer stay behind after a disconnect or a reload.
  • The Rebirth command works without a quicksave. It used to press the game's quick-load, which does nothing unless you had made one.

Upgrading​

Your mods​

Bump the SDK packages and your manifest's minimumVersion to 1.2.0, then work through this:

Was, in 1.1.1Now, in 1.2.0
SkillAttributes, read and writeSkillAttributes is read-only and holds the effective values, base plus running effects. Write BaseSkillAttributes instead.
The Time mixin, on Area, owner-basedRenamed GameTime, because Time inside a service is the service's update clock. It is on World now and server-authoritative, so a client cannot write it.
Time.GameHour, a float from 0 to 24GameTime.TimeOfDay, a read-only TimeSpan, and GameTime.TimeOfDayMinutes, a float counting from midnight
Time.GameDaysPassed, a floatGameTime.GameDay, a uint, still counting days since the world started
Time.TimeScaleGameTime.Timescale, lower-case s
SessionClockWorldClock, in OblivionMP.SDK.Serverside.Systems. NowGameHours() works the same and is no longer per area.
TimeChangeEventTimeSkipRequestEvent, raised when a player confirms the wait menu. It is a request rather than a notification, so read GameTime to follow the clock itself.
Equipment.CurrentPoison, one per characterItemExtraData.Poison, one per item, on inventory entries and dropped items

Also new: LevelMixin.LevelExperience for progress towards the next level, GameTime.Date and the OblivionMP.SDK.Common.Calendar namespace for the Tamrielic calendar, and ServerConfig and ClientConfig for the SDK's own settings.

WorldClock is a service like any other, so a mod that wants to run time its own way disables it through IServices and advances GameTime itself. Time skipping is the same: handle TimeSkipRequestEvent and do what you like with it. The SDK applies the skip itself when AllowTimeSkip is on, so a handler of your own that also advances the clock skips the time twice. Leave the setting off and do the work yourself. Time, weather and session covers all of this.

Recompile even if nothing above applies to your mod: one built against 1.1.0 or 1.1.1 will not load on 1.2.0.

Your server​

  1. Recompile your mods against the 1.2.0 SDK.
  2. Download the 1.2.0 server package for Windows or Linux from Installation.
  3. Stop the old server.
  4. Copy the saves folder, the data folder, the branding folder and the server's own config.json from the old server folder into the new one.
  5. Copy your own mods into the new mods folder, and with them any config file you edited in a mod the package ships.
  6. Start the new server.

Existing saves load as they are, skills and all.

Check Known issues before reporting a bug. Anything not on it, report on the OblivionMP Discord.