feat(bridge): TruePVE in a zone on protocol 14 (PLAN_REDESIGNS §14.3.2)
All checks were successful
PR Checks / plugin-checks (pull_request) Successful in 10s
All checks were successful
PR Checks / plugin-checks (pull_request) Successful in 10s
Stage 3 of the §14.3 integration plan (D362, D368), specified in docs
rust-link/PROTOCOL.md §20.6.
- world.zone's optional truePve: {"exclude": true} or {"ruleset": "name"},
exactly one, the name 1-64 characters. Malformed is `malformed`; TruePVE
not loaded is `truepve-missing`.
- All or nothing: the zone (and its dome) is made, then AddOrUpdateMapping.
A false erases both and answers `truepve-ruleset` with the name (or
`refused` for exclude).
- The registry entry remembers its mapping, and every path that erases one
of our zones calls RemoveMapping first: the deadline, world.revert, a zone
world.owned finds gone, a new wipe. While TruePVE is away the id waits in
data/RunicGateway/truepve.json, flushed at OnPluginLoaded(TruePVE) and at
the bridge's own load.
- hello's integrations.truePve { loaded, version }, sent again when TruePVE
loads or unloads. rg.world prints truePve= and truePveLeftover=.
Compiled and loaded on both rigs (Rust 25902425, Oxide 2.0.7830, Carbon
2.0.262, TruePVE 2.4.6).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01E14m6SuuY6i1vASFeGDBeY
This commit is contained in:
@@ -110,6 +110,11 @@ backpack from the site, a player can see their own, and an event can lend a bigg
|
||||
the bridge only ever reads a backpack, and the bigger size is one of Backpacks' own `backpacks.size.N`
|
||||
permissions, pushed like any other grant.
|
||||
|
||||
nivex's `TruePVE` is optional in the same way. Where it is loaded an event's zone can turn off PvP
|
||||
protection inside it, or use one of the operator's own TruePVE rulesets by name; where it is not, the
|
||||
zone step says "TruePVE is not installed on this server". The bridge only ever adds and removes the
|
||||
mappings of zones it opened, and removes each one with its zone, even when TruePVE was away at the time.
|
||||
|
||||
Rust's own world events need no plugin at all. The patrol helicopter, Bradley, the cargo ship, the
|
||||
Chinook, airdrops, locked crates, the Travelling Vendor, the satellite and the Deep Sea reach the
|
||||
site's feed and its event triggers on every server, and an event can call one of them (`world.call`).
|
||||
|
||||
@@ -5169,8 +5169,9 @@ namespace Oxide.Plugins
|
||||
// Hello carries ZoneManager's flag list and both helpers' states, so a change to any
|
||||
// of the four is said again rather than waiting for the next connect (§3.1, §3.2).
|
||||
// Economics too: hello carries its starting balance, which the richest column needs;
|
||||
// and Backpacks, whose sizes are what a Bigger backpack step offers.
|
||||
if (IsZonePlugin(plugin) || IsRunicNpc(plugin) || IsEconomics(plugin) || IsBackpacks(plugin))
|
||||
// and Backpacks, whose sizes are what a Bigger backpack step offers; and TruePVE, which a
|
||||
// zone step's PvP rules are refused without (§14.3.2).
|
||||
if (IsZonePlugin(plugin) || IsRunicNpc(plugin) || IsEconomics(plugin) || IsBackpacks(plugin) || IsTruePve(plugin))
|
||||
NextTick(ResendHello);
|
||||
|
||||
// Economics loaded after players connected: what they hold now is not otherwise known
|
||||
@@ -5200,7 +5201,7 @@ namespace Oxide.Plugins
|
||||
if (plugin != null && plugin.Name == "BetterChat")
|
||||
_titlesRegistered = false;
|
||||
|
||||
if (IsZonePlugin(plugin) || IsRunicNpc(plugin) || IsEconomics(plugin) || IsBackpacks(plugin))
|
||||
if (IsZonePlugin(plugin) || IsRunicNpc(plugin) || IsEconomics(plugin) || IsBackpacks(plugin) || IsTruePve(plugin))
|
||||
NextTick(ResendHello);
|
||||
|
||||
ConfigWriteJob job = _configJob;
|
||||
|
||||
Reference in New Issue
Block a user