Input is data provided to a game via player interaction (through the mouse, keyboard, gamepad, et cetera).

learn more… | top users | synonyms

0
votes
0answers
31 views

LibGDX with Parallax Camera, unable to accurately select objects

So, basically I borrowed the ParallaxCamera test that LibGDX provides and got the camera set up rather nicely. However, I noticed that when I specify a speed other than 1, my game objects shifted ...
1
vote
1answer
11 views

Unity: Can't access repeatDelay from StandaloneInputModule?

I have a very specific problem. I'm trying to change the repeatDelay variable within my StandaloneInputModule, but it's not coming up as a variable. All of the other variables come up when I use ...
1
vote
1answer
59 views

Event-/Input system with SFML: Cannot move diagonally in 2D

I am a beginner in anything with game development. I written a small prototype in which i can move a square around with the arrow keys. For that i use SFML. At the moment i experiment around with my ...
2
votes
1answer
30 views

GetButtonDown for Unity keyboard UI navigation?

By default, Unity's keyboard navigation for buttons seems to check for GetButton rather than GetButtonDown--if a menu has 5 items and I hold the down arrow, it'll scroll very quickly to the bottom. ...
0
votes
1answer
65 views

Game Controller that is constantly changing

I'm writing a game where the main character is a ghost, and therefor can possess just about everything. The problem is, I'm not sure how to efficiently & effectively handle the changing actions of ...
0
votes
0answers
30 views

Unity Input manager with chain of responsibility and delegates

I am working with unity and I am trying to build a better input system for my game. In essence there would be a singleton class that is the input manager. The player would subscribe to the manager ...
0
votes
1answer
30 views

Unity3D - Change player input axes on trigger

Hope someone can help me with this, it seems like it should be a simple problem but that only makes it more frustrating! I have a simple game where you roll a ball around by applying force to the ...
0
votes
2answers
44 views

How can you have the Input Manager Axis values snap to 1 (or -1)?

When a selected key is pressed in Unity, the Input Manager's Input.GetAxis("Horizontal") function returns a gradually increasing number up to 1 (or negatively -1) for the length it is held down. The ...
1
vote
1answer
43 views

Actor not taking touch libGDX

