Assets\Ball Fight\Scripts\Controller\Scripts\Controller\FloatingJoystickEditor.cs(30,1): error CS1022: Type or namespace definition, or end-of-file expected
UnityEditor.BuildPlayerWindow+BuildMethodException: 2 errors
at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002ca] in <97ba64834c8f4edc84e3d8e30b04f122>:0
at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <97ba64834c8f4edc84e3d8e30b04f122>:0
UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
There is no problem when ı starting game in editor but when ı want to build, i get this mistake. How can ı solve these problems ? Thanks
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
#if UNITY_EDITOR
using UnityEditor;
#endif
[CustomEditor(typeof(FloatingJoystick))]
public class FloatingJoystickEditor : JoystickEditor
{
#if UNITY_EDITOR
public override void OnInspectorGUI()
{
base.OnInspectorGUI();
if (background != null)
{
RectTransform backgroundRect = (RectTransform)background.objectReferenceValue;
backgroundRect.anchorMax = Vector2.zero;
backgroundRect.anchorMin = Vector2.zero;
backgroundRect.pivot = center;
}
#endif
}
}