Skip to main content

Questions tagged [gui]

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

113 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4 votes
0 answers
291 views

Determine user mouse selection of 3D Object for multiple viewports

I am currently working on setting up some world objects for my level editor and am running into a bit of a snag. When I get the hit location from the mouse raycast, I would like to determine what part ...
Chaz H's user avatar
  • 41
4 votes
0 answers
401 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 sub-...
ltjax's user avatar
  • 851
3 votes
1 answer
656 views

Create context menu in Scene view

I created some MenuItemfunctions for navigating, which are currently displayed on the menu toolbar. The C# code: ...
Elgirhath's user avatar
  • 209
3 votes
0 answers
335 views

Quest UI Display in Unity 2D

I have this quest manager script where I store all my quests for easy duplication. I'm adding a feature that gives the player the option to see his/her current to-do quest. The first thing I ...
Nicole James Cresencio's user avatar
3 votes
0 answers
845 views

Find Max Line Count for Unity UI.Text

I'm trying to determine the max line count of a UI.Text with VerticalOverflow set to truncate...
BadmintonCat's user avatar
3 votes
0 answers
105 views

Get the position of a GUI.Button and instantiate in its position

I am trying to instantiate a GUI.Box in the position of my GUI.Button when it is clicked but I just cant seem to get the position of the button. The button does change position. Here is the code of ...
user108659's user avatar
3 votes
0 answers
3k views

How to make a fade effect on the Unity's scrollView?

I have a basic ScrollView, with some additional scripts so it snaps to the nearest element (focusing on it). When I perform the scroll, it looks like this: What I ...
Jacob's user avatar
  • 2,552
3 votes
0 answers
108 views

External gui within a render loop

I was wandering how easy is to interface existing Java programs/GUIs inside a game loop. Sorry if my question is a bit vague. I'll try to explain. I am currently designing a simulation environment ...
Vagos Duke's user avatar
3 votes
0 answers
375 views

Unity 5.3.5 - Blurry UI text after switching canvasses - until text is refreshed by turning visibility off/on or changing resolution

I have multiple scenes in my project where the canvas are switched between, each canvas having UI text included on it. The project was originally created in version 5.0 and I have just updated to ...
NIMBLE JIM's user avatar
3 votes
0 answers
513 views

Optimise Gear-VR text rendering with Unity

I have a problem with my text being always kind of broken, so there are just some parts of the text visible (parts of letters) and the text flickers a lot. At the moment I have this text 2D-UI text ...
TobiasW's user avatar
  • 987
2 votes
0 answers
85 views

What is a natural way of rendering dynamic (partially view dependent) GUI elements?

My question is really about low-level rendering techniques, but I'm going to illustrate it with a high-level GUI example. I'm not so much interested in GUI design, but rather in some basic concepts ...
quasa's user avatar
  • 21
2 votes
0 answers
306 views

Pan over an image like a map using scroll container in godot?

I want to create a level select screen, the aspect ratio for my game screen is 576*1024 and the image, I am using is 2048*2048. What I want is for the user to scroll the screen and navigate along the ...
Hamza Memon's user avatar
2 votes
0 answers
846 views

Why doesn't the Camera.pixel(Height/Width) match the Canvas size?

I am making an app that has a custom viewport Rect like so: When I check the sizes of this viewport rectangle in pixels with Camera.pixelHeight; Camera.pixelWidth,...
FutureCake's user avatar
2 votes
0 answers
1k views

Unity Event after Layout update but before OnWillRenderObject()

Looking for subscribe-able event that occurs right after Layout update in Unity but before OnWillRenderObject is called. Working solution is Canvas.willRenderCanvases, but useful to know if more ...
James Linden's user avatar
2 votes
0 answers
452 views

Unity: onEditEnd and onSubmit only firing from Return key

