Interaction from the player that corresponds to action in the game. Or in simpler terms - pushing buttons!

learn more… | top users | synonyms

-1
votes
0answers
22 views

how to seperating raw input devices into classes?

Is there a way too seperate raw input keyboard, mouse and controller in classes so i can use them independent of each other(something like xinput for xbox controllers).
0
votes
2answers
55 views

Smooth input handling in Java [closed]

I am writing a Java game. My problem is to get a really smooth input. If I hit the key W the character has to go forwards, but if I hit A and release the W key, the character doesn't go left ways :( ...
0
votes
0answers
39 views

class instance issue

Currently, i am working on a project which deals with several parts. First, I want to interface with a Sidewinder Force Feedback 2 joystick in Unity using SharpDX and SharpDX.DirectInput libraries. ...
-1
votes
0answers
34 views

LWJGL - Keyboard.next() not firing

I am trying to make a class which will handle all of my inputs, however Keyboard.next() isn't returning true. Here is my code. while(Keyboard.next()) { if(Keyboard.getEventKey() == ...
1
vote
1answer
50 views

How do I make my SFML mouse position capture fast enough?

I'm new to game development and making a Pong clone in SFML. I am trying to set the screen's top and bottom as bounds for the paddle. Here is my attempt: #include "main.h" #include "objects.h" int ...
2
votes
0answers
51 views

Adding touch/click event to a bitmap in android

In my android game, there is a surfaceview which has 36 bitmaps drawn on it. I want to change the bitmaps when they are touched. Is there a way implement touch or click event to the bitmaps ? Adding ...
1
vote
1answer
57 views

XNA - Prevent Holding of Mouse Button as Part of an Input Handler Game Component

