✓ Accepted answer
This can be done very easily by creating a single value and adding to the value every time an egg is hatched.
local EggsHatched = workspace.Values.EggsHatched
EggsHatched += 1
If you want to read the value on the client put the NumberValue inside a place accessable to the client, such as ReplicatedStorage or Workspace.
When checking the clicks on the client you would need a remote event to communicate with the server about adding to the value. Read more about remote events here.
If you need this value to be saved i would suggest looking into the DataStoreService.
1 comment
ok so I tested it quickly with PlayerAdded and added 1, then I started a test server with multiple players and the value was the amount of players in game. so this seems to work. now I only need to save it and make it do what it has to do :D Thank you