This collection of Visual Studio snippets is created for working with Unity C# scripts. It contains the "Message" functions within MonoBehaviour, such as "Start", "OnCollisionEnter", and "OnSerializeNetworkView", complete with their signatures and brief documentation.
To use the snippets, simply begin typing one of the functions and the suggestions will appear within the IntelliSense popup. Press tab twice to insert the snippet. All the snippets are appended with "_Documentation" to differentiate them from the built in Unity snippets (built in snippets do not contain documentation).
- Open VS and select
Tools > Code Snippets Manager...
or pressCtrl
+K
,Ctrl
+B
. - Do one of the following depending on whether you want to link to this folder or copy
the snippets into VS internal snippets folder.
- Choose
Add...
and select thesnippets
folder to link to these snippets. - Choose
Import...
and select all thexxx.snippets
files in thesnippets
folder to copy the files into VS internal snippets folder.
- Choose