🦇Roguelike (Dungeon Template Library)

Overview

Roguelike (Dungeon Template Library) BSL-1.0


Supported Compilers 🔧

Compiler Run
MSVC None
GCC Wandbox
Clang Wandbox

Generated Image 🖼️

rl1 rl2


Example

#include int main() { using shape_t = int; std::array , 24> matrix{ {} }; dtl::shape::RogueLike (0, 1, 2, 3, 4, 20, dtl::base::MatrixRange(3, 3, 2, 2), dtl::base::MatrixRange(3, 3, 4, 4)).draw(matrix); for (const auto& i : matrix) { for (const auto& j : i) std::cout << j << ','; std::cout << '\n'; } for (const auto& i : matrix) { for (const auto& j : i) switch (j) { case 0:std::cout << "%%"; break; case 1:std::cout << "##"; break; case 2:std::cout << " "; break; case 3:std::cout << "++"; break; case 4:std::cout << "--"; break; } std::cout << '\n'; } return 0; }">
#include "RogueLike.hpp"
#include <array>
#include <iostream>

int main() {

	using shape_t = int;
	std::array
       <
       shape_t, 
       32>, 
       24> matrix{ {} };

	dtl::shape::RogueLike<
       shape_t>(
       0, 
       1, 
       2, 
       3, 
       4, 
       20,
		
       dtl::base::MatrixRange(
       3, 
       3, 
       2, 
       2),
		
       dtl::base::MatrixRange(
       3, 
       3, 
       4, 
       4)).
       draw(matrix);

	
       for (
       const 
       auto& i : matrix) {
		
       for (
       const 
       auto& j : i)
			std::cout << j << 
       ',';
		std::cout << 
       '\n';
	}

	
       for (
       const 
       auto& i : matrix) {
		
       for (
       const 
       auto& j : i)
			
       switch (j) {
			
       case 
       0:std::cout << 
       "%%"; 
       break;
			
       case 
       1:std::cout << 
       "##"; 
       break;
			
       case 
       2:std::cout << 
       "  "; 
       break;
			
       case 
       3:std::cout << 
       "++"; 
       break;
			
       case 
       4:std::cout << 
       "--"; 
       break;
			}
		std::cout << 
       '\n';
	}

	
       return 
       0;
}
      
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,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0,0,1,4,4,4,1,0,0,0,0,
0,0,1,4,1,0,0,0,0,1,4,4,4,4,4,4,1,0,1,4,1,1,1,1,1,1,3,1,1,0,0,0,
0,0,1,4,1,0,0,0,0,1,1,1,1,1,1,4,1,0,1,1,1,4,4,4,3,2,2,2,1,0,0,0,
0,0,1,1,1,0,0,0,0,0,0,1,4,4,4,4,1,0,0,0,1,1,1,4,1,2,2,2,1,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,1,1,1,4,1,1,1,1,0,1,4,4,4,1,2,2,2,1,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,1,4,4,4,4,1,0,1,1,1,1,1,2,2,2,1,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,0,0,0,
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%############%%%%######%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%##        ##%%%%##--######%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%##        ##%%%%##------##%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%##        ##%%%%##--##--##%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%##########++####%%%%##--##--##%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%##----------##%%%%%%##--######%%%%%%%%%%%%
%%######################++##########%%%%%%##++########%%%%%%%%%%
%%##------------++        ##%%%%%%%%%%%%%%##        ##%%%%%%%%%%
########--########        ############%%%%##        ##%%%%%%%%%%
##--------##%%%%##        ####      ########        ##%%%%%%%%%%
######--####%%%%######++######      ++--########++####%%%%%%%%%%
%%%%##--##%%%%%%##----------++      ##------------##%%%%%%%%%%%%
%%%%##--##%%%%%%##############      ##--########--######%%%%%%%%
%%%%##--##%%%%%%%%############++######--##%%%%##------##%%%%%%%%
%%%%##--##%%%%%%%%##------------##%%##--############++####%%%%%%
%%%%##--##%%%%%%%%############--##%%######------++      ##%%%%%%
%%%%######%%%%%%%%%%%%##--------##%%%%%%######--##      ##%%%%%%
%%%%%%%%%%%%%%%%%%%%%%######--########%%##------##      ##%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%##--------##%%##########      ##%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%############%%%%%%%%%%##########%%%%%%

License 💳

>> View License 💳

Copyright (c) 2017-2019 AsPJT. Copyright (c) 2018-2019 As Project.

Distributed under the Boost Software License, Version 1.0.(See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)


Related Items 🎮

DTL GenkaiSyuraku AsLib

