Skip to content

Instantly share code, notes, and snippets.

@NamPhuThuy
NamPhuThuy / 81-C# Script-NewBehaviourScript.cs.txt
Created June 6, 2025 09:17
Add this file into Assest/ScriptTemplates of any Unity project to custom the Default Script Template (the script that is generated when create a new script in Unity))
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
#if UNITY_EDITOR
using UnityEditor;
#endif
public class #SCRIPTNAME# : MonoBehaviour
{
#region MonoBehaviour Methods
@NamPhuThuy
NamPhuThuy / Game-Programming-Shortcuts.md
Last active March 11, 2026 21:28
This document provides a quick reference for keyboard shortcuts in Cursor IDE, JetBrains Rider and Unity

Cursor vs Rider IDE Shortcuts Comparison

General Navigation

Action Cursor Rider Description
Quick Open Ctrl + P Ctrl + Shift + N Open file by name
Command Palette Ctrl + Shift + P Ctrl + Shift + A Show all commands
Go to Definition F12 Ctrl + B Navigate to definition of current field/method/class
Find All Usages Shift + F12 Ctrl + B Find all usages
@NamPhuThuy
NamPhuThuy / AssetImportHelper.cs
Last active May 30, 2025 13:53
Automatically sets import presets based on asset format when imported in Unity
#if UNITY_EDITOR
using UnityEditor;
using UnityEngine;
using System.IO;
//automatically sets import presets based on asset format
namespace NamPhuThuy
{
public class AssetImportHelper : AssetPostprocessor
{