Published 4/2024
https://www.udemy.com/course/alien-farm-game-cpp-sdl2-from-scratch/
You can construct paths and waterways, plant alien crops and trees, and colorful animals that move.
What you'll learn
Create a farm game with an alien theme
A tiling system that allows you to place dirt, water which makes surrounding dirt wet, and different colored "grass"
Plants of different types and sizes that have shadows, move up and down, start small and grow, and can only exist on the correct types of tiles
Animals of different types and sizes that have shadows, start small and grow, move around without overlapping plants, other animals, the wrong types of tiles
Improve your C++ game development skills
Requirements
Basic C++ programming skills
Basic understanding of game development
Windows 7 or newer OR if you use a different OS (eg. macOS) you must have a C++ compiler and SDL2 already installed. This is because the instructions to download and setup this software are only provided for windows.
Description
OverviewYou’ll be able to place dirt, water which makes surrounding dirt wet, and different colored grass. Add and remove plants of different types and sizes that have shadows, move up and down, start small and grow, and can only exist on the correct types of tiles. Add and remove animals of different types and sizes that have shadows, start small and grow, move around, and avoid overlapping plants, other animals, and certain tiles like water.Tiling SystemStart by adding a simple purple checkered grid to get the basics setup.Then it will be improved by adding a tiling system that allows placement of different colored tiles.Next an algorithm that automatically generates shadows, to give a sense of depth, will be added to the game.Finally when water tiles are added or removed, the surrounding dirt tiles become wet or dry depending on how far away they are from water.PlantsStart by setting up simple plants that can be added and removed with the mouse and keyboard.Then they will be improved so that they look like they’re moving up and down, and start small then grow to their full size.Next more plants/trees of different sizes will get added to the game, and their shadows improved to be lighter and remove overlap with other images.Finally an algorithm will be added that checks tile types underneath them. That way they can only get placed on the correct ones, and if tiles are changed to types that they shouldn’t exist on, they get removed.AnimalsStart by setting up simple animals that can be added with the mouse and keyboard, that start small then grow to their full size.Then they will be improved so that sometimes they either pick random points to move to, or random angles to rotate to.Next their movement will be improved further so that they avoid overlapping other animals, plants, and tile types that they shouldn’t exist on, for example water.Finally more overlap checks will be added so that animals can no longer be placed on plants, other animals, or the wrong types of tiles. Also an overlap check so that plants can’t be placed on animals. In addition code will be added so that animals can be remove with the mouse, or if the tiles under them are changed to types they shouldn’t exist on.
TO MAC USERS: If RAR password doesn't work, use this archive program:
RAR Expander 0.8.5 Beta 4 and extract password protected files without error.
TO WIN USERS: If RAR password doesn't work, use this archive program:
Latest Winrar and extract password protected files without error.