Action Game C Code
Prompt
Create comprehensive C code for a complex action game with the following requirements: - The game has 10,000 levels. - Level 1 contains 4 matches; each subsequent level has 2 additional matches than the previous. - Difficulty increases progressively with each level. - On the first game launch, display “Hello” once, then prompt the user to sign up; afterward, the greeting is shown each subsequent time. - Each match has teams of 4 to 12 players; players can customize team size. - The home page includes: - A left-side “Shop” button at the bottom offering purchasable items: characters, weapons, pets, shields, glue-walls, flying-boards, chemoflash-moods, teleportation — requiring 250+ diamonds or 5000+ gold coins. - 500+ characters with high-quality graphics (first two characters free: one male, one female). - Character customization accessible by clicking the character on the home page. - Inventory: - 5000+ guns, machine guns, sniper rifles - 200+ swords and knives - 50+ sticks and spears - 100+ grenades and missile launchers - 300+ animals (crocodiles, tigers, lions, cats, dogs) and birds (phoenix, fire-phoenix, eagle, hawk) as pets (smallest 1.5 feet tall) - 100+ shields and glue-walls - 100+ flying-boards - Settings option at top right of home page. - Player description displayed between settings and Play button at the bottom. - Clicking Play starts the game. - During gameplay: - A plane transports players who then jump with parachutes. - Players collect weapons after landing. - Two teams battle; winning team members earn 500 gold and 5 diamonds, rewards increase with level. - Player profile with diamonds and gold coin counts shown on the left. - Control panel includes: - Flying board option (right side) for flying. - Help option for teammates to heal injured players. - Central fire (one shot) button. - Shield and glue-wall option (left of fire). - Grenade (right of fire) and missile launcher option (right of grenade). - Large round button at bottom for cycling through weapons. - Small teleportation button at bottom left. - Mini-map shows red dots for teammates, blue dots for enemies. - Running, jumping, camouflage modes below the mini-map. - Joystick for movement directions. - Control panel customizable via Settings. - Maps: - Includes maps of all countries and cities worldwide. - Palestine map is free and used in the first matches. - Players can select cities, each city includes 10 matches. - Maps cost between 10,000 to 50,000 diamonds to unlock. - Each city name labeled with its country. - Offline play allows matches against AI. - Diamond purchase options: - 10 diamonds for $1 - 50 diamonds for $5 - 100 diamonds for $9 - 250 diamonds for $15 - Teammates can communicate via voice chat during matches. Deliver well-organized, modular C source code that implements the described game mechanics, user interface, and features. Include comments explaining key components and logic. Assume access to standard C libraries and common game development frameworks if necessary. Prioritize clarity, extensibility, and performance.
Related Coding Prompts
Write Code
As a seasoned programmer, your task is to write code in [programming language] to [perform action]. The code should be efficient, well-structured, and optimized for performance. Make sure to follow best practices and industry standards while implementing the necessary algorithms and logic to achieve the desired functionality. Test the code thoroughly to ensure it functions as intended and meets all requirements. Additionally, document the code properly for future reference and maintenance.
Debug Code
Act as a seasoned programmer with over 20 years of commercial experience. Analyze the provided [piece of code] that is causing a specific [error]. Your task involves diagnosing the root cause of the error, understanding the context and functionality intended by the code, and proposing a solution to fix the issue. Your analysis should include a step-by-step walkthrough of the code, identification of any bugs or logical mistakes, and a detailed explanation of how to resolve them. Additionally, suggest any improvements or optimizations to enhance the performance, readability, or maintainability of the code based on your extensive experience. Ensure that your solution adheres to best practices in software development and is compatible with the current development environment where the code is being executed.
Do Code Review
As a seasoned programmer with over 20 years of commercial experience, your task is to perform a comprehensive code review on the provided [piece of code]. Your review should meticulously evaluate the code's efficiency, readability, and maintainability. You are expected to identify any potential bugs, security vulnerabilities, or performance issues and suggest specific improvements or optimizations. Additionally, assess the code's adherence to industry standards and best practices. Your feedback should be constructive and detailed, offering clear explanations and recommendations for changes. Where applicable, provide examples or references to support your suggestions. Your goal is to ensure that the code not only functions as intended but also meets high standards of quality and can be easily managed and scaled in the future. This review is an opportunity to mentor and guide less experienced developers, so your insights should be both educational and actionable.