Skip to content

Instantly share code, notes, and snippets.

Avatar

Joseph Kalathil josephbk117

View GitHub Profile
@josephbk117
josephbk117 / ExtendedSkybox.shader
Last active Nov 18, 2018
A unity shader code with good skybox colour and transition control ( day/night cycle)
View ExtendedSkybox.shader
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
Shader "BitshiftProgrammer/Skybox"
{
Properties
{
_SkyColor1("Top Color Day", Color) = (0.37, 0.52, 0.73, 0)
_SkyColor2("Horizon Color Day", Color) = (0.89, 0.96, 1, 0)
@josephbk117
josephbk117 / SurfaceGenerator.cs
Last active Nov 18, 2018
Code for generating 2d surfaces like in Alto's Adventure
View SurfaceGenerator.cs
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
using UnityEngine;
public class SurfaceGenerator : MonoBehaviour
{
public bool generateContinuously = false;
public bool generateCollider = false;
@josephbk117
josephbk117 / SurfaceImitator.cs
Created Jan 8, 2018
depth surface generated with the help of surface generator script
View SurfaceImitator.cs
using UnityEngine;
public class SurfaceImitator : MonoBehaviour
{
public SurfaceGenerator reference;
public bool generateCollider = true;
private Mesh mesh;
private Vector3[] vertices;
@josephbk117
josephbk117 / JarvisMarchConvexHull.cs
Last active Sep 23, 2019
Jarvis march convex hull unity c# script
View JarvisMarchConvexHull.cs
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class JarvisMarchConvexHull : MonoBehaviour
{
@josephbk117
josephbk117 / AudioVisualizer.cs
Last active Nov 18, 2018
Audio visualizer in unity with blend shapes
View AudioVisualizer.cs
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
using UnityEngine;
[RequireComponent(typeof(SkinnedMeshRenderer))]
public class AudioVisualizer : MonoBehaviour
{
[Range(1.0f,4500.0f)]
@josephbk117
josephbk117 / GenericsExample.cs
Created Jan 11, 2018
An exmple of generics in c#
View GenericsExample.cs
using System;
using System.Collections;
using System.Collections.Generic;
public interface IUseMagic
{
void UseMagic();
}
public class MagicUser : IUseMagic
{
@josephbk117
josephbk117 / AnimatedFish.shader
Last active Oct 29, 2019
An animated fish shader written for use in unity
View AnimatedFish.shader
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
Shader "BitShiftProgrammer/AnimatedFish"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_EffectRadius("Wave Effect Radius",Range(0.0,1.0)) = 0.5
@josephbk117
josephbk117 / WhiteNoise.shader
Last active Jul 21, 2018
White noise ( grain filter ) shader in unity
View WhiteNoise.shader
Shader "BitShiftProductions/Noises"
{
Properties
{
_MainTex("Texture", 2D)="white"
_NoiseScale("Noise Scale",Float) = 5.0
_Strength("Noise Strength",Float) = 1.0
}
SubShader
{
@josephbk117
josephbk117 / DirectionalColour.shader
Last active Nov 18, 2018
unity shader that shows texture based on the object's normal
View DirectionalColour.shader
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
Shader "BitShiftProgrammer/DirectionalColour"
{
Properties
{
_Tex1 ("Texture 1", 2D) = "white" {}
_Tex2("Texture 2", 2D) = "white"{}
@josephbk117
josephbk117 / VoronoiNoise.shader
Last active May 30, 2019
Voronoi shader in unity
View VoronoiNoise.shader
/*Please do support www.bitshiftprogrammer.com by joining the facebook page : fb.com/BitshiftProgrammer
Legal Stuff:
This code is free to use no restrictions but attribution would be appreciated.
Any damage caused either partly or completly due to usage of this stuff is not my responsibility*/
Shader "BitShiftProductions/VoronoiMagic2"
{
Properties
{
}
You can’t perform that action at this time.