week 6 lab 5

Seitman Lab 5 – Journal 6 – Controller

Objective:  To manipulate as many controllers as possible by building on the sensor lab we had the previous week.

Methods: To add a variety of controllers to my 3 cube scene with out creating logic errors.

The scene I had created previously had 3 cubes; a pink one, a yellow one, and a blue one.  The pink cube disappeared and reappeared based on its proximity to the others.

This week, I added additional controllers to the blue and yellow cubes.

For the yellow cube, I added an And and an Or. The sensor is the space bar with motion as the actuator.  The cube jumped up and down on the x axis.  I then added a rotation with the NOR controller,  but instead of linking it to the space bar I linked it to the up arrow. (Note – The And controller requires everything to be true and the Nor controller is its opposite, meaning it functions when nothing is true.)

Then I focused on the blue cube.  I again used the And controller with the space bar.  I again added motion.  In this case when the space bar is pressed (and set on tab) the blue cube sidled along the y axis.  I tried to add a Boolean property , and while it does show up in the sensor area as a toggle I don’t think it does anything.  There are a variety of other property options available as well. They include Float, String, Integer, and Timer.  For these, values must be assigned.  If you were designing a game, you could initiate a number of bullets, or send a text message, or time how long a character had special powers.

(Note – when you toggle something it turns on and it turns off when released.  It is not like a light switch.)

Result:  When I was finished I had a scene with three different cubes in it.  Each cube simultaneously does something (using Ands and Ors)  when the space bar is pressed and the yellow cube also rotates with the up arrow as a result of a Nor function.

 

 

 

Seitman Lab 5 – Journal 6 – Controllers

 

Objective:  To manipulate as many controllers as possible by building on the sensor lab we had the previous week.

 

 

Methods: To add a variety of controllers to my 3 cube scene with out creating logic errors.

 

The scene I had created previously had 3 cubes; a pink one, a yellow one, and a blue one.  The pink cube disappeared and reappeared based on its proximity to the others.

 

This week, I added additional controllers to the blue and yellow cubes.

 

For the yellow cube, I added an And and an Or. The sensor is the space bar with motion as the actuator.  The cube jumped up and down on the x axis.  I then

added a rotation with the NOR controller,  but instead of linking it to the space bar I linked it to the up arrow.

 

(Note – The And controller requires everything to be true and the Nor controller is its opposite, meaning it functions when nothing is true.)

 

Then I focused on the blue cube.  I again used the And controller with the space bar.  I again added motion.  In this case when the space bar is pressed (and set on tab) the blue cube sidled along the y axis.  I tried to add a Boolean property , and while it does show up in the sensor area as a toggle I don’t think it does anything.  There are a variety of other property options available as well. They include Float, String, Integer, and Timer.  For these, values must be assigned.  If you were designing a game, you could initiate a number of bullets, or send a text message, or time how long a character had special powers.

 

(Note – when you toggle something it turns on and it turns off when released.  It is not like a light switch.)

 

Result:  When I was finished I had a scene with three different cubes in it.  Each cube simultaneously does something (using Ands and Ors)  when the space bar is pressed and the yellow cube also rotates with the up arrow as a result of a Nor function.

 

 

 

 

 

 

 

 

 

 

 

 

 

This entry was posted in Uncategorized. Bookmark the permalink.