Changing Cameras in Game

17.  Add a 2nd And Controller
  • Logic Editor >> Controllers >> Add Controllers >> And
Note:
  • When we add the second And Controller, it will added to State Mask Group 1. 
     
  • In a moment, we will change it so it belongs to State Mask Group 2.
18. Connect Keyboard Sensor to 2nd And Controller 
  • Keyboard Sensor >> And Controller
Note:
  • To connect logic bricks, pull the 'wire' from the logic brick output to a logic brick input.
19. Switch second And Controller to State Mask Group 2
  • 2nd And Controller >> State Mask Group Index
  • Select State Mask Group 2 button
Note:
  • The State Mask Group Panel is set to show only State Mask Group 1.
     
  • When you switch the second And Controller to State Mask Group 2, the second And Controller will "disappear". 
     
  • Sensors and Actuators can belong to more than one State Mask Group.
     
  • The Keyboard Sensor now belongs to State Mask Group 1 and State Mask Group 2.