TheSwamp

CAD Forums => CAD General => Dynamic Blocks => Topic started by: James Cannon on May 28, 2009, 10:45:42 AM

Title: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 10:45:42 AM
Currently it only lets me have one visibility state in a block.

PLEASE tell me there is some way to work around this?

The example I have is basic.  I have a 6"-nominal wall in plan consisting of 3 lines, (2)extents + (1)centerline, each 1" long.  Stretch parameter let's me make the wall longer.

At the end of those 3 lines are 3 more lines.  a 6" line extending each of the wall-extents line, and a 3" line extending the centerline.  I have a visibility state that allows me to turn on-or-off each of the 6" extensions.  Turning off one extension leaves a 45%%d miter to the wall (left or right) for instersections.  Turning off both of those extension lines creates a "Tee" situation.

Now... I'd also like to be able to add a SECOND visibility state for various hatchings.  I want to be able to add insulation batting, solid hatch for fire-rated walls, or other misc. hatches for special scenarios such as 'gas tight' or 'fire resistant' walls.

Is there any way to have separate Visilbity states to control that?
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 10:54:26 AM
You can probably accomplish it with a LOOKUP TABLE.  I messed around with them a while ago - I'll have to check if I have those blocks again.
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 10:58:30 AM
Couldn't find the block, but found this thread.

http://www.theswamp.org/index.php?topic=18535.0
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 11:06:50 AM
Couldn't find the block, but found this thread.

http://www.theswamp.org/index.php?topic=18535.0

Yea I was reading through that... Saw Cory's post in the Autodesk Discussion Groups helping someone else with a similar issue, and eventually linked back to that thread... but I guess I had trouble following it's logic or seeing how it'd fit for my example.

I'm very inexperienced with the Lookup dealio, so I'll start reading about it and trying some things and find out.
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 11:09:43 AM
Can you post what you have now and also what you want to include in the block?  I _think_ I understand what you want to do but....
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 11:18:57 AM
Can you post what you have now and also what you want to include in the block?  I _think_ I understand what you want to do but....
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 11:54:12 AM
OK, the basics of this are that you will need to create a visibility state for every combination you want to show.  Also create a visibility state for each catagory of states (i.e. hatched, not hatched). 
Then create a lookup table that points to the "catagories" (i.e. hatched, not hatched, etc)
This will point to the  "root" visiblity states your created.
In these root visibility states you will have a lookup table in each that points to all the visibility states you want to be able to select from for that catagory.
Do that for each catagory and then go back and delete only the grip for your visibility state action.

it will be easier to learn to use bvshow and bvhide at the command line to manage visibility for objects then the hide show buttons.

Its confusing at first, but not too hard.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 12:01:47 PM
After looking through the help file on 'lookup parameter' and seeing how Mr Cory's example block worked in the thread Matt linked...

...I see how to do it.

I currently can think of 3 possible hatchings, maybe 4, so combined with 4 end-wall-treatments (not counting the "ALL SHOWN" I always put in my blocks) that's gonna be a PITA to make.

BUT.  It will be worth it in the end, I think, and I currently have some time to spend making the block.

Thank you Shiny, Matt, and (even in absence) Cory.
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 12:03:57 PM
Heres a pretty simple version of how I do it.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 12:59:56 PM
I'm losing it.

I had everything set up.

I have the lookups set up.

The execution fails though.

I can't see how to be able to make one Lookup be "left / right / end / tee" and the other be "solid / ansi31 / insulated / no hatch" and have it somehow add those together to make "Left - Solid" or "End - Insulated" from the 2 Lookup selections.


Block progress attached:
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 01:54:30 PM
OK, you can't "stack" the visibility states, rather you have to use them so that you select one first, then the next.

I see what you mean by a single state, for what your after, that is your limitation.

lookup tables are an "OR" not an "AND"

you would have to have one table (say for the hatching) that the user selects,
THEN they would select the configuration options.
you need to reference a seperate state for every combination.

Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 02:19:22 PM
I'm not sure what you mean, I guess... rather, I'm not sure how to do what you're telling me.

I have a separate visibility state for every combination.

I am just not sure how to make it choose between them, I guess.
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 03:10:29 PM
OK,
Lookup one lets say should be the type of wall
Left hand, right hand, T, end.

This will point to 4 specific vis states.
visible in each is another lookup table.

this set of sub tables will each have an entry for fire rates, ansi 131, insulated, no hatch.
These point to the specific visibility state for that combination.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 03:15:05 PM
OHHHHHHH

I get it now.

I had the totally improper assumption about the lookups.  I didn't realize there were NESTED lookups.  I had only two lookups total.

Now I realize what wasn't clicking.  Thank you so much for the explanation!
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 03:21:51 PM
GREAT

