POV-Ray : Newsgroups : povray.binaries.images : Alley Sunflower WIP : Re: Alley Sunflower WIP Server Time
2 Nov 2024 18:50:09 EDT (-0400)
  Re: Alley Sunflower WIP  
From: Nekar Xenos
Date: 28 Apr 2010 05:10:18
Message: <op.vbu7rcziufxv4h@go-dynamite>
On Wed, 28 Apr 2010 10:34:15 +0200, Dave Blandston <nomail@nomail> wrote:

> "Nekar Xenos" <nek### [at] gmailcom> wrote:
>> I still get 3 of the same bricks in a row. Any ideas on how to get it  
>> more
>> random?
>
> Besides not having the same brick appear twice in a row, you probably  
> don't want
> the same brick appearing directly above or below. One possible method  
> (although
> not as cool as the previous suggestion) could be to create a  
> two-dimensional
> array (or three-dimensional, if you also want to worry about the corners  
> of the
> wall). Assign a number to each brick type, and store that number in the
> corresponding array location as the bricks are placed in the wall. As  
> you add a
> new brick, compare the new brick type to the two bricks below and the one
> already placed on the same row. If the new brick matches any of the  
> already
> created bricks, select a different type and compare again.
>
> Regards,
> Dave Blandston
>
>

Hmm. There are 2 bricks above and 2 bricks below each brick and one on  
each side = 6 bricks. I'll have to make a larger variety of bricks!

-Nekar Xenos-


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.