You might also like...
Import of the DIY Dynamic Template v2, retrieved from the Internet Archive
Import of the DIY Dynamic Template v2, retrieved from the Internet Archive

Dynamic Templates This is a copy of the D*I*Y Planner Dynamic Template application that was posted to diyplanner.com/node/6210 back in 2009,

Some hypervisor research notes. There is also a useful exploit template that you can use to verify / falsify any assumptions you may make while auditing code, and for exploit development.

Introduction Over the past few weeks, I've been doing some hypervisor research here and there, with most of my focus being on PCI device emulation cod

Simple template project to build a firmware for the STM32F4 Discovery board with FreeRTOS and libopencm3

STM32F4 Discovery FreeRTOS Makfile This is a simple template project to build a firmware for the STM32F4 Discovery board with FreeRTOS and libopencm3

Bubbles: simple and expandable c++ project template with googletest and boost included

Bubbles: A simple and expandable C++ project template with Googletest and Boost included. Building && Testing cmake -S . -B build cmake --build build

An MDK template for Raspberry Pi Pico

Pico_Template (v1.0.0) An MDK template for Raspberry Pi Pico Compiler: Arm Compiler 6.15 and above (Using non-intrusive wrapper to support pico-sdk wh

Basic template for ST7789 driver and esp32.

LVGL TEMPLATE Basic template for ST7789 driver and esp32. About ESP32 board: ESP32-WROVER flash size: 16MB esp-idf: v4.4 About LCD TFT LCD driver: ST7

A template for creating new MOLA modules

mola-foo Write me! Provided MOLA modules: Foo, type Foo. Build and install Refer to the root MOLA repository. Docs and examples See this package page

A template for experimenting with JUCE's hosting code

juce-wrapper This is a JUCE based plug-in that loads and wraps a single VST, VST3, or AU plug-in (in this case an instrument plug-in, which requires M

A D++ Discord Bot template for Visual Studio 2019 (x64 and x86)

D++ Windows Bot Template A D++ Discord Bot template for Visual Studio 2019 (x64 and x86, release and debug). The result of this tutorial. This templat

Owner
As Project
As Project
OpenGL Template Engine - a C++ OpenGL graphics engine which aimed to be a simple startup template for 3D OpenGL projects.

OpenGL Template Engine is a C++ OpenGL graphics engine which aimed to be a simple startup template for 3D OpenGL projects. This is the template I personally use for my own projects and provides me with the general OpenGL 3D render setup with model import and UI.

Marcus Nesse Madland 2 May 16, 2022
Parsing Expression Grammar Template Library

Welcome to the PEGTL The Parsing Expression Grammar Template Library (PEGTL) is a zero-dependency C++ header-only parser combinator library for creati

The Art of C++ 1.6k Sep 29, 2022
First open source android modding library for Geometry Dash Based on Hooking-and-Patching-android-template

Android-ML First open source android modding library for Geometry Dash Based on Hooking-and-Patching-android-template Installation Download this githu

BlackTea ML 21 Jul 17, 2022
free template opensource with minimal depends library flutter & dart

Project Name Sosial Media Donate ID: Jika Anda Menyukai karya saya dan ingin memberikan dana untuk saya membeli beberapa snack silahkan donasi seberap

Azka Full Snack Developer:) 33 Jan 1, 2022
Template library and blog that explain how JSI modules are built from scratch in React Native

react-native-jsi-template This is an example library that explains how anyone can build jsi modules from scratch in React Native. This code is written

Ammar Ahmed 124 Oct 2, 2022
C language simulation CXX template library

lib.xtl This is the implementation of a C language imitation cxx template library Explain This library simulates some operations in STL. Simulation ve

libxanadu 1 Jan 8, 2022
BNFLite is a C++ template library for lightweight flexible grammar parsers

BNFLite is a C++ template library for lightweight flexible grammar parsers. BNFLite offers creative approach when the developer can specify a language for further parsing directly in the C++ code. Moreover, such "specifications" are executable now!

Alexander S 61 Aug 18, 2022
Xtl - eXtended Template Library

eXtended Template Library Open Hub Linux Windows Coverage Technical Debt Code Quality License Contribute with Gratipay Contribute with Beerpay View th

David Mott 4 Sep 26, 2022
Generic Math Template Library

Generic Math Template Library

IMVU, Inc 19 Jul 29, 2022
C++ template library for linear algebra

SNUV_TOMO: 2D CT using SNUV with IRCD Project tree and description File/folder Description Eigen C++ template library for linear algebra include Conta

null 2 Jan 23, 2022