AgentSkillsCN

Skill

技能

SKILL.md

Roblox Studio Game Development Skill

⚠️ CRITICAL: Read Before Coding

DataStore DOES NOT WORK in Studio by Default!

If you see "Loading..." that never updates, this is almost always the cause.

To enable DataStore in Studio:

  1. Game Settings → Security → Enable "Enable Studio Access to API Services"
  2. Game must be published (not just saved locally)

Or use mock data for Studio testing:

lua
if game:GetService("RunService"):IsStudio() then
    return { Coins = 100, Level = 1 }  -- Mock data for testing
end

For any stuck/loading issues, ALWAYS read references/00-troubleshooting.md FIRST.


Overview

This skill enables creation of excellent, polished Roblox games—not just technically functional ones. It contains best practices extracted from top-performing games like Adopt Me, Blox Fruits, Phantom Forces, Jailbreak, and others.

When to Use This Skill

Use this skill when:

  • Creating any Roblox game from scratch
  • Adding features to existing Roblox games
  • Reviewing/improving game quality
  • Implementing specific systems (combat, monetization, UI, etc.)
  • Debugging performance or player retention issues

Quick Reference: The 10 Pillars of Professional Roblox Games

  1. Layered Feedback - Every action triggers visual + audio + camera + UI response
  2. Sub-60-Second First Fun - Players experience core gameplay within one minute
  3. Consistent Art Direction - Unified visual style across all assets
  4. Responsive Controls - Never laggy, even with satisfying animations
  5. Ethical Monetization - Enhances without blocking gameplay
  6. Multiple Retention Loops - Daily, weekly, and long-term engagement
  7. Server-Authoritative Architecture - All critical logic server-side
  8. Cross-Platform First - Mobile as baseline, scale up for PC
  9. Data-Informed Decisions - Analytics driving improvements
  10. Regular Content Updates - Fresh content keeps players engaged

File Structure

code
roblox-skill/
├── SKILL.md                           # This file - start here
├── references/
│   ├── 00-troubleshooting.md          # ⚠️ READ FIRST for any issues!
│   ├── 01-game-feel.md                # Juice, feedback, screen shake, particles
│   ├── 02-player-psychology.md        # Engagement loops, rewards, hooks
│   ├── 03-onboarding.md               # Tutorials, first-time experience
│   ├── 04-visual-design.md            # Lighting, materials, post-processing
│   ├── 05-sound-design.md             # Audio, music, spatial sound
│   ├── 06-level-design.md             # Map layout, spawns, flow
│   ├── 07-monetization.md             # GamePasses, DevProducts, ethics
│   ├── 08-retention.md                # Daily rewards, events, progression
│   ├── 09-animation.md                # Character animation, priorities
│   ├── 10-polish.md                   # Loading, errors, accessibility
│   ├── 11-social-multiplayer.md       # Chat, trading, parties
│   ├── 12-apis.md                     # Roblox-specific services
│   └── 13-testing.md                  # QA, performance, analytics
├── code-templates/
│   ├── feedback-systems.lua           # Screen shake, hit stop, particles
│   ├── data-management.lua            # DataStore wrapper with retry
│   ├── player-data-server.lua         # Server-side leaderstats setup
│   ├── coin-display-ui.lua            # Client UI that handles loading state
│   ├── daily-rewards.lua              # Complete daily reward system
│   ├── remote-security.lua            # Anti-exploit patterns
│   ├── sound-manager.lua              # Audio with crossfading
└── checklists/
    ├── pre-launch.md                  # Before going live
    ├── mobile-optimization.md         # Mobile-specific
    └── security-audit.md              # Anti-exploit review

How to Use This Skill

For New Games

  1. Read references/02-player-psychology.md first - understand your core loop
  2. Read references/03-onboarding.md - plan the first 5 minutes
  3. Implement core gameplay with feedback from references/01-game-feel.md
  4. Add visuals using references/04-visual-design.md
  5. Before launch, run through checklists/pre-launch.md

For Specific Features

  • Combat System: 01-game-feel.md + 09-animation.md + code-templates/feedback-systems.lua
  • Shop/Store: 07-monetization.md + code-templates/remote-security.lua
  • Daily Rewards: 08-retention.md + code-templates/daily-rewards.lua
  • Multiplayer: 11-social-multiplayer.md + code-templates/matchmaking.lua

For Optimization

  • Performance issues: 13-testing.md + checklists/mobile-optimization.md
  • Retention issues: 02-player-psychology.md + 08-retention.md
  • Conversion issues: 07-monetization.md

For Troubleshooting (READ THIS FIRST!)

  • ANY stuck/loading issue: references/00-troubleshooting.md
  • "Loading..." never completes: DataStore not enabled in Studio!
  • Data not saving: Check BindToClose and PlayerRemoving handlers
  • RemoteEvent not firing: Check script locations and ReplicatedStorage

Critical Rules (Never Violate)

Security

lua
-- NEVER trust client data
RemoteEvent.OnServerEvent:Connect(function(player, itemName, price)
    -- BAD: Using client-provided price
    player.Cash.Value -= price  -- Exploiter sends price = 0
    
    -- GOOD: Server defines all values
    local serverPrice = Items[itemName].Price
    if player.Cash.Value >= serverPrice then
        player.Cash.Value -= serverPrice
    end
end)

Performance Targets

PlatformMemoryFrame TimeTarget FPS
Mobile<600MB<33ms30
Console<1.5GB<17ms60
PC<4GB<17ms60+

DataStore Safety

lua
-- ALWAYS wrap DataStore operations
local success, result = pcall(function()
    return dataStore:GetAsync(key)
end)
if not success then
    warn("DataStore error:", result)
    -- Implement retry with exponential backoff
end

Key Metrics to Track

MetricTargetHow to Improve
D1 Retention>25%Better onboarding, clearer goals
D7 Retention>10%Daily rewards, social features
D30 Retention>5%Long-term progression, events
Session Length>10minEngaging loops, friends features
ARPDAU$0.01-0.03Better monetization placement

Common Mistakes (Anti-Patterns)

  1. DataStore in Studio without enabling API Services - Causes infinite "Loading..." states
  2. Text wall tutorials - Players don't read; use visual guidance
  3. Linear tween everything - Use springs/easing for organic feel
  4. Client-side validation - All rewards/damage must be server-side
  5. Testing only in Studio - Always test on real mobile devices
  6. Ignoring mobile - 50%+ of players are mobile
  7. No sound design - Audio transforms perception of quality
  8. Aggressive monetization popups - Drives players away
  9. No analytics - Can't improve what you don't measure
  10. Resetting daily streaks harshly - Frustrates loyal players
  11. Flat, empty maps - Use verticality and POI triangles
  12. No timeout on async operations - Can hang forever

Version History

  • v1.0 - Initial comprehensive skill based on research of top Roblox games