Oh, one other thing. IT seems like it'd be a bit easier to use if Play was like start/stop, that way you could start, or stop it, without moving your finger.. lol
That's what I had thought too.
But this game is SO small and loops so fast after it pauses it it goes to the bottom of the program loops back to the top and finds your still holding your finger down and un-pauses it again. It's really quite annoying. So I programmed it this way.
That's what I had thought too.
But this game is SO small and loops so fast after it pauses it it goes to the bottom of the program loops back to the top and finds your still holding your finger down and un-pauses it again. It's really quite annoying. So I programmed it this way.
Use a boolean.
Declare something like:
bool pressed = false;
Now just modify your DPad.B(Play/Pause) code to look like this:
if (!pressed && GamePad.GetState(PlayerIndex.One).DPad.B == ButtonState.Pressed)
{
your code here
pressed = true;
}
if (pressed && GamePad.GetState(PlayerIndex.One).DPad.B == ButtonState.Released)
{
pressed = false;
}
What this does is it checks for a boolean to be false when pressing the button, if its false it carries the code under it out and then makes the boolean true therefore not letting it loop again until you release the button and it makes the boolean false again.
Use a boolean.
Declare something like:
bool pressed = false;
Now just modify your DPad.B(Play/Pause) code to look like this:
if (!pressed && GamePad.GetState(PlayerIndex.One).DPad.B == ButtonState.Pressed)
{
your code here
pressed = true;
}
if (pressed && GamePad.GetState(PlayerIndex.One).DPad.B == ButtonState.Released)
{
pressed = false;
}
What this does is it checks for a boolean to be false when pressing the button, if its false it carries the code under it out and then makes the boolean true therefore not letting it loop again until you release the button and it makes the boolean false again.
THANKS!
Works great.
Update: This will be used to make the music run smoother as well. So just hang on while I fix this.
Okay, so now, the timer doesn't lag for 100ms every time you adjust the music or volume. And now, because the play button now does play AND pause with no annoying mistakes, the center button is essentially useless. So i'm thinking about putting a menu in when you press it (mainly so I can extend my C# experience and learn something) But i'll try to add something like changing the background or something awesome like that. =D
This stopwatch is pretty, haha. Oh gosh, my Zune comes back to me from repair TOMORROW and then I can use all the spiffy new stuff that popped up as soon as it went kaput.
Great app. I've got a couple suggestions if you'd like:
First off, the skip keys are "backwards" (ie left should skip back and right should skip forwards).
Next, the volume's a bit funny. It's a bit annoying that it sets your current volume as "max", so you have to first turn up your Zune's volume before entering the app. The volume jumps are also a bit too large; if you could implement something similar to the Zune's native volume controls, that would be mighty good.
Finally, if you're missing something for the middle button, might I suggest that you put in some sort of music play/pause feature, either on the original play/pause button (and then put the timer play/pause on the middle button) or on the middle button (and keep the timer play/pause button the same).
Finally, I don't know if there's a way to turn the screen/backlight off, but if there is that'd be great, as if you're timing for extensive periods, I'd imagine it's quite a drain on the battery life.
Great work so far, though! Thanks so much (I've been using this timer for running, which is great, because I don't need to bring a watch now).
Great app. I've got a couple suggestions if you'd like:
First off, the skip keys are "backwards" (ie left should skip back and right should skip forwards).
Next, the volume's a bit funny. It's a bit annoying that it sets your current volume as "max", so you have to first turn up your Zune's volume before entering the app. The volume jumps are also a bit too large; if you could implement something similar to the Zune's native volume controls, that would be mighty good.
Finally, if you're missing something for the middle button, might I suggest that you put in some sort of music play/pause feature, either on the original play/pause button (and then put the timer play/pause on the middle button) or on the middle button (and keep the timer play/pause button the same).
Finally, I don't know if there's a way to turn the screen/backlight off, but if there is that'd be great, as if you're timing for extensive periods, I'd imagine it's quite a drain on the battery life.
Great work so far, though! Thanks so much (I've been using this timer for running, which is great, because I don't need to bring a watch now).
As for the right and left being reversed I had no idea.
I'll fix the volume adjuster.
I was planning on making a menu when you center click. Maybe to control what plays and such.
And, No there is no way to turn off the back light. XNA (currently) Forbids it.
Just one suggestion, could you please have like a time view as well at the bottom.
I'm tired of checking the seconds section and hours section every time and not say the time properly. for example, like 1:11:27:19
Hrs:minutes:seconds:milliseconds
And maybe another suggestion. Music playback while using the app.