agentleFS
blushneybusiness-glitchblushneybusiness-glitch/roblox-omniskills/skills/rbx-analytics-events/SKILL.md

rbx-analytics-events

Skill0 starsChanged 3 months agoMITView on GitHub

AnalyticsService instrumentation that survives launch — one wrapper module, a disciplined event taxonomy, economy/funnel/progression/custom events logged server-side within rate limits. Use when the user says "add analytics", "track events", "instrument the economy", "log purchases/kills/levels", or when the dashboard is empty, numbers look impossibly high, or events silently stopped appearing. Do not use for interpreting the resulting charts — load rbx-analytics-reading — or for multi-step drop-off analysis — load rbx-analytics-funnels instead.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Server logs, client never: Every AnalyticsService call runs in a server script.

    line 18
  2. Very specific:

    Read: the game's projects.md block for the established event-name registry and currency names — a second system on the same game extends …

    line 88
  3. Very specific:

    Write: every new event name, funnel name, and SKU string into that block the moment it ships.

    line 90

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

rbx-analytics-events

Laws

  1. Server logs, client never. Every AnalyticsService call runs in a server script. A client-fired event is an exploiter-writable metric; one spam loop poisons a month of data. Client actions that matter reach the server through the RemoteEvents they already use (rbx-net-remotes) — log in the server handler, after validation.
  2. Log success, not attempt. Fire the event after the purchase grants, the quest completes, the level saves. Attempt-logging inflates every metric it touches and the inflation is undetectable later.
  3. One wrapper module. Systems call Analytics.Track(...) / Analytics.Economy(...); nothing calls the service raw. The wrapper batches, throttles, and pcalls — a dead analytics backend must never error gameplay code.
  4. Custom fields for variants, never event names. The budget is 100 unique event names for the lifetime of the universe — exceed it and new names are silently ignored. EnemyKill with CustomField01 = weapon beats EnemyKill_Sword + EnemyKill_Bow forever.
  5. Names are permanent. Renaming an event severs its history; the old chart flatlines and the new one has no baseline. Pick PascalCase names on day one and never touch them.
  6. Every currency logs both directions. A Source without its Sinks (or vice versa) makes inflation invisible until players feel it. Balance-after-transaction is a required argument, not decoration — pass the real post-transaction balance.

Passes

  1. Wrapper — ServerScriptService/Analytics/Tracker ModuleScript: Track(player, name, value?, fields?), Economy(player, flow, currency, amount, balance, txType, sku), FunnelStep(player, funnel, step, name). Each method wraps the service call in pcall and increments a per-minute counter; over budget → queue, don't drop silently.
  2. Batcher — high-frequency counters (kills, pickups, damage) accumulate in a { [Player]: { [name]: number } } table, flush every 30s and on PlayerRemoving. Purge entries for departed players at flush or the table leaks Player references.
  3. Economy events — LogEconomyEvent at every faucet and sink rbx-economy-currencies defined: flow type Source/Sink, currency name (10 currency types max), amount, balance after, transaction type from Gameplay | Shop | ContextualPurchase | InAppPurchase | TimedReward | Trade, SKU string naming the trigger (QuestReward_Daily, SpeedBoost_30min).
  4. Progression events — LogCustomEvent(player, "LevelReached", level) on level-up, zone unlocks with CustomField01 = zone name, plus SessionDuration (seconds) on PlayerRemoving.
  5. Funnel steps — onboarding and purchase funnels via rbx-analytics-funnels; the wrapper exposes FunnelStep so those skills don't touch the service either.
  6. Verify — Creator Hub → Analytics → the event category → "View Events" shows fires within seconds; the dashboard charts lag up to 24 hours. No event in View Events after a test run = your call never executed; check get_console_output for the pcall's logged failure before touching the dashboard again.

Performance budget

Rate limit: 120 + 20 × CCU calls per minute, exceeded calls dropped with no error — batching is mandatory, not optional. Budgets: 100 custom event names, 10 economy currency types, 3 custom fields per event, 8,000 unique values per field (then bucketed as "Other"). The batcher's flush loop is one task.spawn with task.wait(30), not a per-player loop.

Load with

rbx-analytics-funnels (step events), rbx-analytics-reading (what the numbers mean), rbx-abtest (exposure events ride this wrapper), rbx-script-production (the wrapper is built under its idempotency contract). Economy instrumentation points come from rbx-economy-currencies.

AI-tells

  • ☐ Raw AnalyticsService calls scattered across scripts instead of one wrapper
  • ☐ Events logged from LocalScripts
  • ☐ Variant baked into the event name (EnemyKill_Zombie_Sword_Wave5)
  • ☐ Economy events with a guessed or stale balance argument
  • ☐ Kill/pickup events fired unbatched every hit
  • ☐ Logging inside the attempt branch instead of the success branch
  • ☐ No pcall — analytics failure can break a purchase handler
  • ☐ Event names invented mid-project that duplicate an existing metric under a new spelling

Memory

Read: the game's projects.md block for the established event-name registry and currency names — a second system on the same game extends the existing taxonomy, never forks it. Write: every new event name, funnel name, and SKU string into that block the moment it ships; the wrapper module's location into module-library.md once it survives its first project.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.