Skip to content

Instantly share code, notes, and snippets.

View 6ilberM's full-sized avatar
🧙‍♂️
On it

Gilber Moreno 6ilberM

🧙‍♂️
On it
View GitHub Profile
@6ilberM
6ilberM / DebugCameraController.cs
Created September 4, 2020 18:08
A simple Floating Camera Controller for Unity, using Unity's "New Input System".
using UnityEngine;
using UnityEngine.InputSystem;
using UnityEngine.InputSystem.EnhancedTouch;
using Touch = UnityEngine.InputSystem.EnhancedTouch.Touch;
[AddComponentMenu("Debug/Float Camera Controller")]
public class DebugCameraController : MonoBehaviour
{
public float lookSpeedH = 5f;
Shader "Unlit/Panner"
{
Properties
{
_Color ("Color", Color) = (1,1,1,1)
_MainTex ("Color Texture", 2D) = "white" {}
_MaskTex ("Mask Texture", 2D) = "white" {}
_MFade("Mask Fade", Range(0,1)) = 0.2
_MIntesity("Mask Intesity", Float) = 1
_SpeedU("Color SpeedU", Float) = 1