storm-tournament

byBRAZIL

Main Prompt: Tournament App Generation You are an expert full-stack developer. Your task is to generate a fully working mobile-first Tournament Web App called "Adept Play, using ONLY the following technologies: HTML Tailwind CSS JavaScript (for basic UI/UX only, NO AJAX) PHP MySQL DB Font Awesome (only for icons) NO external frameworks like React, Vue, Laravel, Bootstrap, jQuery, or AJAX should be used. All actions should be handled through traditional PHP form submissions and page reloads. The design should resemble a real mobile application user-friend Ly, responsive, and clean UI. All text selection, right-click, and zoom in/out must be disabled using JavaScript. ## APP STRUCTURE OVERVIEW: Root Folder соmmоn header.php bottom.php config.php admin login.php index.php tournament.php manage tournament.php user.php setting.php common header.php bottom.php login.php index.php my tournaments.php wallet.php profile.php install.php L.htaccess (optional) ##COMMON INCLUSIONS (User & Admin Panel) config.php one centralized DB connection (host: 127.0.0.1, user: root, pass: root) "header.php contains the top navigation, logo, and user\"s wallet balance. bottom.php Wallet, Profile). fixed bottom navigation with icons (Home, My Tournaments, All UI components must use Tailwind classes only, and Font Awesome for icons. Use a modern dark theme. ##USER PANEL Pages Design & Functionality ### 1. login.php Design: Two tabs Login and Sign Up in the same file. Fields: Username, Password Username, Email, Password (for signup). Use standard PHP form submission. Show errors/success messages on the same nage after reload. On success, redirect to index.php. ### 2. index.php (Homepage) Display a list of all \"Upcoming tournaments in a card grid format Card: Tournament Title, Game Name, Match Time, Entry Fee, Prize Pool. Each card must have a "Join Now button inside a <form> tag. Clicking "Join Now" should submit the form to the same page ("index.php"). The PHP logic at the top of the file will handle the joining process: check balance, deduct fee, and add user to participants. Show a success/error message after the page reloads. ### 3. mv_tournaments.php Use a two-tab layout: **\"Upcoming/Live\" tab: Shows tournaments the user has joined that are not yet completed. If a tournament is live, it should display the "Room ID and Password** **\"Completed\" tab: Shows ws a history of all tournaments the user has played, along with their results (e.g., \"Winner\", \"Participated\"). ### 4. wallet.php Display current wallet balance in a large, prominent card. Show a transaction history list. Include "Add Money" and "Withdraw" buttons (dummy buttons). ### 5. profile.php Show and Edit: Username, Email. Change password section. Logout button. ## ADMIN PANEL Pages Design & Functions www 1. login.php Simple, secure login page for the admin using a standard PHP form. Fields: Username & Password. ### 2. Index.php (Admin Dashboard) Mobile-app style Admin Dashboard with clean, modern UI. Show quick stats using small Tailwind grid cards: Total Users, Total Tournaments, Total Prize Distributed, Total Revenue (Commission). Include a quick-action button: "Create New Tournament\". ### 3. tournament.php A standard PHP form to add a new tournament. Fields: Title, Game Name, Entry Fee, Prize Pool, Match Time, Commission Percentage (e.g., 20%). On submission, the page reloads and shows a success/error message. Below the form, show a list of all created tournaments with options to Edit/Delete (leading to other pages or handled with GET/POST requests). ### 4. manage_tournament.php This is the core management page for a single tournament. Display a list of all users who have 301ned. A form to enter/update the Room ID" and "Room Password**. A form with a dropdown menu of all participants to select the winner. A button "Declare Winner & Distribute Prize\". when the form is submitted, the PHP logic will: 1. Add the prize pool amount to the winner\"s wallet. 2. Change the tournament status to \\\\\\\'Completed\\\\\\\ 3. Show a success message after the page reloads. ### 5. user.php List all registered users with their current wallet balance. Option to view a user\'s match history or block the user. ### 6. setting.php Update admin info/password using a standard PHP form. #FEATURES TO IMPLEMENT: All actions are handled by traditional PHP form submissions (POST/GET). "install.php" must: Create the database and all required tables. Insert default admin credentials (admin/admin123). Redirect to Login.php after successful installation. ## DATABASE SCHEMA (Install File Should Auto-Create) "admin" (id, username, password) "users" (id, username, email, password, wallet balance, created_at) tournaments (id, title, game name, entry_fee, prize_pool, match_time, room_id, room password, status, created_at] participants (id, user id, tournament_id) transactions (id, user id, amount, type, description, created at) (type: \\\\\\\"credit\\\\\\\' or \\\\\\\'debit\\\\\\\ #SECURITY & USER EXPERIENCE Disable right-click, text selection, and zoom using 35. Use overflow-hidden", select-none", and custom 15 for a native app feel. Validate all forms on the server-side (۲۱۲). Use PHP sessions for login tracking. Use prepared statements in PHP to prevent SQL injection. Clean redirects on login/logout. Consistent dark theme, color scheme, and typography across the app. (ALL pricing/wallet values should be displayed in Indian Rupees (1) format. Your output should be a complete ready-to-run project, structured into pages and folders.) ##FINAL DELIVERABLE: Generate all required code files and folders as described above. For each File, clearly mention: The Filename The folder/directory where it should be saved The complete source code/content of the file All PHP files with integrated logic. The complete SOL schema inside install.php The project should be a single folder, ready to be uploaded and run on a Localhost or hosting server.

