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 | |
| // | |
| // Magic Ring Buffer | |
| // https://gist.github.com/mmozeiko/3b09a340f3c53e5eaed699a1aea95250 | |
| // | |
| // Sets up memory mapping so the same memory block follows itself in virtual address space: | |
| // | |
| // [abcd...xyz][abc...xyz] | |
| // |
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; | |
| using UnityEngine; | |
| using UnityEngine.Tilemaps; | |
| using Random = UnityEngine.Random; | |
| public class PlayerAnimator : MonoBehaviour { | |
| [SerializeField] private float _minImpactForce = 20; | |
| // Anim times can be gathered from the state itself, but | |
| // for the simplicity of the video... |
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.Generic; | |
| using UnityEngine; | |
| using UnityEngine.Sprites; | |
| using UnityEngine.UI; | |
| #if UNITY_2017_4 || UNITY_2018_2_OR_NEWER | |
| using UnityEngine.U2D; | |
| #endif | |
| #if UNITY_EDITOR | |
| using UnityEditor; |
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
| $userPath = $env:USERPROFILE | |
| $pathExclusions = New-Object System.Collections.ArrayList | |
| $processExclusions = New-Object System.Collections.ArrayList | |
| $pathExclusions.Add('C:\Windows\Microsoft.NET') > $null | |
| $pathExclusions.Add('C:\Windows\assembly') > $null | |
| $pathExclusions.Add($userPath + '\Downloads\HeidiSQL_11.3_64_Portable') > $null | |
| $pathExclusions.Add($userPath + '\.dotnet') > $null |
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 BovineLabs.Entities.Systems; | |
| using Unity.Burst; | |
| using Unity.Entities; | |
| using Unity.Jobs; | |
| using Unity.Collections; | |
| using Unity.Physics; | |
| using Unity.Physics.Systems; | |
| using UnityEngine; | |
| [UpdateAfter(typeof(BuildPhysicsWorld)), UpdateBefore(typeof(EndFramePhysicsSystem))] |
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
| // --- Library -------------------------------------------------------------------------- | |
| #include <string.h> | |
| #include <assert.h> | |
| struct ui_box {int x,y,w,h;}; | |
| typedef unsigned long long ui_id; | |
| struct ui_node { | |
| int parent; | |
| int lst, end, nxt; | |
| int siz[2]; |
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) 2022 Piero Dotti, Elf Games | |
| // | |
| // 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: |
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 UnityEngine; | |
| public static class GameObjectExtensions { | |
| /// <summary> | |
| /// Returns the full hierarchy name of the game object. | |
| /// </summary> | |
| /// <param name="go">The game object.</param> | |
| public static string GetFullName (this GameObject go) { | |
| string name = go.name; |