Graphical User Interface. A term used to describe the tools available to the player to interact with the game.

learn more… | top users | synonyms

1
vote
1answer
452 views

Unity 4.6 GUI - Dynamically change the functions called by GUI elements

Looking to dynamically change the value in the button OnClick and slider On Value Changed . If I had to guess on how this was done, get a reference to the button/gui element. Next get the Button ...
0
votes
1answer
171 views

Simple heart container script for 2D game (Unity)?

I'm attempting to create a simple mobile game (C#) that involves a simple three-heart life system. After searching for hours online, many of the solutions use OnGUI (which is apparently horrible for ...
0
votes
1answer
70 views

touch in guiTexture

Before time in my game start. i want there will show a guiTexture.. if i touch this guiTexture, that will hidden and the time game will start. I try to make a script but it doesn't work. I'm a bit ...
0
votes
1answer
113 views

Libgdx actor bounds are wrong

The Actor's boundaries are not centered at the ButtonText but I used the setBounds() method. The higher the Y position is, the less centered is the boundary. The weird thing is that i only created ...
0
votes
1answer
96 views

Generating a particle effect on top of a GUIElement (Unity)

I am working in Unity on a 2D project which is using C#. I have a number of guitextures which are hearts in order to create a sort of life meter. I would like when the player loses a heart for the ...
0
votes
1answer
185 views

Unity Gui from text file templates

I've been banging my head against a wall this past while over how I might create menu's and menu components in unity from text file. I would normally just build my own extended panel/label classes etc ...
0
votes
1answer
157 views

Make GuiText responsive

I'm using C# code to make a responsive GuiText. I was abel to make a responsive GuiTexture, but I'm struggling with doing the same for a GuiText. Code for the responsive GuiTexture using ...
0
votes
1answer
72 views

How can I create a button with an image in libGDX?

I am new to LibGDX. I am trying to develop a game for Android (so it will support different screen sizes), but I don't know how to put a button with an image. I tried ImageButton but I can't resize ...
0
votes
2answers
831 views

Responsive GUI with Unity and C# script

I'm working on my character menu for an RPG in Unity. I have my menu set up with different buttons for different categories. All is well, except when I re-size my screen, my layout is sized ...
0
votes
1answer
168 views

How do I animate Unity GUIComponents?

I want to transform my GUIWindow from the bottom of the screen to the middle whenever the user presses a button. How can I do this?
1
vote
1answer
142 views

Libgdx stage rendering issues

I'm using scene2d for the first time, and I can't get anything to draw EXCEPT the stage ui. Say I have my ui on top of my game screen: uiStage.act(): batch.begin(); gameSprite.draw(batch); //does not ...
2
votes
3answers
460 views

SharpDX/D3D: How to implement and draw fonts/text

I am playing with SharpDX (Direct3D for .NET) without using "Toolkit", already finished with basic rendering 3D models. But now i am wondering how to program/create fonts for game (2D), or how to ...
0
votes
2answers
108 views

How to show a float with no decimals [closed]

