Author Topic: Detecting Certain Bricks  (Read 732 times)

Hello all. I'm new to coding, and so far, all of my scripts have failed. I've been trying over and over to make a script that will show up in my Add-Ons list. Not yet.

I was wondering if there was a way to detect a certain kind of brick. For example, lets say I was making a code where I turned all trees in the server red. How would I scan the bricks for trees?

Thanks.

Goes in coding help

but anyway, if you mean the treebrick, then you would loop through all the bricks in the server and compare their datablocks, and if the're the same then change the color.

If you mean trees made of many bricks, well that's an entirely different task...

if you mean the treebrick, then you would loop through all the bricks in the server and compare their datablocks, and if the're the same then change the color.

If you mean trees made of many bricks, well that's an entirely different task...

Like I said, I'm new to coding. I've been studying it and get it, but I don't know any of the commands besides function, which I understand. I don't know how to run a loop through all the bricks. What is the code for that?
« Last Edit: September 16, 2012, 09:55:13 AM by Miner Blockman »