This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using UnityEngine; | |
| using UnityEngine.Sprites; | |
| using UnityEngine.UI; | |
| #if UNITY_2017_4 || UNITY_2018_2_OR_NEWER | |
| using UnityEngine.U2D; | |
| #endif | |
| #if UNITY_EDITOR | |
| using UnityEditor; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // | |
| // Lookup Tables for Transvoxel's Modified Marching Cubes | |
| // | |
| // Unlike the original paper (Marching Cubes: A High Resolution 3D Surface Construction Algorithm), these tables guarantee | |
| // a closed mesh "whose connected components are continuous and free of holes." | |
| // | |
| // Rotations are prioritised over inversions so that 3 of the 6 cases containing ambiguous faces are never added. 3 extra | |
| // cases are added as a post-process, overriding inverses through custom-build rotations to eliminate the rest. | |
| // | |
| // Uses the exact same co-ordinate system as https://gist.github.com/dwilliamson/c041e3454a713e58baf6e4f8e5fffecd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ######################################## | |
| # Bakery .gitignore | |
| # Ignore: https://geom.io/bakery/wiki/index.php?title=How_do_I...#How_do_I_use_git.2Fcollab.2Fother_version_control_system_with_Bakery.3F | |
| # Never ignore: https://geom.io/bakery/wiki/index.php?title=How_do_I...#How_do_I_share_a_scene_with_someone_who_doesn.E2.80.99t_have_Bakery_installed.3F | |
| ######################################## | |
| ############# BAKERY ASSETS ############ | |
| # Ignore Bakery Assets folder | |
| /[Aa]ssets/Bakery/* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using UnityEngine; | |
| using UnityEngine.Rendering; | |
| using UnityEngine.Rendering.Universal; | |
| /* | |
| - Renders DepthOnly pass to _CameraDepthTexture, filtered by LayerMask | |
| - If the depth texture is generated via a Depth Prepass, URP uses the Opaque Layer Mask at the top of the Forward/Universal Renderer asset | |
| to determine which objects should be rendered to the depth texture. This feature can be used to render objects on *other layers* into the depth texture as well. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import bpy | |
| import os | |
| import sys | |
| ''' | |
| Imports the given FBX model, Decimates the meshes and exports as FBX | |
| @input | |
| <input_fbx_filepath> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using UnityEngine; | |
| using UnityEngine.Sprites; | |
| using UnityEngine.UI; | |
| #if UNITY_2017_4 || UNITY_2018_2_OR_NEWER | |
| using UnityEngine.U2D; | |
| #endif | |
| #if UNITY_EDITOR | |
| using UnityEditor; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using System.Runtime.InteropServices; | |
| using UnityEngine; | |
| class Render : MonoBehaviour | |
| { | |
| struct DrawData | |
| { | |
| public Vector3 Pos; | |
| public Quaternion Rot; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using UnityEditor; | |
| using UnityEngine; | |
| #if UNITY_EDITOR | |
| /// <summary> | |
| /// https://gist.github.com/alexmelyon/8f79bd08c79202d1570f26faefe47bf3 | |
| /// </summary> | |
| [ExecuteInEditMode] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using UnityEngine; | |
| using UnityEngine.Events; | |
| public class MouseFingerEvent | |
| { | |
| public Vector2 position; | |
| public int index; | |
| } | |
| public class MouseFinger : MonoBehaviour |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections; | |
| using System.Collections.Generic; | |
| using UnityEngine; | |
| public class CameraEditorMovement : MonoBehaviour | |
| { | |
| [Header("Mouse")] | |
| public float lookSpeedH = 2f; | |
| public float lookSpeedV = 2f; | |
| public float zoomSpeed = 2f; |