I'm completely confused.
I just tried to make my Procedural tile map generation. there is a tile object with 3 frames.
for x from 0 to 10
for y from 0 to 10
create tile to loopindex(x), loopindex(y)
stop animation
tile.frame = random(3)
set animation frame to tile.frame
It creates random framed map.
Now I want to make
(Neither I can't get chess.chess.UID's sub properties nor loopindex(x)-1. sub properties)
compare loopindex(x)-1.tile.frame not equal loopindex(x).tile frame then
global.randomize50 = random(1)
if global.randomize50 = 1 then
loopindex(x).set animation frame = loopindex(x)-1.tile.frame
Which I try to do is if a tile is frame 1 then %50 chanse for tile which is on right is also frame 1.
Maybe I don't have enough english to explain my self. Sorry about that.
I just tried to make smth like perlin. Like stones pile up somewhere, irons pile up somewhere else (with high probability)
----------------------------------
I know I really have to learn math. I unfortunately suck at math.
my second problem is, Is there anyway to do smth like
if there is tile.frame = 2 then
for 5 squares range there is not another tile.frame = 2
maybe this is not the place to ask these questions. I wish if there was a way to get object's property's with for example
Chess.Chess.DIR2UID(2,0).private variable
But I can't access to exact tiles while on for condition.
Sorry to disturb.
Thanks for any advice