- Home /
Question by
Geine · Sep 22, 2012 at 02:32 AM ·
javascriptguitextureguiwindow
GUI.Texture Over GUI.Window
hi~ i'd like to ask how can a `GUI.Texture()` be drawn over `GUI.Window()` on the same script
e.g
function OnGUI()
{
GUI.DrawTexture(Rect((mX-msX/2),((Screen.height-mY)-msY/2+msY/2),msX,msY),cmTex);//texture
bag = GUI.Window(0,bag,bagWindow,cPage[gridV]); //window
}
Comment
Answer by atromgame · Feb 15, 2013 at 02:40 PM
Try like this ;
funtion OnGUI() {
GUI.Window (0, windowRect, GUI.WindowFunction (DoWindow), "Window");
}
function DoWindow (windowID : int) {
GUI.DrawTexture(Rect((mX-msX/2),((Screen.height-mY)-sY/2+msY/2),msX,msY),cmTex);//texture
}
Your answer
![](https://koobas.hobune.stream/wayback/20220613081328im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Door Problem 1 Answer
Health Script not working 1 Answer
How to Make A GUI Keypad Login With Texture Buttons 1 Answer
Make crosshairs disappear while aiming 0 Answers
Finding the GuiTexture of an object 1 Answer