Uploaded May 2020 | Updated December 2026, 3 hours ago
Earlier this week we explored remote container environments for development that allow you to install, run and debug your development environments inside of isolated containers. By using containers this approach enables a few things: your development experience can be more consistent across multiple developers and each project has its own environment (less likely to introduce weird behavior because of some custom setup, a tool for a different project or missing dependency).
This is the first time I've really taken a dive into this feature so lets see what we can find out, if there are any significant pain points to keep in mind or ways to improve the experience. If you use these development environments and have suggestions I'd love to hear them!
Learn more about using remote containers in Visual Studio Code: code.visualstudio.com/docs/remote/containers
This was part of a Live Stream on Twitch. You can catch more of them by following worldofzerodev on Twitch: twitch.tv/worldofzerodev
Join the World of Zero Discord Server: discord.gg/hU5Kq2u
Earlier this week we explored remote container environments for development that allow you to install, run and debug your development environments inside of isolated containers. By using containers this approach enables a few things: your development experience can be more consistent across multiple developers and each project has its own environment (less likely to introduce weird behavior because of some custom setup, a tool for a different project or missing dependency).
This is the first time I've really taken a dive into this feature so lets see what we can find out, if there are any significant pain points to keep in mind or ways to improve the experience. If you use these development environments and have suggestions I'd love to hear them!
Learn more about using remote containers in Visual Studio Code: code.visualstudio.com/docs/remote/containers
This was part of a Live Stream on Twitch. You can catch more of them by following worldofzerodev on Twitch: twitch.tv/worldofzerodev
Join the World of Zero Discord Server: discord.gg/hU5Kq2u



You can use the `CreateAssetMenuAttribute` to [create asset menus and more easily create new `ScriptableObject`s](https://docs.unity3d.com/ScriptReference/CreateAssetMenuAttribute.html).
Join the World of Zero Discord Server: https://discord.gg/hU5Kq2u Using Scriptable Objects in Unity](https://i.ytimg.com/vi/2P4oPtU2Rtk/mqdefault.jpg)


: Multiline strings expand the normal textbox a fixed number of vertical lines. This is less flexible than a `TextArea` but can still be useful in some situations.
* [`TextArea`](https://docs.unity3d.com/ScriptReference/TextAreaAttribute.html): Text Areas span between a minimum and maximum number of lines and - unlike a `Multiline` attribute - they will add scrollbars if the text exceeds the maximum number of lines. Additionally the `TextArea` spans the entire width of the Inspector giving more room to type.
The JSON.NET documentation is available here: https://www.newtonsoft.com/json/help/html/Introduction.htm
***
Join the World of Zero Discord Server: https://discord.gg/hU5Kq2u An Intro to Json Serialization and Deserialization in Unity](https://i.ytimg.com/vi/3F4HjM_5hZY/mqdefault.jpg)

![Live Coding Handles and Custom Editors in Unity
There are a few fun ways to make fantastic Editor tools in Unity for your code. Two of those are `Handles` and `GenericMenu`. They enable you to create interactive components inside the Unity Scene View that allow you to more easily interact with your objects. They work as fantastic solutions for building custom editors. The thing is... Ive never really used them. Its time that changed.
Lets explore how these features work and how we might use them for our own projects. How do we draw a custom Handle using Unitys Handle features? How about creating a custom editor with a context menu we can consume? Well build both to improve the visualization of our custom Graph code from a previous video.
To draw a basic `Handle` you may use `OnSceneGUI`. A sample of what this kind of editor might look like is below. It will draw a yellow line from the center of the scene to the `GameObject`s position.
```csharp
using UnityEditor;
[CustomEditor(typeof(MyCustomClass))]
public class MyCustomClassEditor: Editor
{
protected virtual void OnSceneGUI()
{
MyCustomClass customClass = (MyCustomClass)target;
// Safety against selecting a null GameObject
if (customClass null)
{
return;
}
Handles.color = Color.yellow;
Handles.DrawLine(Vector3.one, customClass.transform.position);
}
}
```
You may draw a custom `GenericMenu` using something like this. It will create a two option menu that prints out the selected option to the Debug Log.
```csharp
GenericMenu menu = new GenericMenu();
menu.AddItem(new GUIContent(The name of a menu option), false, () ⇒ { Debug.Log(Picked First Option); });
menu.AddItem(new GUIContent(The name of a second menu option), false, () ⇒ { Debug.Log(Picked Second Option); });
// once you are done, show your menu
menu.ShowAsContext();
```
The documentation for `Handles` is available on Unitys website: https://docs.unity3d.com/ScriptReference/Handles.html
The documentation for `GenericMenu` is also on Unitys site. More info here: https://docs.unity3d.com/ScriptReference/GenericMenu.html
Join the World of Zero Discord Server: https://discord.gg/hU5Kq2u Live Coding Handles and Custom Editors in Unity](https://i.ytimg.com/vi/3efiobxsurY/mqdefault.jpg)

![Using C#s nameof Expression - C# Quick Tip
The `nameof` expression allows you to convert a variable, property, type or function into a string that represents its name. This can be an alternative to typing out strings directly in your code when you need to reference the name of an object in your code. This is really common when implementing `INotifyPropertyChanged` events and has a number of other uses as well.
The advantage of using `nameof` compared to writing out the object in a string is that the dotnet compile will fail if the reference in your nameof expression does not exist. This can help catch issues during refactoring when elements are renamed. Typically, when using strings directly those references can become runtime errors and potentially be very difficult to identify (ex. a UI element not updating because it no longer receives its Property Update notification). `nameof` can help avoid that issue in your code.
Some examples of how to use `nameof`:
```csharp
class Program
{
public float aVariableNamedFoo = 3.14f;
public float Foo =˃ aVariableNamedFoo;
static void Main(string[] args)
{
Console.WriteLine($Class: {nameof(Program)}); //Class: Program
Console.WriteLine($Variable: {nameof(aVariableNamedFoo)}); //Variable: aVariableNamedFoo
Console.WriteLine($Property: {nameof(Foo)}); //Property: Foo
Console.WriteLine($Function: {nameof(Main)}); //Function: Main
}
}
```
`nameof` can also be used against members of other objects. For example the `nameof` a Lists Count can be retrieved using:
```csharp
var contents = new List˂Page˃();
Console.WriteLine($List Count: {nameof(contents.Count)}); //List Count: Count
```
You can learn more about using `nameof` in the C# documentation here: https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/operators/nameof
***
Join the World of Zero Discord Server: https://discord.gg/hU5Kq2u Using C#s nameof Expression - C# Quick Tip](https://i.ytimg.com/vi/48iBTUYjf8k/mqdefault.jpg)
