This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <vector> | |
#include <algorithm> | |
#include <optional> | |
#include <stdexcept> | |
#include <utility> | |
template <typename T> | |
class Arena; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <variant> | |
namespace prpg::window_event | |
{ | |
struct PositionChanged | |
{ | |
const int xpos; | |
const int ypos; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <mutex> | |
#include <queue> | |
#include <optional> | |
namespace prpg | |
{ | |
template <class T> | |
class ConcurrentQueue | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright (c) 2021 Daniel Valcour | |
Permission is hereby granted, free of charge, to any person obtaining a copy of | |
this software and associated documentation files (the "Software"), to deal in | |
the Software without restriction, including without limitation the rights to | |
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of | |
the Software, and to permit persons to whom the Software is furnished to do so, | |
subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all | |
copies or substantial portions of the Software. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Journeyman's circle iteration algorithm - Public Domain | |
Does not use division or square roots! | |
Given: | |
Circle struct: | |
```c | |
typedef struct Circle | |
{ | |
/*! | |
* \brief The x position of the center of the circle. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TUI_ERROR_UNKNOWN | |
TUI_ERROR_ALREADY_INITIALIZED | |
TUI_ERROR_BACKEND_SPECIFIC | |
TUI_ERROR_DAMAGED_INSTANCE | |
TUI_ERROR_DANGLING_CURSOR | |
TUI_ERROR_DANGLING_GLYPH_ATLAS | |
TUI_ERROR_DANGLING_INSTANCE | |
TUI_ERROR_DANGLING_PALETTE | |
TUI_ERROR_DANGLING_PANEL | |
TUI_ERROR_DANGLING_TEXTURE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TUIC TASKS | |
new error TUI_ERROR_INSTANCE_DAMAGED | |
new error TUI_ERROR_INVALID_COLOR_COUNT | |
new error TUI_ERROR_NULL_COLORS | |
new error TUI_ERROR_INVALID_IMAGE_CHANNEL_COUNT | |
document all places where TUI_ERROR_BACKEND_SPECIFIC can be thrown | |
release 1.2 | |
for 1.3: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright (c) 2021 Daniel Valcour | |
Permission is hereby granted, free of charge, to any person obtaining a copy of | |
this software and associated documentation files (the "Software"), to deal in | |
the Software without restriction, including without limitation the rights to | |
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of | |
the Software, and to permit persons to whom the Software is furnished to do so, | |
subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <cmath> | |
#include <iostream> | |
int main() | |
{ | |
double a, b, c; | |
std::cout << "Quadratic formula solver.\nGive A:" << std::endl; | |
std::cin >> a; | |
std::cout << "Give B:" << std::endl; | |
std::cin >> b; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using System.Runtime.CompilerServices; | |
using UnityEngine; | |
[RequireComponent(typeof(MeshFilter))] | |
[RequireComponent(typeof(MeshRenderer))] | |
public class Chunk : MonoBehaviour | |
{ | |
public MeshFilter meshFilter {get; private set;} = null; |