- Home /
Can't draw a box using Basic GUI
Very... VERY... Basic script... I mean... Come on..
using UnityEngine;
using System.Collections;
public class StatPoints : MonoBehaviour {
void OnGUI() {
GUI.Box(new Rect(10, 20, 20, 20), "hi");
}
}
Error = No overload for method Box' takes
1' arguments
Used google, no fix. I've used GUI.Box plenty of times before, I don't know why it's derping on this project.
hm, try creating a new project entirely and do not import anything. Your code is exactly what is posted on the docs. If it still doesn't work you may need to repair/re-install Unity. Possible missing packages/files/etc
Answer by LPGaming · Jan 13, 2013 at 09:59 AM
I closed my console and refreshed my Scripts Folder, then re-opponened console and it was fine. Thanks for the help
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Is there something wrong with my c# script? 1 Answer
GUI Box with a GUI Skin 1 Answer
[Solved] GUI Error? 1 Answer
Error (Read Only) 1 Answer