Newbie With Urgent Mindstorms 2.0 Ballshooter Question

Discussion specific to NXT-G, NXC, NBC, RobotC, Lejos, and more.
inxt-generation
Posts: 290
Joined: 03 Oct 2011, 00:06
Location: Gallifrey
Contact:

Re: Newbie With Urgent Mindstorms 2.0 Ballshooter Question

Post by inxt-generation »

I see the problem, and can understand why it happened. You didn't put the "intruder" switch block inside the repeat forever loop. It didn't do anything because there wasn't anything in the loop. And since it was set to loop forever, the code never moved on. Even if it had, the switch would execute once and then the program would end, because there was nothing to keep it going. Everything else is fine. They shouldn't have zoomed the view in so far, then it would be easier to see the structure of the blocks. I attached the fixed program.
Attachments
Shooterbot V2.rbt
Fixed!
(849.21 KiB) Downloaded 250 times
A.K.A. NeXT-Generation.
"A kingdom of heaven for RobotC now has recursion!"
kartman01
Posts: 7
Joined: 30 Dec 2011, 02:53

Re: Newbie With Urgent Mindstorms 2.0 Ballshooter Question

Post by kartman01 »

inxt-generation:
Thank you so much for your help on this! I will download the new program tonight and I will let you know how it works...

Thank you. :-)
kartman01
Posts: 7
Joined: 30 Dec 2011, 02:53

Re: Newbie With Urgent Mindstorms 2.0 Ballshooter Question

Post by kartman01 »

inxt-generation:

It works! It works GREAT!!!

Thank you SO much for helping us out! I hope you are available for 'consulting' as we continue to learn our way around programming Lego NXT...

I hope you have a great New Year! :-)
inxt-generation
Posts: 290
Joined: 03 Oct 2011, 00:06
Location: Gallifrey
Contact:

Re: Newbie With Urgent Mindstorms 2.0 Ballshooter Question

Post by inxt-generation »

kartman01 wrote:inxt-generation:

It works! It works GREAT!!!

Thank you SO much for helping us out! I hope you are available for 'consulting' as we continue to learn our way around programming Lego NXT...
Your welcome. Glad I could help. If I see a question that I can answer, I usually do.
kartman01 wrote:I hope you have a great New Year! :-)
And the same to you!!
A.K.A. NeXT-Generation.
"A kingdom of heaven for RobotC now has recursion!"
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests