Origins (1.23.1)
Curse Maven Snippet
What's new
Fixed
- Transferring an origin out of a swap pool did nothing, silently.
origins:transfer_originonly ever read the origin a player had chosen on the layer it was pointed at, and a swappable layer records no chosen origin — it holds a pool of granted ones. Aiming a transfer at such a layer therefore found nothing to move, ran its follow-up actions and reported success. It now reads the pool when the layer is swappable, and reads whichever origin the player is currently wearing when asked to. Taking an origin also removes it from wherever it genuinely came from, so a move out of a pool revokes that one entry instead of clearing the whole layer.
Added
-
A way to say which origin is being transferred, for players who hold several.
origins:transfer_originandorigins:copy_origingained aselectionfield with four values.mainis the layer's chosen origin and remains the default for an ordinary layer.activeis whatever the player is actually playing as, which is the swapped-in origin if they are swapped and the chosen one otherwise.poolis the origins sitting in their swap pool, and is the default when the layer being read is itself swappable.alltakes the chosen origin and the entire pool together, transferring every one of them. Where a selection turns up more than one candidate the first is taken, or a random one ifrandomis set, and a neworiginfield skips the search entirely by naming exactly which origin to move regardless of where the donor keeps it. -
origins:grant_originandorigins:revoke_origin, two new entity actions for handing an origin to a player and taking it back. Granting on an ordinary layer makes the origin that player's pick; granting on a swappable layer adds it to their swap pool; andto_poolon an ordinary layer adds it to the pool feeding that layer instead of replacing what they have, which is the "unlock another form they can swap into" case. Revoking takes one named origin back from wherever it sits, or clears the layer and its whole pool when no origin is named, and a player currently swapped into a revoked origin is dropped back to their own. Until now the only way to give a specific origin from data was a two-step detour throughorigins:store_originandorigins:apply_stored_origin, and there was no way to take one back at all. -
The
origins:origincondition can look somewhere other than the chosen origin. A newselectionfield takes the same four values as the transfer action. This matters because the default — and the only previous behaviour — is to check what the player chose, which means a swapped-in origin read as absent.activeasks what they are actually playing as,poolasks what they could swap to, andallasks whether they have it in any sense at all. -
/origin revoke <targets> <layer> [origin], the operator-side counterpart to/origin set. With an origin named it takes that one out of the player's pool, or clears the layer if that origin was their pick; without one it removes everything on that layer, pick and pool together. -
Origins are readable from expressions. Two variables,
origin_countfor how many layers the player has a non-empty origin on andis_swappedfor whether any layer is currently swapped, plus five functions that take an id:has_originandtarget_has_originfor whether a player has a given origin anywhere, counting an active swap;in_origin_poolfor whether it is sitting in their pool;has_origin_onfor whether a given layer holds anything; andorigin_impact, which reports a layer's active origin's impact as a number from 0 to 3. All of them answer correctly on the client as well as the server, which is what lets them drive the client-side things Apoli evaluates during rendering.
Changed
/origin setno longer refuses an origin that is not in a swappable layer's own list. Pool grants were never checked against that list — the whole point of a swappable layer is that it can ship empty and be filled at run time — so the command was rejecting something the underlying system was perfectly happy to do.

