UnityImGUI
UnityImGUI copied to clipboard
"Microsoft (R) Visual C# Compiller version 2.9.1.65535 (9d34608e)" after installing UnityImGui package
Hey I'm a little confused on how to actually implement this seeing as there is no documentation. any help is appreciated.
Howdy!
After bringing the unity package into your project from the releases, add the ImGuiPluginHook prefab to your scene.
Now, you can write the usual ImGui code (Thanks to ImGUI.NET) in the Update function of one of your scripts.
eg.
using UnityEngine;
using ImGuiNET;
public class MyAwesomeGameScript : MonoBehaviour
{
public System.Numerics.Vector3 selectedColor;
public void Update()
{
ImGui.Begin("Interesting Game Window");
if (ImGui.Button("TestButton"))
Debug.Log("Button Pressed!");
ImGui.ColorEdit3("Colour Picker", ref selectedColor);
ImGui.End();
}
}
And when running you will get this
Holy fast reply thank you!
Whats in your project console? Any compile errors?
Uh yeah I'm trying to google that too and its a little difficult
I'm not really too advanced in game development just heard from a friend that unity uses C# and I should try it out
Thats a strange issue. Which version of unity are you on?
And is this on windows?
latest 2019.4.17f1
And correct I am on windows.
Hmm, very strange! Thats the exact version that I took that screen shot from a moment ago
It might be something with your visual studio install. I would run the visual studio installer
Then modify your install
And then check to make sure you have all the c sharp things installed that you would need (I am not sure which things you would actually need)
Also, in the project settings in your unity project.
In the player tab
Is your Api compatibility level set to this?
Uh I closed unity assuming that it would need to restart after messing with visual studio packages I will relaunch it one second.
Sure no rush, Ill be around for a couple hours or so 😄
Unities OnGUI is a lot easier to get running but it doesn't fit my game style, of more modern.
OnGUI also ends up allocating each frame if I recall, and is generally bad for performance unless you really mess with some of the internal DLL code relating to it.
ImGUI is really nice, I use it for quick debug menus quite a lot. I wish I had more time to make this perfect to use in all situations, but I just dont have the time :(
Please Excuse my grammar english isn't my first language.
I'm creating an online platformer game and I need it for an administration/moderation menu
Please Excuse my grammar english isn't my first language.
Don't worry, I understand you fine :)
Sounds like it could be a good game, I wish you luck!
I dont see the api compatability
It would be in the other settings drop down
I'm so confused
Hmm, I have no idea why you might be getting this issue then. I have never seen it before.
It is probably something with your setup. Does it do the same issue in a new project, when you don't have UnityImGUI added?
No.
do i need to install ImGUI.net via nuget?
No, it should have came with it. Did you check online for that error? It seems like a specific issue
i tried and no results
Ima attempt to fix this on my own please leave this issue open i will post any solutions I can come up with for anyone else who has this problem
Sure can do, Im going to go to bed shortly. I'll keep an eye out to see if I can figure it out too :)