I want to show the current health and stamina of the player using GUI.Label. All is working fine however it shows the values with decimals to the millionth (example: ...
2
votes
3answers
136 views

How to display a GUI Texture for a certain amount of time

Is it possible to make a gui Texture display for a certain amount of Time.
2
votes
1answer
3k views

Should I use XNA or Unity to build a video game? [closed]

My friend and I are planning to make a video game (like Slender) where the character is stuck in a building, when lightning strikes, and the lights go out and your objective is to find the back-up ...
0
votes
1answer
39 views

SDL Surface clipping mask

I am creating a GUI for my game, so I use some buttons like . So you can see it is only text surrounded by a rectangle. But I currently use a huge png image with all the buttons I need arranged as I ...
2
votes
1answer
409 views

How to match font size with screen resolution?

So I'm working on a game using LibGDX, and I have a problem. To make my game fit most resolutions, I created a base asset for each aspect ratio, for example, a main menu background image, I made it ...
2
votes
2answers
669 views

How can I prevent clicks from going through a GUI.Box?

I have a GUI.Box that I slide in from the side of the screen. How can I prevent mouse interaction from going to any objects under it (another GUI.Button for instance, or for that matter an ...
0
votes
0answers
61 views

hide and show many guiTexture

in the 1 scene there are many guiTexture. So how to write this code ? public class guiTanya : MonoBehaviour { public GUITexture guiA, guiB, guiC, guiD, guiE, guiF; void onMouseDown() { //if i press ...
0
votes
1answer
324 views

SDL2 window as child of Win32 GUI

I'm building an editor. Is it possible to create a child window of SDL2 within a Win32 gui? (The most obvious page from SDLTutorials works for earlier versions of SDL)
0
votes
1answer
424 views

Going from WPF to Unity3D, how to implement the MVVM-pattern?

I've been working with MVVM in WPF for a long time and I'm now trying out Unity3D for a GUI-driven application. Can I work with view models and bind them to properties in GUI-components? I guess the ...
1
vote
2answers
165 views

Hide part of the GUITexture in Unity

I have a Health Bar in my Unity game and it's implemented as a GUITexture with gradient image from red to green. Now I can reduce it's width from max width to 0, but is still scaled gradient. ...
1
vote
0answers
462 views

How to correctly set window size in Libgdx scene2d.ui dialog

In my libGDX application I am using the scene2d.ui classes to render my game's GUI. One of the things I render via these classes is a dialog window with a background image set. I have created the ...
0
votes
1answer
830 views

Prevent GUI Clickthrough

I'm using NGUI to setup my UI in Unity. Attached to the MainCamera I do have a script to rotate the camera view by clicking and dragging. It does handle mouse events using Input.GetMouseButton(). ...
0
votes
0answers
34 views

Keeping relative size with different resolution

I'm making a GUI system and want the components having a konstant relative size, even if I'm changing the resolution. Since I'm using the relative OpenGL coordinates to place them, there is no ...
9
votes
2answers
814 views

Entity/Component System and UI “Entities”

I'm still green to entity/component systems. I find that since I have useful components for drawing sprites (or spritesheets) and handling input (mouse/touch clicks), I naturally want to reuse these ...
0
votes
1answer
289 views

Should I render all of my HUD views to a single SurfaceView?

I'm using a SurfaceView and canvas to implement a game HUD, title screens etc., by overlaying standard Android view widgets over my SurfaceView. This works reasonably well and maintains an acceptable ...
-2
votes
1answer
131 views

Why is my Snake' tail rendering the wrong sprite? [closed]

I am making a snake game in Unity. The game is simple, using Texture2D to display the head, tail and body parts. I am stuck with this problem: I stored 4 textures (each one for one of the four ...
2
votes
2answers
143 views

Print on the GUI in Unity

I'm trying to show the players name on the GUI with a label. GUI.Label(new Rect(10,10, 100, 30), playerName); Instead of use the default style I want to use a different font with larger character. ...
12
votes
1answer
9k views

Making a HUD/GUI with OpenGL (LWJGL)

I'm at the stage in my game development where I need to make a HUD or GUI. I've never gotten to this part, so I don't know how its done. I tried rendering a simple quad at a fixed position on the ...
1
vote
1answer
2k views

GUIText size on 4:3 and 16:9 is different

I have a text (guiText) on the screen. It shows correctly when viewed on 16:9 resolution. But it scales up when viewed on 4:3 (e.g iPhone4). I am using following ObjectLabel script to place it on ...
16
votes
4answers
1k views

What are some good (retro) symbols for magic/mana/energy? [closed]

Much like a heart is used a lot for health and lives in old retro games... ...what would be a good icon to use for Energy, Mana and/or Magic points?
2
votes
3answers
178 views

How can I model a “weapon overheating” mechanic?

I want to create a weapon overheating system very similar to the plasma rifle in Halo. You can watch a video of the plasma rifle firing. What I want to do is to create a flexible logic that can be ...
2
votes
2answers
134 views

Should widgets be part of a scene in a 2D game?

I'm in the middle of separating logic and drawing of a 2D game, i.e. I'm moving from scenes/entities that draw themselves to scenes/entities that merely store and update data, getting drawn by a ...
1
vote
0answers
49 views

Pencil GUI design for Game Development [closed]

Does anyone know if there are any game-development related stencil collections for the Pencil GUI designer, or whether there's a more appropriate tool for this job? I just want to be able to quickly ...
1
vote
1answer
207 views

Why isn't this UIButton visible in Xamarin.iOS?

I'm trying to implement buttons into my game. I noticed iOS has the UIButton class, which I tried, but upon drawing it nothing is shown. The asset image is properly loaded, I've checked this. The ...
0
votes
1answer
248 views

OnClick events - using Scaleform UI with Cryengine 3.5.4

I've created a UI in Flash, set up an xml file for it and designed a flowgraph to ensure it displays when I launch. However, clicking on the buttons doesn't appear to do anything, despite me writing ...
0
votes
2answers
86 views

string on GUI.Button not showned

I am sure that inventoryItem.Name contains "Wood" cause i see it when i add a breakpoint. Still i get nothing in the game. Just empty buttons. void DrawInventoryContent (int id) { ...
0
votes
1answer
101 views

Variable number of GUI Buttons

I have a generic HTML5 Canvas GUI Button class and a Scene class. The Scene class has a method called createButton(), which will create a new Button with onclick parameter and store it in a list of ...
0
votes
1answer
518 views

Unity GUI not in build, but works fine in editor

I have: GUITexture attached to an object A script that has GUIStyles created for the Textfield and Buttons that are created in OnGUI(). This script is attached to the same object in number 1 3 ...
2
votes
0answers
110 views

1:1 mapping of texels to pixels with DX11 and multisampling and linear interpolation

Is it possible to get a 1:1 mapping of texels to pixels on a multisampled target in DX 11 with interpolation? It seems to me that the texture coordinate used in the shader is always one of the ...
1
vote
0answers
209 views

What's a good C++ game engine for beginners? [closed]

I'm looking for game engines. I'm not looking for things like OPENGL, DirectX, or Irrlitcht; those are game libraries? Also can it be C++ native code? So any good ones out there?
2
votes
2answers
125 views

How should I provide a navigation system for a world with infinite space?

The world is generated by perlin noise chunks and will only be saved once that chunk has been generated. It will also not necessarily have one obvious (to the user) central point anywhere in the ...
1
vote
1answer
234 views

LWJGL Wait for key press in a single method

Currently I am implementing the possibility in my game to change the keyboard configuration. Therefor, I have a menu in which is a button for each action the player can do. If the player clicks on one ...
2
votes
1answer
168 views

How should I architect my GUI for my HTML5 canvas cell phone game? [closed]

I'm making a game on the HTML5 canvas and my intent is to run or port this code to work on cell phones. Right now it only runs on my desktop computer. I'm trying to write my GUI code but I'm not ...
46
votes
9answers
44k views

Good GUI for OpenGL [closed]

I am starting to learn OpenGL with FreeGLUT using the Superbible and the knowledge i have from my elementary graphics to brush up on my skills. To get more from this experience i want to integrate a ...
1
vote
1answer
224 views

What type of GUI element is the Starcraft points counter?

I have recently played 2-3 games of StarCraft 1 and after each game the statistics screen shows up. The part I like on this screen is the points counter. It starts from zero and then it counts up to ...
0
votes
1answer
584 views

Slick2D and Nifty GUI

I am currently trying to combine both slick2d and nifty to work together. I've had some amount of success - I can now actually run my test and it won't crash. As far as I can tell, it will also ...
1
vote
1answer
505 views

Candy crush saga popup-like messages

I was wondering how could I make in Android something like the popup messages seen in Candy Crush Saga, those messages like "Delicious!", "Tasty!" or similar: As well as the score of each movement, ...
-3
votes
1answer
368 views

GUI layouts in games?

What is a general process of making a GUI in a game without resorting to a full blown GUI library? What I mean by this is how would I go about constructing a GUI layout like those in Java that are not ...