Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.help > #1344
| From | "John B. Matthews" <nospam@nospam.invalid> |
|---|---|
| Newsgroups | comp.lang.java.help |
| Subject | Re: Reseting the ball after changes |
| Date | 2011-11-15 11:51 -0500 |
| Organization | The Wasteland |
| Message-ID | <nospam-545B37.11514815112011@news.aioe.org> (permalink) |
| References | <1bebffda-d16a-4cb0-b443-6fab7306b8fc@g21g2000yqc.googlegroups.com> |
In article <1bebffda-d16a-4cb0-b443-6fab7306b8fc@g21g2000yqc.googlegroups.com>, Michael Adedeji <yankosmgt@gmail.com> wrote: > I have done the menu, but I have problem with reseting of the ball, > everytime I change the size or the speed of the ball, it kind of > change the way the sounds works. I kinda figure out that I need to > reset it everytime I change the size or the speed of the ball. Exactly, you're changing the (implicit) model's state behind the view's back. > Does anyone have an idea how I could go about it. I'd reiterate my earlier suggestion on MVC [1]; it's time to re-factor. As an alternative, the example cited adjusts the Timer's rate, rather than the velocity's norm. A similar problem arises when the simulated boundary is resized; the model has a corresponding setWalls() method. [1] <https://groups.google.com/d/msg/comp.lang.java.help/u2r-L6H_kD4/t2Q165gnOM8J> -- John B. Matthews trashgod at gmail dot com <http://sites.google.com/site/drjohnbmatthews>
Back to comp.lang.java.help | Previous | Next — Previous in thread | Next in thread | Find similar
Reseting the ball after changes Michael Adedeji <yankosmgt@gmail.com> - 2011-11-14 05:14 -0800
Re: Reseting the ball after changes "John B. Matthews" <nospam@nospam.invalid> - 2011-11-15 11:51 -0500
Re: Reseting the ball after changes Michael Adedeji <yankosmgt@gmail.com> - 2011-11-15 13:14 -0800
Re: Reseting the ball after changes Michael Adedeji <yankosmgt@gmail.com> - 2011-11-15 16:34 -0800
Re: Reseting the ball after changes "John B. Matthews" <nospam@nospam.invalid> - 2011-11-16 00:17 -0500
Re: Reseting the ball after changes Michael Adedeji <yankosmgt@gmail.com> - 2011-11-16 02:32 -0800
Re: Reseting the ball after changes "John B. Matthews" <nospam@nospam.invalid> - 2011-11-16 10:37 -0500
csiph-web