I have been trying to prevent players to break spawn but how can I and I am also asking how do you set spawn for everyone?
From the Wiki:
default value: 16
Determines the radius of the spawn protection. Setting this to 0 will not disable spawn protection. 0 will protect the single block at the spawn point. 1 will protect a 3x3 area centered on the spawn point. 2 will protect 5x5, 3 will protect 7x7, etc. This option is not generated on the first server start and appears when the first player joins. If there are no ops set on the server, the spawn protection will be disabled automatically.
Add a line to the
server.properties file of your server, and put
This will set an area around your spawnpoint that only OPs can interfere with (this includes opening chests, breaking and placing blocks). You can change the
10 to any suitable number to fit your setup, so long as it remains an integer.
As this appears to have plugins on it, I would recommend getting WorldGuard (or similar). This way you can select what regions of the world can be modified in which ways.