Skip to content

Instantly share code, notes, and snippets.

View aprius's full-sized avatar
⛱️
Nếu như lần đầu gặp mặt Ai sẽ vì ai mà quay đầu

Aprius aprius

⛱️
Nếu như lần đầu gặp mặt Ai sẽ vì ai mà quay đầu
View GitHub Profile
@aprius
aprius / TrafficLightAttribute.cs
Created June 13, 2019 09:53 — forked from LotteMakesStuff/TrafficLightAttribute.cs
TrafficLight control/layout/property drawer: Adds a new editor control that draws lil Traffic Lights in the inspector. its really useful for visualizing state. For example, checkboxes can be hard to read at a glace, but a Red or Green status light is easy! Recommend you use the attached package, as it has all the icon image files.
// Non Editor code
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public abstract class TrafficLightAttribute : PropertyAttribute
{
public bool DrawLabel = true;
public string CustomLabel;
public bool AlsoDrawDefault;
@aprius
aprius / introrx.md
Created June 13, 2019 15:33 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@aprius
aprius / LazyUniTask.cs
Last active December 2, 2022 02:15 — forked from yKimisaki/LazyUniTask.cs
add method extend for IResourceLocation
#if CSHARP_7_OR_LATER
#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member
using System;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.ResourceManagement.ResourceLocations;
using UnityEngine.ResourceManagement.ResourceProviders;
using UnityEngine.SceneManagement;
@aprius
aprius / update_git_repos.sh
Last active November 27, 2019 15:52 — forked from douglas/update_git_repos.sh
Update all git repositories under a base directory
#!/bin/bash
# store the current dir
CUR_DIR=$(pwd)
# Let the person running the script know what's going on.
echo "Pulling in latest changes for all repositories..."
# Find all git repositories and update it to the master latest revision
for i in $(find . -name ".git" | cut -c 3-); do
@aprius
aprius / EasingFunctions.cs
Last active October 13, 2019 10:57 — forked from cjddmut/EasingFunctions.cs
Easing Functions for Unity3D
/*
* Created by C.J. Kimberlin
*
* The MIT License (MIT)
*
* Copyright (c) 2019
*
* 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
@aprius
aprius / NativeMeshTest.cs
Created November 2, 2019 11:31 — forked from LotteMakesStuff/NativeMeshTest.cs
[NativeCollections] How to copy a regular .C# array into a NativeArray suuuuuper quick using memcpy. its about as fast as its ever gunna get!
using Unity.Collections;
using Unity.Collections.LowLevel.Unsafe;
using Unity.Mathematics;
using UnityEngine;
public class NativeMeshTest : MonoBehaviour
{
private NativeArray<float3> vertexBuffer;
private Vector3[] vertexArray;
@aprius
aprius / open-cmder-here.md
Last active March 2, 2020 02:37 — forked from hamzahamidi/open-cmder-here.md
"Open Cmder Here" in context menu

"Open Cmder Here" in context menu

To add an entry in the Windows Explorer context menu to open Cmder in a specific directory, paste this into a OpenCmderHere.reg file and double-click to install it.

    Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\Background\shell\Cmder]
@="Open Cmder Here"
"Icon"="C:\\Program Files\\cmder\\Cmder.exe,0"
@aprius
aprius / link.xml
Created September 13, 2020 10:59 — forked from TigerHix/link.xml
Unity link.xml for LiteDB 5.0.5