I am trying to handle the touch of one of the Actors in the stage. The following is the code I have written: public class MyGame extends ApplicationAdapter { private GameStage gameStage; //Game ...
0
votes
0answers
19 views

In HLSL pixel shader, why am I getting [-256.0, 256.0] values in SV_POSITION input?

My question is basically in my DirectX11 pixel shader, why am I getting a range of values from -256.0 to 256.0 in the SV_POSITION input instead of the supposed values from 0.0 to ViewportWidth and 0.0 ...
1
vote
0answers
40 views

How do I manually submit a new UI InputField in code?

I need some conditions for submitting the text inside of an Inputfield, however I cannot find a way to do this via code. I was expecting something simple like with WPF or WinForms, but I cannot find ...
0
votes
1answer
42 views

Given a constant rotation and target point, find position so that point will be in camera center

Given a fixed rotation and a target "center" point, how to I find the position the camera should be in so that that point is the center? LookAt changes the rotation keeping the position constant. ...
0
votes
1answer
110 views

Handling input with callback functions

I'm not sure if I understand callback functions completely - they are functions that another function calls? This seems like a powerful tool, especially w/r/t handling input. I've written up this ...
0
votes
0answers
21 views

Change pointerDrag target during a drag

In Unity, I am trying to change which GameObject is receiving drag messages from my EventSystem's StandaloneTouchInputModule. E.g., while I'm dragging one object, a script reassigns who is receiving ...
0
votes
1answer
54 views

Button image on game menu is updating too slow

I'm using SDL2 and i'm facing a problem with my game menu buttons. Every time i detect that the mouse pointer is over a button of the menu i update the image of the button (from MOUSE_OUT to ...
0
votes
1answer
32 views

Making a ordered list iterator [closed]

Noob here, I am trying to display a list of a vector with ascending numbers. To display the list I iterate through the following code. cout << "\nYour games list is: \n"; for (iter = ...
1
vote
2answers
37 views

Flushing KeyboardState

I'm using a simple InputManager class for an XNA game with keyboardState and lastKeyboardState that gets updated and has KeyDown/KeyReleased/KeyPressed functions... but ran into a small problem: I ...
1
vote
0answers
58 views

Proper joystick input processing

Take for example, the Xbox One controller. XInput returns joystick input along 2 axis (x & y). I'm not sure if the hardware just measures voltage across 2 axis or not, I'm not very knowledgeable ...
-1
votes
1answer
50 views

Sprite movement only works the first time, can't figure out why [closed]

In my libGDX game I have finally managed to get the sprite to move the way I want him to but for some reason my desired outcome only works the first time I run the code. If I try to run it again, he ...
0
votes
1answer
85 views

LibGDX how to efficiently handle button presses

I'm making a simple 2D game for android using LibGDX. My game needs to have many buttons in it that fire off a method when pressed, and I was wondering what the best way to do this would be. I tried ...
0
votes
1answer
133 views

Unity3d - c# - changing FPSInputController controls through script

For a game I am making I would like the user to be able to change the controls (in game NOT through the clunky launch window (wich i disabled)) I have the system working but don't know how to change ...
-1
votes
1answer
79 views

How can I implement input handling into my game?

I'm making a libgdx game where the player dodges falling objects. To move the player I have it set so that on desktop he moves left and right when you press A and D respectively. I am trying to ...
2
votes
1answer
90 views

Unity joystick input acting strange

After setting up my joystick axes in Unity and sweeping them around I find that the Y-axis jumps to the opposite direction in certain positions. So, when I press up on the joystick, the input will ...
0
votes
1answer
76 views

In Unity, how can I check if an input was made x seconds/frames ago?

I'm using the Rewired input plugin, and it comes with an input buffer. I enabled the buffer for my directional keys and airdash button so that the player doesn't have to hit both keys on the same ...
8
votes
2answers
877 views

Unity 3d 4 players Only 4 buttons can be pressed at a time

Only 4 buttons can be pressed at a time, so players cant move sometimes Each Player Has their own Controls i Change, Up Arrow and the other ones for each player---v InputsV-V-V public string ...
0
votes
3answers
126 views

What are real world uses of secondary key bindings?

I'm currently wondering if there's really a reasonable use that would justify making the effort of implementing secondary key bindings? If you don't know what they are: They allow multiple controls ...
1
vote
0answers
64 views

How can I hook up player input to an action in RPGMaker?

How do I set a player input to perform an animation such as swinging a sword. I tried doing it by creating a parallel process in which hitting z calls the following common event. Change Party ...
0
votes
2answers
161 views

Better ways to parse text adventure commands? [duplicate]

Currently I have got a system set up where I split each sentence handed to me into it's baser parts and then compare each word against a list of known words. Once I have the verbs, adjectives and ...
2
votes
1answer
140 views

How can I support multiple player inputs in Pygame?

I'm trying to develop a team-based Asteroids game. It's going well except for the "multiple user inputs to a single machine" part. Can anyone recommend a method for getting and updating 6 players ...
1
vote
1answer
96 views

Reference keyboard keys as “justPressed”, “pressed”, and “justReleased” with SDL in C++

I'm teaching myself 3D graphics with OpenGL and SDL in C++. I'm at a point where I need to be able to query states of individual keys, like so: if (InputManager::justPressed(SDLK_UP)) {} if ...
1
vote
0answers
193 views

In GM Studio, how do I prompt the player for a password?

I could make strings in earlier Game maker versions, but it doesn't work in the Studio version when I try. The code I used: When Left Mouse Clicked on Password Bar: var str; str=get_string("Crack ...
32
votes
6answers
5k views

Can I (safely) assume that people playing my game have a middle mouse button?

The title pretty much says it all. I am currently writing a desktop game, which will probably not be played by the casual gamer. Thus my expectation is that nearly every user will most likely ...
1
vote
3answers
230 views

Problem getting mouse events while keys held down in SDL2

I'm attempting to write input capturing code using SDL2 on Windows. However, I'm running into a problem. Whenever a key is held down, the SDL event queue has no mouse movement, nor will the mouse ...
0
votes
0answers
258 views

Unity3D C#: How to resize an inputfield according the content which is set dynamic

I've got an InputField where the text is filled in upon getting a string back from the server. We can debug the entire text so we receive it correctly. However the text is too long to fit in our ...
0
votes
0answers
53 views

Removing extra blank window when adding Jmonkey based sound to Java based game

I'm currently programming a simple run and jump game in java. I'm in the process of implementing sound and I'd like to use Jmonkey's sound because I'd like to eventually switch the whole game over to ...
1
vote
1answer
106 views

How to handle input in Monogame

I've just switched over to MonoGame from XNA. Since MonoGame is supposed to have the same API (implying that any copied code should work as usual), I've run into a strange issue- input doesn't seem to ...
0
votes
2answers
234 views

Handling player and AI in a component based structure dynamically?

I'm trying to find a way to allow both input and AI to call actions of an actor in a component based structure for a 2d turn based game. The actions make use of the components. To keep the system ...
1
vote
1answer
1k views

Getting a pixel of Sprite at the cursor position in Unity

Summary: I've been trying to figure out a way to use simple box colliders as a nice and efficient "first pass" collider. For the "second pass", I want to check that the area clicked has an alpha value ...
0
votes
0answers
44 views

how to disable touch in Quintus?

hi i'm new in web games development and trying to build card game using the Quintus game engine i have object called card i can touch and drag it in the screen but i want just to touch and drag it one ...
0
votes
1answer
76 views

Checking whether a specific key was pressed in enchantJS

I am using enchantJS and would like to use the letters and numbers as well as numpad on a keyboard to do different things (eg: hotkeys). From this page ...
1
vote
5answers
91 views

What to do with input during movement?

In a concept I'm working on, the player can move from one position in a grid to the next. Once movement starts it can't be changed and takes a predetermined amount of time to finish (about a quarter ...
0
votes
0answers
47 views

How do I simultaneously capture and play sound with SlimDX/DIrectSound?

Is it possible to simultaneously capture microphone input and play back some other sound, using DirectSound via SlimDX? How?
0
votes
1answer
133 views

Press multiple switches to unlock the door

I made 2 scripts, one that is a switcher and one that checks if object is switched (Switch, SwitchCheck). Switch script (it's on 2 objects that are switches and both objects have colliders with ...
0
votes
1answer
31 views

Moving multiple hingejoints based on joystick input

I'm controlling a 2D side-viewed (facing right) stickman with a joystick. The movements are fairly intuitive: Joystick down -> Stickman crouches down Joystick up -> Stickman stretches out ...
12
votes
3answers
259 views

Player fatigue for tablets?

I'm thinking about making games for tablets. Coming from a PC/console background, I'm keenly aware of the huge differences in the user interfaces, and that I need to design it with the target platform ...
0
votes
1answer
509 views

C++ timer function acts as if time limit is instantly reached if it is less than 1 second [closed]

I'm trying to make a Snake clone with C++ and OpenGL/GLUT, but I've been having trouble with programming the timed input. I made a timer class, as you'll see below, to be used for the short time ...
1
vote
1answer
248 views

game server/client user input/event handling

I'm currently getting my feet wet in the realm of networking, so I set a goal to make a simple client/server game using SFML for both graphics and networking. In my head it seemed easy at first, but ...
2
votes
2answers
740 views

Act on Right Mouse Button click on Button

I want to be able to listen for a right mouse click onto a TextButton. Is this possible without removing the default ClickListener of the TextButton? If yes, how? Or should I use a different listener? ...
0
votes
2answers
375 views

Problem with moving player through a secript by a set distance

I am currently trying to add a sort of "dash"-ability to my sidescroller. What I try to do, is to let the player press a key where a simple key-press causes the player to move quickly into one ...
1
vote
1answer
250 views

Input handling between game loops

This may be obvious and trivial for you but as I am a newbie in programming I come with a specific question. I have three loops in my game engine which are input-loop, update-loop and render-loop. ...