LandingLoginAdmin Login
Landing

Comments (0)

No comments yet. Be the first!

System Requirements

System Requirement Document
Page 1 of 6

System Requirements Document (SRD)

DEVIL ESPORTS

1. Introduction

DEVIL ESPORTS is a mobile-first tournament web application designed to provide a seamless and secure platform for hosting and participating in esports tournaments. The application caters to both users and administrators, offering features such as tournament management, wallet systems, referral programs, and advanced security measures. With the integration of payment gateways and fraud detection mechanisms, DEVIL ESPORTS ensures a professional and trustworthy experience for its users.

This document outlines the updated requirements to incorporate advanced systems, including payment gateways, referral systems, enhanced security features, and expanded admin panel controls, into the existing application.

Page 2 of 6

2. System Overview

DEVIL ESPORTS is a responsive web application built using the following technologies:

  • Frontend: HTML, Tailwind CSS, JavaScript (basic UI/UX only)
  • Backend: PHP
  • Database: MySQL
  • Icons: Font Awesome

The application is structured to provide a mobile-app-like experience with a consistent dark theme. All actions are handled through traditional PHP form submissions and page reloads, ensuring simplicity and reliability. The new features will enhance the app's functionality, focusing on secure payments, referral rewards, and fraud prevention.

3. Functional Requirements

Payment Gateway System

  • As a User, I should be able to recharge my wallet using Razorpay with UPI, QR code, and card payment options.
  • As a User, I should receive auto coin credits after successful payments.
  • As a User, I should see a transaction history of all my payments and wallet activities.
  • As a User, I should be able to submit UTR/Transaction IDs for manual payment verification.
  • As an Admin, I should be able to approve/reject manual payment submissions.
  • As an Admin, I should be able to change the QR code for payments anytime.
  • As an Admin, I should be able to enable/disable specific payment methods.
  • As a System, I should securely validate all payments and handle success/failure scenarios.
Page 3 of 6

Referral & Refer Code System

  • As a User, I should have a unique referral code to invite friends.
  • As a User, I should earn coins when my referred friend signs up.
  • As a User, I should earn extra rewards when my referred friend makes their first payment.
  • As a User, I should see a referral history screen showing all rewards earned.
  • As a User, I should see a referral leaderboard to compare my performance with others.
  • As a System, I should automatically distribute referral rewards.
  • As a System, I should prevent fake referrals by limiting one referral per device.
  • As a System, I should detect duplicate IPs/accounts and flag them for review.

Security Features

  • As a System, I should use JWT authentication for secure API requests.
  • As a System, I should encrypt all API requests to prevent tampering.
  • As a User, I should verify my account using OTP during signup or sensitive actions.
  • As an Admin, I should have 2FA enabled for secure login.
  • As a System, I should detect and prevent fake payment attempts.
  • As a System, I should prevent duplicate transaction IDs from being processed.
  • As a System, I should detect suspicious activity and flag or ban accounts.
  • As an Admin, I should be able to ban devices or accounts flagged for fraud.

