Have fun with a colleague during break time with this web-based game. There are two people playing game. each people uses two buttons to control direction of goalkeepers. Therefore, we need four buttons. Arduino reads the states of four buttons, If any of them is changed, Arduino will re-calculated the moving direction of goalkeeper and send the direction values to PHPoC WiFi Shield. When receiving the values, PHPoC WiFi Shield send it to Web Browser via websocket. JavaScript function will update the moving direction of goalkeepers. JavaScript program will continuously update position of ball, goalkeepers and obstacles based on their direction and check collision as well. Direction of goalkeepers are changed based on the state of buttons. “

Link

Related Content