Blockland Forums > Modification Help

Finding supported bricks

Pages: << < (3/6) > >>

Treynolds416:

I don't have an opportunity to use blockland until next weekend, so could somebody do that for me?

Also, I found the function willCauseChainKill, it appears to be a bool that tells if destroying one brick will destroy others as well. This is probably what the hammer uses though...

Greek2me:

Here's some useful functions:


Exposure:
%brick.getExposedAreaBottom() - ()
%brick.getExposedAreaEast() - ()
%brick.getExposedAreaNorth()
%brick.getExposedAreaSouth() - ()
%brick.getExposedAreaTop() - ()
%brick.getExposedAreaWest() - ()

%brick.iloveposed() - ()exposed = no bricks attached to one end

Up/Down Bricks
%brick.getUpBrick() - (int index)Returns up brick at given index.
%brick.getDownBrick() - (int index)Returns down brick at given index.
%brick.getNumDownBricks() - ()Returns number of bricks in downlist.
%brick.getNumUpBricks() - ()Returns number of bricks in uplist.

%brick.dumpDownList() - ()Dumps the downbrick list.
%brick.dumpUpList() - ()Dumps the upbrick list.

Path-to-Ground
%brick.getDistanceFromGround() - Returns number of connections away from the ground
%brick.hasFakePathToGround() - ()Returns true if brick is attached to a baseplate (considers blown-up bricks to be dead).
%brick.hasPathToGround() - ()Returns true if brick is attached to a baseplate.

%brick.willCauseChainKill() - () returns true if killing this brick will cause others to fall

Destiny/Zack0Wack0:

hasPathToGround should work.

Treynolds416:


--- Quote from: Destiny/Zack0Wack0 on April 28, 2012, 07:17:25 PM ---hasPathToGround should work.

--- End quote ---
It doesn't tell me which bricks will be destroyed. It will be helpful, but it's only a bool indicator.

Greek2me:

Look at these 2 functions, they might help you get an idea of what is supporting:
%brick.dumpDownList() - ()Dumps the downbrick list.
%brick.dumpUpList() - ()Dumps the upbrick list.

Pages: << < (3/6) > >>

Go to full version