public override void OnInspectorGUI() { RoomLayout rl = (RoomLayout)target; if (DrawDefaultInspector()) { //rl.GenerateRoom(); } if (GUILayout.Button("Generate")) { rl.GenerateRoom(); } }