Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Alexander Scheurer ASPePeX

🏠
Working from home
View GitHub Profile
View Fusee.Engine.Core.Serializer.cs
using Fusee.Base.Core;
using Fusee.Serialization;
using System.IO;
namespace Fusee.Engine.Core
{
/// <summary>
/// High level serialization helper thing
/// </summary>
public static class Serializer
@ASPePeX
ASPePeX / SpanCast.cs
Created Jul 24, 2018
Casting Span<T> Example - int to byte and back
View SpanCast.cs
using System;
using System.Runtime.InteropServices;
namespace SpanCast
{
class Program
{
static void Main(string[] args)
{
//preparing test data
View gist:199575f9df7f75236a165065c33f4093
Adventure Racer in the style of Monkey Island sword fights
Crypt of the Necrodancer MOBA
@ASPePeX
ASPePeX / InputJSON.cs
Last active Jul 20, 2017
Unity www poll script
View InputJSON.cs
public class InputJSON
{
public float Input;
}
@ASPePeX
ASPePeX / SmoothCameraFollow2D.cs
Created Mar 3, 2017
An easy and short script for a smooth 2D follow camera in Unity.
View SmoothCameraFollow2D.cs
using UnityEngine;
public class SmoothCameraFollow2D : MonoBehaviour
{
public GameObject Target;
public float LerpValue = 0.05f;
private float _t;
private Vector3 _pos;
@ASPePeX
ASPePeX / texcompunity.txt
Last active Nov 3, 2016
Texture Compression Reminder - Unity Android
View texcompunity.txt
Samsung Galaxy S4 - Snapdragon 600 - ASTC
Project Tango - Tegra - DXT
--
More to come
@ASPePeX
ASPePeX / SpriteAlphaMask.shader
Last active Oct 6, 2016
Unity shader to use a sprite as a transparent mask. You can for example have a animated sprite-sheet in a augmented reality scene and occlude it by real world objects.
View SpriteAlphaMask.shader
Shader "Sprites/SpriteMask"
{
Properties
{
[PerRendererData] _MainTex("Sprite Texture", 2D) = "white" {}
_Cutoff("Base Alpha cutoff", Range(0,1)) = .5
}
SubShader
{
You can’t perform that action at this time.