Skip to content

Instantly share code, notes, and snippets.

View wallstop's full-sized avatar
🎯
Focusing

Eli Pinkerton wallstop

🎯
Focusing
View GitHub Profile
namespace Editor.Networking
{
using System.Collections.Generic;
using Core.Helper;
using global::Networking;
using Unity.Netcode;
using UnityEditor;
using UnityEngine;
[CustomEditor(typeof(CollectAllNetworkPrefabs))]
@wallstop
wallstop / QuadTree.cs
Created March 15, 2022 01:57
QuadTree
namespace Core.DataStructure
{
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using Extension;
using UnityEngine;
public sealed class QuadTree<T>
@wallstop
wallstop / PathNode.cs
Created March 15, 2022 01:46
PathNode
namespace Pathfinding
{
using UnityEngine;
public sealed class PathNode
{
public readonly Vector3Int position;
public int gCost = int.MaxValue;
public int hCost = 0;
@wallstop
wallstop / TimedCache.cs
Created March 15, 2022 01:12
TimedCache
namespace Core.DataStructure
{
using System;
using Helper;
using Random;
using UnityEngine;
public sealed class TimedCache<T>
{
public T Value
namespace Core.Attributes
{
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
[AttributeUsage(AttributeTargets.Field)]
public sealed class ValidateAssignmentAttribute : Attribute
@wallstop
wallstop / Vector3Converter.cs
Created November 11, 2020 02:16
Vector3Converter
using System;
using Assets.Scripts.Core.Extension;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using UnityEngine;
namespace Assets.Scripts.Core.Serialization.JsonConverters
{
public sealed class Vector3Converter : JsonConverter
{
@wallstop
wallstop / Vector2Converter.cs
Created November 11, 2020 02:15
Vector2Converter
using System;
using Assets.Scripts.Core.Extension;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using UnityEngine;
namespace Assets.Scripts.Core.Serialization.JsonConverters
{
public sealed class Vector2Converter : JsonConverter
{
@wallstop
wallstop / Serializer.cs
Created November 11, 2020 02:14
Serializer
using Assets.Scripts.Core.Extension;
using Assets.Scripts.Core.Serialization.JsonConverters;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.IO;
using System.Runtime.Serialization.Formatters.Binary;
using System.Text;
namespace Assets.Scripts.Core.Serialization
{
@wallstop
wallstop / Serializer.cs
Created November 11, 2020 02:13
Serializer
using Assets.Scripts.Core.Extension;
using Assets.Scripts.Core.Serialization.JsonConverters;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.IO;
using System.Runtime.Serialization.Formatters.Binary;
using System.Text;
namespace Assets.Scripts.Core.Serialization
{
@wallstop
wallstop / StringExtensions.cs
Created November 11, 2020 02:12
StringExtensions
using System;
using Assets.Scripts.Core.Serialization;
namespace Assets.Scripts.Core.Extension
{
public static class StringExtensions
{
public static string Center(this string input, int length)
{
if (input == null || length <= input.Length)