I have an InputField in my UI, but currently I can only submit its contents via the Return key. I tried mapping other buttons to the Submit action (e.g. the tab key ...
eternal's user avatar
  • 341
2 votes
0 answers
496 views

Why are parts of this Unity scrollrect not being bound to the mask?

I'm setting up a system for people to load up extra levels. Since I don't know how many levels are going to be loaded I have a UI prefab that gets added to the main Level Load UI. However, the Text ...
Califer's user avatar
  • 433
2 votes
1 answer
2k views

Unity Grid Layout causing multiple draw calls

We are developing a game in Unity 4.6.6 for both Android and iOS. Currently I am building the game UI with the new Unity UI system. In particular I am building a button list to create kind of ...
VicM's user avatar
  • 121
1 vote
0 answers
220 views

Unity How to expand a child in a horizontal layout group to the left

I intend to hover over an item inside a Horizontal layout group and make it expand depending on its position within the carousel. I am able to expand the items upon hovering; however, I want the items ...
CraftedGaming's user avatar
1 vote
0 answers
104 views

Animate buttons sliding in

I am developing my first libGDX game. I want to animate the buttons on the stage, so they transition into view instead of just popping into appearance. For example, each button should slide in from ...
Zerg's user avatar
  • 11
1 vote
0 answers
193 views

How to tell which letter or vertex of a letter is at a certain screen position with a Unity UI Toolkit Label or TextElement?

I am using the Unity UI Toolkit and I would like to create my own TextField class (ie. input field, similar to the one I'm typing in now to write this message) with better functions using the Label ...
mike's user avatar
  • 481
1 vote
0 answers
985 views

Rendering 3D items in a GUI in Unreal Engine

I have various buildable 3D items in my game like so: These are just a few, but there will eventually be hundreds of them. The models of each of these items are displayed to the user as part of a ...
Drew's user avatar
  • 176
1 vote
0 answers
2k views

UE5 - stop hiding the Content Draw

Semi-Solution: Going to Window > Layout > UE4 Classic Layout opens out the content browser and other stuff without them closing down again. However, I'm still not sure how to set it to stay or ...
Candle's user avatar
  • 141
1 vote
0 answers
34 views

Editing an InputField on mobile with the keypad open, it wont let me edit another field without loosing focus on the current 1st. How to by pass?

When I'm typing into a tmp input field on a mobile keypad, I can't instantly edit another input field by clicking it!? I have to click off the keypad to loose focus on the current before I can click ...
riaan du toit's user avatar
1 vote
0 answers
2k views

Orientation changed event in Unity3D?

I'd like to listen to orientation change events, so for example my UI layout or the components themselves can be changed. All I've found is that I should check the value of ...
Tudvari's user avatar
  • 761
1 vote
0 answers
86 views

Horizontal scrollview only

I am using unity's scrollview. I want to disable the vertical scrollbar and i want the viewport to resize vertically depending on the content. Too confusing to explain with word so i have created the ...
i'm ashamed with what i asked's user avatar
1 vote
0 answers
884 views

Drawing rectangle around a target on screen

I am just started with Unity and C#. I need in my work to do rectangle on a scene. I have a 3D scene, say some warehouse and there is an object. Camera is animated and moving towards the object. Is it ...
Hillbilly Joe's user avatar
1 vote
0 answers
178 views

UI clicks hitting the GameObjects below

I've made a simple script which makes a mesh with a collider act like a button. However the mesh button get clicked through the UI. I figured out how to fix this in editor, however this problem still ...
tanya's user avatar
  • 11
1 vote
0 answers
653 views

What is the order of execution of OnClick and PointerUp in Unity?

I have an UI element in Unity with a Button and a Event Trigger component. The Button component calls a method when the OnClick event is triggered, and the Event Trigger component calls another method ...
John's user avatar
  • 11
1 vote
0 answers
970 views

Unity Input System On-Screen Button doesn't work with touchscreen 2019.3.2f1

I am trying to make my player jump whenever the space button is pressed (if a keyboard is present), and I'm adding a on-screen button for players on mobile. The on-screen button works fine in the ...
lsauceda's user avatar
  • 151
1 vote
0 answers
840 views

Unity calculate the size of a text box before text gets drawn so it can lerp to the next size

Im trying to make a dialog box image that lerps to the next size. In order to do that I need to calculate the size of the image before the text gets drawn. My idea is to use the legacy GUI stuff ...
BigDuke6's user avatar
1 vote
1 answer
188 views

Handling different aspect ratios on a 2D dodging game

I've been making a game where the player is on the ground and has to dodge objects falling to the ground. Since I'm using libGDX (But the question still applies to any other language/framework), The ...
Sarah's user avatar
  • 59
1 vote
0 answers
2k views

Using Unity Post Processing v2, how can I apply processing effects to just the UI?

I am using Unity 2018.3 with HDRP 4.9, and Post Processing 2.1.3. I would like to apply post processing effects (i.e bloom) to the UI only. I tried the 2 camera approach, but still can't get it ...
JacketPotatoeFan's user avatar
1 vote
0 answers
1k views

How to zoom image on Unity UI to particular point where mouse cursor is located?

I have some RectTransform on Unity UI. I have already implemented some Zoom functionality but now I need it to zoom to the area where the mouse cursor is located. Currently, it zooms to the anchor ...
Random generalist's user avatar
1 vote
0 answers
27 views

How to attach an UI button to a prefab and follow it in Unity2D

My plan is creating a button above my prefab (a tree) and whenever my character is detected, the button will appear and allow me to click on it to active a dialog. I just want my trees are randomly ...
adorablemelon's user avatar
1 vote
0 answers
716 views

How to sort cards' on-screen positions by their suit?

I have a 13 cards and sort button. When I click that button, I want all the cards of each suit to be grouped-together on screen. So if I have 4 diamond cards in my 13-card hand, all 4 diamonds must ...
Deepak Gaurav's user avatar
1 vote
0 answers
120 views

How can I render 3d objects over uGUI?

I have a scene with 3d objects but need uGUI as background. How can I achieve this?
questionasker's user avatar
1 vote
0 answers
286 views

Unity: redraw only part of the GUI

I am making an RTS game which currently has a very heavy GUI and takes up sometimes 50% of the CPU time per frame. Most of the data on the GUI remains constant, (selected units and their avalible ...
PStag's user avatar
  • 1,240
1 vote
0 answers
272 views

Image looks GOOD on the editor but BAD (blurry) on the HTML5 export

I have a red bar that looks good inside Unity editor, but when I export the build it looks very strange. Any idea on how to fix this? The image on the left is the one with the strange/bad looking red ...
Grow Animation's user avatar
1 vote
0 answers
70 views

Unity built-in Network Lobby How to move GUI?

I'm using built-in network manager HUD and I'm fine with it for now. But I can't move lobby GUI, only Network Manager HUD. Is there a way to move it down to make space for Title Art?
KiRa937's user avatar
  • 35
1 vote
0 answers
35 views

Unity: Retrieve animation names from imported blend file

I am just trying to generate a list from all animations within my Blender Asset file (see image) This is what I have so far: ...
Marten Zander's user avatar
1 vote
0 answers
121 views

Create button in NGUI

I try to create a button with the help of the NGUI. Here are screenshots of me doing that: So the problem here is the next. When clicking play button in game mode I hope to get the following line in ...
oobarbazanoo's user avatar
1 vote
0 answers
309 views

Execution order of uGUI events in Unity?

I'm trying to understand how UI events fit into the overall Unity update loop. Specifically, I want to manually call onClick via script, and then modify the effect ...
eternal's user avatar
  • 341
1 vote
0 answers
689 views

GuiSan | SDL2 - Setting colour key of render target results in having an black screen

At the moment i am experimenting with guisan within my little project. Everything is done sofar with SDL_Texture except Guisan which utilize SDL_Surfaces instead SDL_Texture for rendering itself. Per ...
ExOfDe's user avatar
  • 213
1 vote
0 answers
211 views

How can I prevent a GameObject within a ScrollView from moving?

I have a ScrollView. It has children, most of which I want to scroll, but some of which I want to remain still. Think of something along the lines of a spreadsheet where the title rows/columns don't ...
Evorlor's user avatar
  • 5,803
1 vote
0 answers
162 views

How to get what button was clicked on?

Other contexts in which this was done I'm sure have been answered for this kind of problem before. But this has thus far been a 2 week long impasse of wittling down all the other suggestions I've seen ...
blackhalo117's user avatar
1 vote
0 answers
317 views

Displaying an image when ScrollPane item is highlighted

I would like to have images displayed when an item in the list is highlighted as a form of a "preview" of the map that is selected. I'm not sure how i would implement this with clickListeners or ...
AllisterRegdarCrowley's user avatar
1 vote
0 answers
723 views

Unity Mask shows black content in world space canvas (Vuforia)

So I've built my scroll rect, like this reference tells me to do : http://docs.unity3d.com/Manual/script-ScrollRect.html -> Scroll View (Rect Transform with scroll rect attached) ---> Viewport (Image ...
TobiasW's user avatar
  • 987
1 vote
0 answers
58 views

Unity UI - Assigning Event Callbacks Via Script Fails for Objects Instantied by script

So I have a pretty basic tower defense game going on, there are set build points each with their own mini canvas UI for building and upgrading towers. Once you build a tower on them, they disappear ...
Nile's user avatar
  • 23
1 vote
0 answers
5k views

How does the Unreal Engine transaction (undo/redo) system work?

I would like the transaction system to handle the create/update/deletion of some custom objects. Then I can proceed as follow: ...
arthur.sw's user avatar
  • 291
1 vote
0 answers
69 views

Minecraft Crafting GUI weird bugs

I'm writing a Forge mod for Minecraft 1.8. When I'm pressing the 'z' key a 3x3 Crafting grid should open. In the KeyInputHandler I call ...
Nova Shadowflame's user avatar