https://github.com/blueokiris/x-craft
Craft your dream 2D gaming experiences with the X-Craft engine.
https://github.com/blueokiris/x-craft
2d cpp craft engine game source x
Last synced: over 1 year ago
JSON representation
Craft your dream 2D gaming experiences with the X-Craft engine.
- Host: GitHub
- URL: https://github.com/blueokiris/x-craft
- Owner: blueOkiris
- License: gpl-3.0
- Created: 2023-12-20T21:20:43.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-03T17:55:32.000Z (over 2 years ago)
- Last Synced: 2025-01-31T22:49:04.550Z (over 1 year ago)
- Topics: 2d, cpp, craft, engine, game, source, x
- Language: C++
- Homepage:
- Size: 2.88 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# X-Craft
## Description
Craft your dream 2D gaming experiences with the X-Craft engine.
Semi-inspired by the systems of the GameMaker engine but fully source-code based (C++), the X-Craft engine hopes to be the ideal engine for indie game devs coming from a programming background.
No longer do you need to figure out how to integrate your abstractions in your engine of choice; build them in regular code and integrate it with the engine by default!
## Building a Game
Requirements:
- SDL, SDL_image, SDL_ttf, and SDL_mixer
- gcc
- make
- Probably Linux system
+ May work on other \*nix or even Windows/Mac if set up correctly
+ Only Linux systems are officially supported tho
Nix users can create a valid shell via `nix-shell`
1. Fork project. You're probably not going to touch the things in the `(src|include)/engine/` folders, but you will mess with everything else
2. Add your images and audio to the proper folders
3. Load your images and audio into the proper global hashmaps a la examples in `main.cpp`
4. Create your custom GameObjects in the `(src|include)/gameobjs/` folders to define behavior for your game (see `Player.h/cpp` and `Brick.h/cpp` for examples)
- This is also where you define sprites for animation frames
5. Create rooms to hold instances of GameObjects in the `(src|include)/rooms/` folders (see `Room0.h/cpp` for examples)
6. Replace `x-craft` with the name of your game in the `Makefile` and in `src/engine/globals.cpp`
7. Run `make` to build your binary
Check out the `x-snake` branch for an example of how to make a game in the engine.