Skip to content

garrettmichae1/PlayNotNPC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

80 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Real-Life XP Tracker Level up your life. Track habits, earn XP, and make progress feel like a game. Fully functional planner/calendar, diary, level/achievement system, and social features like adding friends. Decently documented easy to extend.

Table of Contents

  • What Is This?
  • Key Features
  • Tech Stack
  • Folder Breakdown
  • How to Run It Locally
  • Environment Setup
  • Deploying It
  • Security Stuff
  • Tweak It Your Way
  • Contributing
  • License

What Is This? PlayNotNPC is a full-stack habit and productivity tracker that turns your real life actions into XP. Whether you're working out, studying, or just staying consistent.

Key Features

  • Login/Register - JWT-based auth.
  • Activity Logging — Track anything: workouts, study time, deep work, etc.
  • XP System — XP scales with effort, levels up over time, and carries over.
  • Achievements — Milestones, streaks, and special unlocks.
  • Dashboard — Stats, streaks, and progress analytics.
  • Friends & Challenges — Add friends, compete, and climb leaderboards.
  • Mobile-First — Responsive UI, PWA support, works offline.
  • Stripe Tips — Optional tippin.
  • Security — CORS, rate limiting, input validation, secure headers.
  • Modular Codebase — Easy to maintain and extend.

Tech Stack

  • Backend: Node.js + Express + MongoDB (Atlas)
  • Frontend: HTML/CSS + Vanilla JS (modular, no frameworks)
  • Environment configs, health checks, error handling
  • Service worker, manifest, installable app

How to Run It Locally git clone https://github.com/garrettmichae1/playnotnpc.git cd playnotnpc npm install npm start

Environment Setup Create a .env file in the root with: NODE_ENV=development PORT=5000 MONGODB_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret APP_URL=https://playnotnpc.com STRIPE_SECRET_KEY=your_stripe_secret_key

Deploying It I used Render.com

  • Hook up your GitHub repo
  • Add your env vars
  • Use npm start as the start command

Security

  • JWT for auth

  • CORS locked down in production

  • Rate limiting (add express-rate-limit)

  • Input validation on all endpoints

  • HTTPS enforced (via platform or proxy)

  • Centralized error handling

  • Secrets stored in env vars

  • Theme: Edit styles.css for colors and branding

  • Achievements: Customize logic in modules/achievements.js

  • XP System: Adjust XP rules in modules/xpManager.js

  • New Activities: Add types in modules/tracker.js and backend routes

  • PWA: Update manifest.json and sw.js for icons and offline behavior

Contributing If you want to help out:

  • Fork the repo and make a new branch
  • Keep your code clean and commented
  • Add tests if needed
  • Submit a pull request with a clear description

License MIT. Do what you want.

Contact: Questions, ideas, or business stuff = garrettiswoodside@gmail.com

About

full stack js application with express.js, node.js, and a mongo db

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published