I got desperate enough to get you started.

This covers left hand and right hand, you just need to keep it going for T and end wall
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 03:22:53 PM
I also removed the vis states from the stretch, LOL

You should ad a rotate in there too, but thats just my opinion.
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 03:23:22 PM
And to make it all look seemless, you place the various lookup table icons on top of each other for the various visibility states.
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 03:24:39 PM
I also removed the vis states from the stretch, LOL

You should ad a rotate in there too, but thats just my opinion.
Oooh oooh ooooh!!  And a left, right, T condition for the other end.  (as if it isn't complicated enough already)


OR... you can just upgrade to Architectural Desktop or Architecture or whatever they call it these days.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 03:26:08 PM
I also removed the vis states from the stretch, LOL

You should ad a rotate in there too, but thats just my opinion.
Oooh oooh ooooh!!  And a left, right, T condition for the other end.  (as if it isn't complicated enough already)


OR... you can just upgrade to Architectural Desktop or Architecture or whatever they call it these days.

You gonna foot that bill?  I suggested it to the boss, though.  *shrug*

Just trying to make crap for myself to make my job faster and/or easier, with what I got so far.
Title: Re: More than one Visibility State in a Block
Post by: Shinyhead on May 28, 2009, 03:27:22 PM
Hey, when you get it done, send it to me.  I have a few tricks I might want to show you just for bragging rights.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 03:27:25 PM
GREAT

I got desperate enough to get you started.

This covers left hand and right hand, you just need to keep it going for T and end wall

Thanks a boatload!

Soon as I get this "OMG I NEED THIS BACK ASAP" request from one of our clients, on another project, I'll be able to get back to that block and finish 'er up!

Hey, when you get it done, send it to me.  I have a few tricks I might want to show you just for bragging rights.

haha, okey doke then.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 03:49:52 PM
Couple tiny quirks I might want to alter and change for smoothness of operation.... but it's completely functional, as far as I can tell, now.

Matt, regarding the rotation parameter, I feel it would unnecessarily complicate the block, as using the regular rotate command would lessen bloat in the drawing, and would keep me from having to go through the PITA of messing with this already-complicated block further.

As for the end treatment of opposing end, as well, I actually use two blocks for walls that need treatment at both ends, with the base point of the blocks near the midpoint of the wall, each block half the length of the required wall.  It's "brute force" sure, but it works.

*thinking out loud*  I wonder if I can make an adjustment so I can use the same block for 4" walls and 6" walls and 8"-16" walls (because 8-16 walls could be CMU walls if I add an appropriate hatch......)

...I think I'm just gonna let that thought go for now.... before I start wondering about 3D dynamic blocks again...
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 03:54:42 PM
Matt, regarding the rotation parameter, I feel it would unnecessarily complicate the block, as using the regular rotate command would lessen bloat in the drawing, and would keep me from having to go through the PITA of messing with this already-complicated block further.
Hey, that wasn't me...  that was the blue guy!  :wink:
Title: Re: More than one Visibility State in a Block
Post by: Matt__W on May 28, 2009, 03:56:42 PM
...but it's completely functional, as far as I can tell, now.

Crack open that drawing (the one you posted) and just stretch it.  Here's what I got when I did that.
Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 04:01:46 PM
Matt, regarding the rotation parameter, I feel it would unnecessarily complicate the block, as using the regular rotate command would lessen bloat in the drawing, and would keep me from having to go through the PITA of messing with this already-complicated block further.
Hey, that wasn't me...  that was the blue guy!  :wink:

Whoops!  Scrolling too fast while reading.. icons must've blurred :P

I'm actually looking up some stuff on Architecture... my main thing is seeing how well it does steel framing... if it has a decent steel design capability, I might be sold into demanding my boss buy this (read: throwing a tantrum and stomping my feet in his office)

Title: Re: More than one Visibility State in a Block
Post by: James Cannon on May 28, 2009, 04:03:26 PM
...but it's completely functional, as far as I can tell, now.

Crack open that drawing (the one you posted) and just stretch it.  Here's what I got when I did that.

That's the intentional "stopping point" for insulation and fire rating.  I will see if it's more appropriate to end the solid hatch further down, but that's our "FIRE RATED" hatch and I don't want to extend it further than it should, and forget to spec out some fire rated assembly in the wall that intersects my block... if that makes sense... I'm just going to see 'how it goes' before finalizing things like that.

As for the insulation seeming to disappear up top... for some reason the top of the insulation (which is made up of separate objects in an array) is UNDER the solid hatch in 'draworder' but the lower ones and subsequently arrayed ones, are 'on top'  .. the insulation is there, just 'under' the hatch.

***edit/// that's also with "ALL SHOWN" by default, until the user selects what they want.  I could default to a plain wall, I guess... meh.