I'm using C# XNA 4.0 Refresh. I'm working to create an InputHandler Game Component for my XNA game to handle all of the keyboard and mouse input. I used SixOfElevens RPG Game Tutorial (Here - ...
1
vote
1answer
43 views

How can I check for key releases between keyReleased callbacks?

Slick2D's Input class has a isKeyPressed() method that returns a boolean value according to whether the specified key has been pressed. I want to check if a key has been released in the same fashion. ...
1
vote
1answer
120 views

How can I have human-readable key names in a configuration file?

Given a file mapping keys to controls, such as this: up w down s left a right d jump space run shift crouch ctrl The values need to be converted into game commands, ...
2
votes
1answer
65 views

Passing Input to Compute Shader

I am using D3D11 on D3D10 hardware, trying to get a very simple compute shader to run (my hardware supports cs_4_0). What is the best way to pass data to the compute shader? I've seen some samples ...
1
vote
1answer
135 views

Decoupling rendering pipeline (for UI responsiveness): Multithreading and multiple contexts?

Warning! Wall of text (see <TL;DR> paragraphs below for short version) I have been noticing something in quite many games (most recently in cutting-edge RTS games such as Uber Entertainment's ...
13
votes
2answers
482 views

How can I stop the player from drifting due to local input prediction when they stop?

I'm working on a 2D server-client multiplayer game engine (which you can try here). It uses WebRTC DataChannels. (The connections are peer-to-peer, but the host peer still acts as a server.) The ...
2
votes
1answer
187 views

does order of updates and renders matter?

I know in a game loop there needs to be an order like physics should update before rendering. So, I have created two separate functions: update and render and the game loops like below: ...
0
votes
1answer
92 views

How to handle simultaneous mouse and keyboard input with sdl?

I'm making a game in SDL2 that so far is basically just a top down shooter, where the player aims at the mouse. When I run the game, you can move properly and shoot properly, and shoot and move the ...
0
votes
2answers
178 views

How can I make my sprite jump up and move forward at the same time?

I'm trying to make a sprite's movements work. For some reason, he can only jump and then move, or move and then jump, but never at the same time. I'm using InputProcessor and a TiledMap system. ...
1
vote
1answer
305 views

Handling XBox 360 Controller Connections in LibGDX after Game has Started

I am currently making a game with the java library LibGDX and want to add XBox 360 controller support using the GDX-Controllers extension. At the moment I have a setup where I create a listener to ...
1
vote
2answers
135 views

Can I trigger input/controls via code?

I have the 3rd person controller in my game, which moves with the WASD keys. But since I am developing for a mobile release, I want touch controls. I have already the touch control-script in a new ...
0
votes
2answers
103 views

How can I access LWJGL's Keyboard from a thread other than the graphics thread?

I'm loving LWJGL, but have been running into a number of odd problems with it. Most of it seems to deal with the fact that OpenGL is a state-machine and was only ever meant to be accessed from a ...
2
votes
2answers
98 views

How do I smooth out of the effects of a too-sensitive control?

I have a game that takes input from a joystick. If you tilt the joystick right, the ship moves right linearly according to how much the joystick is tilted. So if you tilt the joystick twice as much ...
0
votes
1answer
125 views

LWJGL: Camera distance from image plane?

Let me paste some code before I ask the question... public static void createWindow(int[] args) { try { Display.setFullscreen(false); DisplayMode d[] = ...
0
votes
1answer
278 views

How to manage input state in Unity3D?

In Unity3D how do I manage input among many components, especially in relation to "blocking" input messages to certain components? To make my question clear, an example: Component 1: Input Manager ...
1
vote
0answers
69 views

The input doesn't recognize that I release the key? [closed]

I'm creating a window (JOptionPane), in response to a collision. However, if the player is holding a key down when the window pops up, the input doesn't trigger a key release when the key is released. ...
1
vote
2answers
143 views

Input of mouseclick not always registered in XNA Update method

I have a problem that not all inputs of my mouse events seem to be registered. The update logic is checking a 2 dimensional array of 10x10 . It's logic for a jewel matching game. So when i switch my ...
1
vote
1answer
115 views

Brief pause after keypress

After i press and hold the key it goes forward once then pauses for a second or less then goes forward on forever. My problem is the brief pause I cant locate the issue. Thanks for your help. ...
1
vote
1answer
62 views

All libGDX input statements are returning TRUE at once

I'm fooling around with Box2D and libGDX and running into a peculiar problem with polling for input. Here's the code for the Screen's render() loop: @Override public void render(float delta) { ...
0
votes
1answer
80 views

What input and window handler should I learn for complement OpenGL? [closed]

I have a good base in C++ programming and I did some 2D games using SDL. Now I want to start making 3D games, but as much as posible, I want to learn following the standars of the profesional ...
2
votes
3answers
244 views

What are reasons for input polling vs. input events?

I noticed people use both - but is there any empirical evidence when it's better to use one over the other? This is related but not quite a 'why use either' or even 'why use both': Polling vs event ...
0
votes
2answers
723 views

Detecting key press only once [duplicate]

Have a question on keyboard inputs. Currently I am using this method to read my input, Gdx.input.isKeyPressed(Input.Keys.A), it is working fine. But I do realized at times there are multiple instances ...
2
votes
1answer
341 views

How to implement input handling in a C game engine?

I am starting to learn C programming (though I have a lot of experience using higher-level languages). I want to write a game engine using C and OpenGL. I think I understand the graphics rendering ...
2
votes
1answer
148 views

When do you get Mouse.getstate().X or Y as negative?

I am creating a game in which I use a function: int x() { int px = 100; int pxend = 128; int xx = 0; for (int i = 0; i < 6; i++) ...
0
votes
0answers
14 views

Grab mouse input in OpenTK? [duplicate]

I've searched a lot on the Internet but I can't seem to find any code that works with the current OpenTK, that "grabs" the mouse input (just gives the delta-x and delta-y, for camera rotation for ...
1
vote
1answer
461 views

Entity Component Systems, Input, and Angry Birds!

I am using Artemis ECS. I have the very basics of a game already. I am now trying to determine how to gracefully handle input and to a lesser extent collisions. Some people say with ECSs, everything ...
4
votes
2answers
117 views

Asking the user to place the joystick in the center while calibrating

I would like to know why exactly calibration programs (usually?) ask the user to place the joystick in middle, that is: Why isn't moving the handle in a complete circle (usually?) enough to calibrate ...
3
votes
0answers
320 views

AndEngine- OnAreaTouched

In my AndEngine-based game there are a few sprites on the scene. One sprite acts as a surface and the rest of them are placed on top of this surface. I want to take unique actions whenever any of the ...
1
vote
1answer
171 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 ...
0
votes
1answer
266 views

Input events slow on unity Update function

I have this running on the Update() on Unity. I am trying to create a page swipe feature on my game, but the problem is there is a half second delay when printing "dragging" to "end drag" when I ...
1
vote
1answer
1k views

Registering InputListener in libGDX

I'm just getting started with libGDX and have run into a snag registering an InputListener for a button. I've gone through many examples and this code appears correct to me but the associated callback ...
0
votes
1answer
235 views

Design question: How to handle input more efficiently?

I'm designing a system to handle the keyboard input for my game. To get it more simple, I have a class that has two methods, KeyUp and KeyDown which tell me which key has been pressed, this is already ...
1
vote
1answer
120 views

Getting mousemovement despite mouselock - unity

I have lockcursor so the cursor doesn't leave the screen, but now i have to rotate an object based on mouse movement (think garrys mod item rotation) but the mouse cursor is obviusly locked to the ...
1
vote
2answers
175 views

How do you capture keyboard and mouse input for an HTML5 game?

Is there an accepted method for capturing player input in HTML5 games? I have seen several methods, and the browsers seem to be in varying states of implementation; On MDN they tell you not to use ...
1
vote
2answers
294 views

What is an acceptable input delay?

It is common knowledge that if the framerate of a game is over 25-30 fps, we humans perceive it as running smoothly (more is better but if it is above that it at least doesn't lag). Is there any ...
7
votes
2answers
1k views

Input management techniques in large games

Is there a standard technique for managing input in large games. Currently, in my project, all input handling is done in the game loop, like so: while(SDL_PollEvent(&event)){ ...
2
votes
3answers
215 views

How can we validate subjective inputs from a client?

Let's propose for a minute where we have a game using something like the Virtuix Omni. You track feet movement. You track the speed at which they run. Now, let's suppose we want to translate this into ...
0
votes
2answers
170 views

Gravity and collision detection interfering with player movement

I am attempting to implement collision detection for a 2d sidescroller game and I'm having trouble keeping gravity from interfering with player movement. Every frame I get and handle input, creating ...
1
vote
2answers
606 views

Entity system game design and input handler

I have started create a lightweight game engine with Ogre and C++. I have a abstract component class and an abstract entity class. #ifndef ENTITY_HPP_ #define ENTITY_HPP_ #include <string> ...
2
votes
2answers
624 views

LWJGL multiple keyboard/mouse input checks

As in many game libraries such as LWJGL, you can check mouse/keyboard events with Mouse.isButtonDown or Keyboard.IsKeyDown. I want to check for button/key presses, not if it's currently pressed down ...
4
votes
2answers
211 views

Manage user input and diffentiate it between the player and the app

I hope the title makes sense. Basically, I am trying to figure out how the app will know I the input I am sending it is meant for the app and not the player, and vice-versa. (It is very similar to ...
3
votes
1answer
177 views

Handling actions in component based multiplayer game

Please stay with me as I explain my question. I'm creating a multiplayer game. My design pattern follows broadly thoughts described in the post here. The idea is that each actor whether be it a ...
-1
votes
1answer
778 views

How can I support PS3 controllers in my Java game?

Is there a lightweight open source library that would allow me to get PS3 controller input and use it in a program (for OS X and Windows) that I am writing in Java? The alternatives I were looking at ...
4
votes
4answers
289 views

Networking gampeplay - Sending controller inputs vs. sending game actions

I'm reading about techniques for implementing game networking. Some of the resources i've read state that it is a common practice (at least for some games) to send the actual controller input across ...