I'm making an object, which, when created, spawns 4 other objects in 4 directions and passes them value, which is random between 5 and 10, minus one, or sometimes two. Then that new object creates another 4 objects and passes it's value minus one or two again. New object doesn't make another object if it's value is one. That way I'm trying to make mountains with random forms.
The problem is, the value is passed wrong, so it only shows up good when it sends it as message, but it's true value is 0. For example, after 3 generations of objects are made, initial one returns 7, another one 6 and third on -1.
Another thing is, I was forced into using different objects for different generations. When 2nd generation object tries to make another 2nd, i get loads of spam. If it tries to make 3rd, which is identical to 2nd, everything works fine
And last, I have a question. What would be best way to check if, for example, neighbor turf is /turf/cliff
My lame code: