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
| # RegEx to select EVERY OTHER comma | |
| ([^,]*,[^,]*),([^,]*,[^,]*), |
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
| # Load version control information | |
| autoload -Uz vcs_info | |
| precmd() { vcs_info } | |
| # Format the vcs_info_msg_0_ variable | |
| zstyle ":vcs_info:git:*" formats "(%b) " | |
| NEWLINE=$'\n' | |
| # Set up the prompt (with git branch name) | |
| setopt PROMPT_SUBST |
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
| { | |
| // Use IntelliSense to learn about possible attributes. | |
| // Hover to view descriptions of existing attributes. | |
| // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | |
| "version": "0.2.0", | |
| "configurations": [ | |
| { | |
| "name": "Unity Editor", | |
| "type": "unity", | |
| "path": "/D:/PATH_TO_UNITY_PROJECT/Library/EditorInstance.json", |
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 UnityEditor; | |
| public class TreeModelEditor : MonoBehaviour | |
| { | |
| /// Example editor function for creating a new prefab in Assets folder | |
| [MenuItem("GameObject/CreatePrefab")] | |
| public static void CreatePrefab() | |
| { | |
| GameObject newObj = new GameObject(); |
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
| Object[] fbxObjects = Resources.LoadAll("Buildings"); // filename is "Buildings.FBX" | |
| List<Mesh> meshes = new List<Mesh>(); | |
| List<Material> materials = new List<Material>(); | |
| foreach (Object obj in fbxObjects) | |
| { | |
| if (obj is Mesh) | |
| { | |
| meshes.Add(obj as Mesh); | |
| } | |
| else if (obj is Material) |