VIP Trial [Inactive]
v1.0.0Allows eligible players to redeem a free 3-day VIP trial.
Documentation
Flow
/viptrial → checks eligibility → prompts with /confirm /confirm → grants viptrial group → server-wide announcement → schedules auto-removal in exactly 3 days
Eligibility checks (all enforced at both steps)
Already in vip, viptrial, or vipplus → blocked with a message Already used a trial (stored in data file) → permanently blocked from claiming a second one
Performance optimizations
HashSet<ulong> for pending confirms — O(1) lookups, no per-tick overhead Dictionary<ulong, Timer> for expiry timers — one timer per player, old ones cancelled before replacing Timers are destroyed on Unload() to prevent memory leaks No repeated permission lookups; single IsVip() call gates both commands Data is only written to disk on actual trial activation, not on every hook
Persistence / crash safety
Expiry timestamps saved to Oxide's data file as UTC ticks (VipTrial.json) On OnServerInitialized, all saved trials are re-evaluated — expired ones are removed immediately, active ones have their timers rescheduled for the remaining duration Players that disconnect mid-flow (between /viptrial and /confirm) are automatically cleared from the pending set
Installation
Drop VipTrial.cs into your oxide/plugins/ folder Make sure the viptrial Oxide group exists: oxide.group add viptrial Assign whatever permissions you want to that group and you're good to go
Commands
Checks eligibility → prompts with /confirm
Grants viptrial group → server-wide announcement → schedules auto-removal in exactly 3 days