Skip to content

Instantly share code, notes, and snippets.

Avatar
😊
I love to code and can do it all day long ;)

Dilmer Valecillos dilmerv

😊
I love to code and can do it all day long ;)
View GitHub Profile
View EditorExtensionsThroughExperimentation.cs
using UnityEngine;
using System.Collections;
using UnityEditor;
using System.IO;
using System;
public class LevelScreenshot: EditorWindow {
// Quality Settings
enum Quality {
high = 4, Medium = 3, Normal = 2, Low = 1
View gist:0b4a33333c5140390a92
//This method goes in your character controller
//CharacterController.cs
void GlueToFloor ()
{
if (Mathf.Abs (move) > 0 || !groundHit || IM.Jump_Button ()) {
this.transform.GetComponent<Rigidbody2D> ().isKinematic = false;
}
else if (groundHit && Mathf.Abs (move) == 0 && !isPlatform) {
this.transform.GetComponent<Rigidbody2D> ().isKinematic = true;
}