MDC Panel+ is a multi-functional tool designed to assist roleplay communities' Law Enforcement Officers with their daily tasks. It provides a suite of tools, generators, and resources for official government use within a roleplaying context. The application is built with Next.js and Tailwind CSS, offering a modern, intuitive, and responsive user experience.
- Arrest Calculator: Calculate arrest sentences and fines based on charges from a comprehensive and up-to-date penal code.
- Arrest Report Generator: Create and manage both basic and advanced arrest reports, with functionality to pre-fill officer and charge details.
- Paperwork Generators: Dynamically generate various types of paperwork from predefined templates. Includes a form builder to create custom templates.
- Simplified Penal Code: An easy-to-navigate and searchable version of the official penal code.
- Caselaw & Legal Resources: Access a database of relevant caselaw and other essential legal resources.
- AI Legal Search: An experimental AI-powered search engine to query the penal code and caselaw.
- Interactive Map: A searchable map of San Andreas with drawing tools, markers, and snapshot functionality.
- Log Parser: A utility to filter GTA:World chat logs for specific character interactions.
- Report Archive: Automatically saves submitted arrest reports and paperwork for future restoration.
- Customizable Settings: Personalize your experience by setting default officer information, managing alternative characters, and controlling the visibility of faction-specific forms.
- Theming & Internationalization: Switch between light and dark modes and multiple languages (English and Spanish supported).
To get a local copy up and running, follow these simple steps.
- Node.js (v18.18.0 or higher)
- npm or yarn
- Docker and Docker Compose (for containerized setup)
- Clone the repo:
git clone https://github.com/b00skit/MDC-Panel-plus.git
- Navigate to the project directory:
cd MDC-Panel-plus - Install NPM packages:
npm install
- Create a
.envfile in the root of the project and add your environment variables:# Required for AI features GEMINI_API_KEY=your_google_ai_api_key_here # Optional: For logging errors and feedback to Discord DISCORD_LOGS_WEBHOOK_URL=your_error_webhook_url_here DISCORD_FEEDBACK_WEBHOOK_URL=your_feedback_webhook_url_here
For a containerized setup, you can use the provided Docker configuration to run the application.
-
Ensure you have Docker and Docker Compose installed on your system.
-
Make sure you have created the
.envfile as described in the installation steps above. -
Build and run the container using Docker Compose:
docker-compose up -d --build
-
The application will be available at http://localhost:3003.
-
To stop the application, run:
docker-compose down
In the project directory, you can run:
npm run dev: Runs the app in development mode. Open http://localhost:9002 to view it in the browser.npm run build: Builds the app for production to the.nextfolder.npm run start: Starts a Next.js production server.npm run lint: Runs ESLint to find and fix problems in your code.
This project is built with a modern tech stack to ensure a high-quality and maintainable application.
- Framework: Next.js
- Generative AI: Google AI & Genkit
- Styling: Tailwind CSS with
tailwindcss-animate - UI Components: shadcn/ui
- State Management: Zustand
- Form Handling: React Hook Form
- Mapping: Leaflet
- Icons: Lucide React
The application's core settings are managed through the data/config.json file. This includes the site name, version, descriptions, and feature flags like enabling the form builder.
The visual theme, colors, and layout are defined in tailwind.config.ts and src/app/globals.css, following the design principles outlined in the project's blueprint.
Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.