Documentation / Safety, Recovery & Cleanup
PROPOSED API
API specification — not a released addon. SkCine-specific syntax shown here is proposed and must be implemented and server-tested before use.

Safety, Recovery & Cleanup

API status — PROPOSED, NOT IMPLEMENTED. SkCine is currently a design specification in this conversation; no built SkCine.jar or syntax registry was supplied. All SkCine-specific examples are intended API contracts, not verified runnable .sk. Do not advertise these as tested until each example passes a real Skript reload and runtime test.

Golden rule

A cinematic is temporary. The player must return to normal state on completion, stop, skip, failure, death, disconnect, reload and plugin disable.

Snapshot and restoration

Capture before changing: camera target, gamemode if spectator backend uses it, location/rotation if necessary, flight and explicitly overridden movement flags, relevant owned UI/visibility state.

Do not snapshot and overwrite inventory, permissions, progression, or unrelated status effects. Use compare-and-restore or ownership tokens if other plugins change overlapping state during playback.

Cancellation reasons

completed, skipped, stopped, player-quit, player-died, world-change, script-unloaded, plugin-disabled, backend-error, capability-unavailable, resource-limit, replaced-by-new-scene.

on cine scene cancel:
    if event-cine-reason is "player-quit":
        broadcast "A viewer left a cinematic."

Crash recovery

Journal minimal player state before disruptive changes and invalidate journal on successful restoration. On reconnect, reconcile rather than blindly overwrite current state. Journal serialization is an internal resilience mechanism, never the scene authoring workflow.

Locking conflicts

For a player already watching a scene, apply a configurable policy: reject, queue, replace, or stack-if-safe. Multiple simultaneous camera owners for one viewer are unsafe unless managed by an explicit priority stack.

Testing checklist

  • Stop at every keyframe; restore immediately.
  • Disconnect mid-spectator; reconnect.
  • Force a track exception; ensure cleanup.
  • Reload source .sk; no stale callbacks.
  • Disable addon while in scene; restore as much as shutdown allows.
  • Confirm existing world actors are not deleted.
© 2026 DHeaven · SkCine documentation design · All scene authoring happens in Skript (.sk).