Skip to content

Instantly share code, notes, and snippets.

@todorok1
Last active January 8, 2021 06:54
Show Gist options
  • Save todorok1/7f408d57a67f1913359d5730e6113908 to your computer and use it in GitHub Desktop.
Save todorok1/7f408d57a67f1913359d5730e6113908 to your computer and use it in GitHub Desktop.
readonlyの例
public static class TodoStaticClass
{
public const string name = "todo";
public static readonly int thisYear = 2021;
}
// 別のクラスで呼んでみる
Debug.Log(TodoStaticClass.thisYear);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment