Welcome, Guest

Author Topic: Fixing Missed Mouse Clicks  (Read 7605 times)

Dan Dixon

  • Creator of Universe Sandbox
  • Developer
  • *****
  • Posts: 3244
    • Personal Site
Fixing Missed Mouse Clicks
« on: November 23, 2010, 09:20:43 PM »
I've just spent all day modifying the input system (what handles mouse clicks) so that even when the simulation is running really slow Universe Sandbox will no longer ignore your mouse clicks.

Now it saves them up and dishes them out one frame at a time.

Have you noticed that sometimes you have to click more than once on something for it to select or change? No longer... (after the next update)

Chaotic Cow

  • Universe Sandbox 1 Beta Team
  • *****
  • Posts: 588
  • President of Bovine Relations
    • Facebook
Re: Fixing Missed Mouse Clicks
« Reply #1 on: November 24, 2010, 07:50:48 AM »
Never had the problem but AWESOME!

deoxy99

  • Universe Sandbox 1 Beta Team
  • *****
  • Posts: 872
  • ✨ the name's verb ✨
Re: Fixing Missed Mouse Clicks
« Reply #2 on: November 24, 2010, 09:36:49 AM »
I have had the problem forever since Universe Sandbox 2 was released, so that sounds great.

Dan Dixon

  • Creator of Universe Sandbox
  • Developer
  • *****
  • Posts: 3244
    • Personal Site
Re: Fixing Missed Mouse Clicks
« Reply #3 on: November 24, 2010, 01:25:09 PM »
Never had the problem but AWESOME!

I imagine that, like me, you don't notice the problem and just click again instinctively. This is why I've ignored the problem for so long, even though it's been an issue since the beginning.

atomic7732

  • Global Moderator
  • *****
  • Posts: 3849
  • caught in the river turning blue
    • Paladin of Storms
Re: Fixing Missed Mouse Clicks
« Reply #4 on: November 24, 2010, 04:02:57 PM »
I've had that problem forever!

deoxy99

  • Universe Sandbox 1 Beta Team
  • *****
  • Posts: 872
  • ✨ the name's verb ✨
Re: Fixing Missed Mouse Clicks
« Reply #5 on: November 24, 2010, 04:40:47 PM »
I've had that problem forever!
I have had the problem forever too!

Darvince

  • *****
  • Posts: 1842
  • 差不多
Re: Fixing Missed Mouse Clicks
« Reply #6 on: November 24, 2010, 04:47:19 PM »
I've had that problem forever!
I have had the problem forever too!

I think you just posted the same thing twice.  :P And I haven't noticed it becasue I try to keep the number of objects in the simulation down.

Bla

  • Global Moderator
  • *****
  • Posts: 1013
  • The stars died so you can live.
Re: Fixing Missed Mouse Clicks
« Reply #7 on: November 27, 2010, 11:17:24 AM »
If it's the problem that occurs when the simulation needs to make a lot of calculations, so it takes a while before the buttons respond when you click them etc. (so you have to hold down the mouse button for them to notice the click), and it's fixed, awesome. :)
Otherwise, awesome. :)

Dan Dixon

  • Creator of Universe Sandbox
  • Developer
  • *****
  • Posts: 3244
    • Personal Site
Re: Fixing Missed Mouse Clicks
« Reply #8 on: November 27, 2010, 06:23:12 PM »
(so you have to hold down the mouse button for them to notice the click)

Yes. That's exactly the problem I've fixed. Now even if it's running at something really slow (and seemingly unusable) like 1 frame per second it still detects fast clicks.

What I'm now doing is running the input detection on a separate thread and saving the mouse click down, mouse click up commands as they come in. Only when the main program is ready for them do I pass those commands along one at a time.
« Last Edit: November 27, 2010, 08:52:33 PM by Dan Dixon »

Dan Dixon

  • Creator of Universe Sandbox
  • Developer
  • *****
  • Posts: 3244
    • Personal Site
Re: Fixing Missed Mouse Clicks
« Reply #9 on: January 20, 2011, 05:10:30 PM »
Does this problem appear to be solved for everyone in the latest release (2.0.14) ?