Example: /stats entity @a set AffectedBlocks @a Test Updates a scoreboard objective named 'Test' for all players whenever a command is performed relative to them. The objective will update by the number of blocks affected by the command. Since the stat was set to AffectedBlocks, this means that if the command is /fill, it will update the objective for whoever is running the command (@a) by the number of blocks filled.