Charcoal, 3838 37 bytes
XF³²«F…·±ιιF…·±ιι«Jκλ›⁼№KMX¹⁼KKX»UMKAXJ³¹¦³¹XF³²«UMKAXF⁶³F⁶³«Jκλ›⁼№KMX¹⁼KKX
Try it online!Try it online! Link is to verbose version of code. According to my comment on the Sandbox post I can do this in 37 bytes but unfortunately my computer rebooted to install updates and I didn't save my solution. Explanation:
XJ³¹¦³¹X
Output the central X
in the centre of the square.
F³²«
Grow the snowflake 31 times. (The firstlast loop has no effect since it only checks one squareis just used for its side-effect of replacing the -
s with X
s.)
F…·±ιιF…·±ιι«UMKAX
Check a larger square each time.Change all the (This is golfier than hardcoding-
s to X
s.
F⁶³F⁶³«
Iterate over the sizesquare.)
Jκλ
Jump to each position in the square.
›⁼№KMX¹⁼KKX
If the cell does not yet have an X
but it has one neighbouring X
then print a -
.
»UMKAX
After checking the square, change all the -
s to X
s.