Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles

unity-wave-function-collapse

unity procedural level generation with the Wave Function Collapse algorithms · By selfsame

Pre-set tiles for simple WFC?

A topic by Bamboy created May 21, 2017 Views: 373 Replies: 2
Viewing posts 1 to 3

Is doing this sort of thing currently supported in any way for simple WFC?

Developer

Hmm it should be possible, but i've never tried to set it up.

Here's a comment about setting up constraints: https://github.com/mxgmn/WaveF...

I think the trick is to figure out the index of the desired tile, then in the wave array set that index to true and the rest to false for the desired tile. I also think the "while(Propagate())" has to be done before calling  "Run(seed, limit)" to finish the output

from the unity component, you can access the underlying model ( SimpleTiledWFC.model ), which will have the "wave" array and "Propagate" method

Oh, also i think setting up manual constraints would have to happen between these lines:

https://github.com/selfsame/un...

I'll have to tinker with it when I get free time again. Thank you for your time. ^_^