This Level_Football community component allows you to configure game rules for the Crazy Football game.
|Ball1, Ball2, Ball3, Ball4||The object that represents a ball. You can have at most 4 balls in the game.|
|Sound object||An empty object that marks the audio position. The sound is played where the object sits. To make players hear the sound clearly, place the object close to the football field.|
|Blue team goal||The cube that represents the goal area for the blue team. The blue team scores 1 point each time a blue team player shoots the football in this area. To detect the ball, add a trigger box to the cube.|
|Red team goal||The cube that represents the goal area for the red team. The red team scores 1 point each time a red team player shoots the football in this area. To detect the ball, add a trigger box to the cube.|
|Shoot force||The force that a player applies to the ball when shooting it|
|Ball distance||The distance between the ball and the goal with which the player can shoot|
|Force on Y||Indicates how great the force on the Y axis is when a player shoots the ball.|
|Audio file||The sound for the game. Audio clip 1 is the sound of a goal. Audio clip 2 is the sound of shooting. Audio clip 3 is the sound played when the game is over.|
|Add players' position||Adds positions for players when the game starts.|
|Blue team position||The position of the player in the blue team|
|Red team position||The position of the player in the red team|
Note: As this is a global component, you can attach this component to any object in the scene. However, it's a best practice to create an empty object named "GameManager" and attach this component to it.
In the Crazy Football game, use UI_Football to provide UIs for the game.
To add visual effects for the players, place visual effects in the scene and attach the SpawnableObjectMarker component to them. In SpawnableObjectMarker, set the name to teamBlueFlag if you want the visual effect to display on the blue team players; set to teamRedFlag if you want the visual effect to display on the red team players.