Admin Panel Controls

  • As an Admin, I should be able to manage all payments, including viewing logs and approving/rejecting transactions.
  • As an Admin, I should be able to manage referral rewards and adjust reward amounts.
  • As an Admin, I should be able to view and analyze revenue and transaction statistics.
  • As an Admin, I should be able to monitor fraud reports and take appropriate actions.
  • As an Admin, I should be able to manage user wallets, including adding or deducting coins manually.
Page 4 of 6

4. User Personas

  1. User: Regular players who participate in tournaments, recharge wallets, and earn rewards through referrals.
  2. Admin: Platform managers responsible for overseeing tournaments, payments, referrals, and security.

5. Visuals Colors and Theme

Color Palette

  • primary: #1A1F36 (Deep Navy Blue)
  • primary_light: #2C3550 (Muted Navy Blue)
  • secondary: #FF6F61 (Coral Red)
  • accent: #FFD700 (Gold)
  • highlight: #FFA500 (Amber)
  • bg: #121212 (Dark Gray)
  • surface: rgba(18, 18, 18, 0.95) (Semi-transparent Dark Gray)
  • text: #FFFFFF (White)
  • text_muted: #B0B0B0 (Muted Gray)
  • border: rgba(255, 255, 255, 0.2) (Subtle White)
Page 5 of 6

6. Signature Design Concept

Interactive Tournament Dashboard with Dynamic Animations

The homepage will feature an interactive tournament dashboard where users can explore tournaments through a scrollable 3D carousel. Each tournament card will "flip" on hover, revealing details like prize pool, entry fee, and match time. The carousel will use @react-three/fiber for 3D rendering and framer-motion for smooth animations.

Key features:

  • Dynamic Glow Effects: Tournament cards will emit a soft glow (matching the primary color) when hovered.
  • Interactive Wallet Display: The wallet balance will animate with a "coin drop" effect whenever coins are added.
  • Referral Leaderboard Animation: The leaderboard will feature a "rising star" animation for top users, with their avatars glowing gold.

7. Interaction Model & Motion Direction

  • Landing Page: Parallax interaction with layered depth effects for a visually rich first impression.
  • Internal Pages: Animated interaction with hover transitions and spring physics for buttons and cards.
  • Admin Panel: Static layout with minimal motion for clarity and efficiency.

8. Non-Functional Requirements

  • The system must handle at least 10,000 concurrent users.
  • Payment processing must complete within 3 seconds.
  • Referral rewards must be distributed within 1 second of qualifying actions.
  • Fraud detection algorithms must flag suspicious activity within 500ms.
Page 6 of 6

9. Tech Stack

  • Frontend: HTML, Tailwind CSS, JavaScript
  • Backend: PHP
  • Database: MySQL
  • Payment Gateway: Razorpay
  • Authentication: Firebase (OTP), JWT
  • Libraries: framer-motion, @react-three/fiber (for animations)

10. Assumptions and Constraints

  • All monetary values will be displayed in Indian Rupees (₹).
  • The system assumes users have stable internet connections for payment processing.
  • Admin actions (e.g., banning users) are final and irreversible.

11. Glossary

  • JWT: JSON Web Token, used for secure authentication.
  • UPI: Unified Payments Interface, a real-time payment system in India.
  • UTR: Unique Transaction Reference, used for payment tracking.
  • 2FA: Two-Factor Authentication, an additional security layer.
Landing design preview
Admin Login: Authenticate
Admin Login: Verify 2FA
Dashboard: View Stats
Tournaments: Create Tournament
Tournaments: Manage Tournament
Manage Tournament: Set Room Credentials
Manage Tournament: Declare Winner
Payments: View Logs
Payments: Approve Payment
Payments: Reject Payment
Payments: Change QR Code
Payments: Toggle Payment Methods
Users: View All Users
Users: Manage Wallet
Users: Ban Account
Referrals: Manage Rewards
Referrals: Adjust Reward Amounts
Fraud Monitor: View Reports
Fraud Monitor: Ban Device
Analytics: View Revenue
Settings: Update Admin Info