/cybrion

Cybrion - A voxel game written in C++ using SDL2 and modern OpenGL (Minecraft clone)

Primary LanguageC++MIT LicenseMIT

Cybrion

Cybrion

โJust a silly blocky gameโž โ€” @qninhdt

Cybrion preview

๐Ÿ’ก Features

  • Infinite, procedurally generated world
  • Multithreading for world generation
  • Beautiful and colorful world
  • Custom shape blocks (fence, chess, table)
  • Wide variety of flowers and trees
  • Save and load world using custom file type
  • Complex GUI (Block menu, inventory)

๐Ÿ”ง Building

Windows

Requirements

Don't forget to add CMake to environment variables

Installing libraries and compiling

  • Step 1: Open terminal and dowload source code
> git clone https://github.com/qninhdt/cybrion
  • Step 2: Install vcpkg and libraries
> cd cybrion
> build.bat
  • Step 3: Rerun build.bat to compile project
> build.bat

After compiling, executable files and resource files will be put in folder cybrion/build

To play game, you need to run cybrion.exe in that folder

Linux

Requirements

Installing libraries and compiling

  • Step 1: Dowload source code
$ git clone https://github.com/qninhdt/cybrion
  • Step 2: Run build.sh. It will install tools, libraries and compile automatically
$ cd cybrion
$ ./build.sh

Similar to Windows, build folder will be cybrion/build

๐Ÿ“ Project structure

โ”œโ”€โ”€ resources           # Game textures, shader files and config files
โ””โ”€โ”€ src                 # Source files
|   โ”œโ”€โ”€ client              # Everything that relates to rendering, window, controls          
|   |   โ”œโ”€โ”€ GL                  # OpenGL primitive elements (mesh, framebuffer, texture, ...)
|   |   โ”œโ”€โ”€ graphic             # Handle rendering for block, world, sky, ...
|   |   โ”œโ”€โ”€ resource            # Load config files, shader files and block textures
|   |   โ””โ”€โ”€ ui                  # Handle user interface (inventory, menu, text, ...)
|   โ”œโ”€โ”€ core                # Custom data structures and some useful classes
|   โ”œโ”€โ”€ physic              # Handle physic (AABB, ...)
|   โ”œโ”€โ”€ uitl                # Utility functions
|   โ”œโ”€โ”€ world               # Manage world components (block, chunk, entity, ...)
|   โ””โ”€โ”€ ...
โ””โ”€โ”€ ...

๐ŸŽฎ How to play

Hello world

  • Step 1: Enter the name of your world then click Create
  • Step 2: Click Play
  • Step 3: Enjoy the game ๐Ÿ—ฟ๐Ÿท

Controls

  • Left Click to break a block
  • Right Click to place a block
  • WASD to move around
  • Space to go up
  • Shift to go down
  • E to open block menu
  • Esc to pause game
  • Ctrl to move faster
  • F1 to hide GUI
  • F3 to open Debug tools