How to make the goals active ? for 2 players and single player

ST1031130083ST1031130083 Member Posts: 10

How to make the goals active ? for 2 players and single player

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    You'll need to provide more details about what you are wanting to do.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • ST1031130083ST1031130083 Member Posts: 10

    @tatiang I have pictures of goals and I want player 1 when he shot ball on the goal, he gets the score and the ball goes to player2 and same as player 2 when he shot ball on player 1 goal. Like soccer game. How to do it ?

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    Make an integer game attribute called game.currentPlayer and give it a value of 1. When the current player shoots the ball, change attribute game.currentPlayer to 3-game.currentPlayer. This will cycle the value between 1 and 2.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • ST1031130083ST1031130083 Member Posts: 10

    @tatiang Thanks :smile:

Sign In or Register to comment.