Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: DF in AutoCAD  (Read 2611 times)

MelloHero

  • Bay Watcher
  • 無基督、我無也。
    • View Profile
DF in AutoCAD
« on: October 14, 2009, 03:24:25 pm »

Alright. The location of my latest fortress seems so perfectly amazing (lacking only magma, but plenty of wood, both in-ground and Elven houses) that it's warranted some planning. I've bought a pad of graph paper, but the paper is thick and the grids don't line up from page to page. Has anyone had any success in designing forts in AutoCAD, specifically the 3D layers, and if so, could you share some details how you did it?
Logged
Even if you have dwarves decked out in cotton candy they will still have fun with clowns.

Duke 2.0

  • Bay Watcher
  • [CONQUISTADOR:BIRD]
    • View Profile
Re: DF in AutoCAD
« Reply #1 on: October 14, 2009, 03:28:24 pm »

 I use a raster graphics editing program with a pixel grid turned on and semitransparent layers to plan my forts. In my case Paint.net. I have designations for each color and draw my fort out.
Logged
Buck up friendo, we're all on the level here.
I would bet money Andrew has edited things retroactively, except I can't prove anything because it was edited retroactively.
MIERDO MILLAS DE VIBORAS FURIOSAS PARA ESTRANGULARTE MUERTO

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: DF in AutoCAD
« Reply #2 on: October 14, 2009, 04:03:16 pm »

Being an AutoCAD developer myself, I can't say I haven't thought about it, and indeed, there are a whole host of ways it can be done, from using custom blocks (possibly with visible/non-visible attributes and/or dynamic (resizable) elements), through using AutoLISP or ObjectARX to automate drawing using primitives (rectangles, polylines, faces, solids etc) and all the way to custom objects representing terrain meshes, buildings, creatures which can be a simple or as complex as you want using ObjectDBX or OMF.

It's even possible using the DF memory hacking library (which I'm following the development of quite closely) to use AutoCAD as a visualiser as well as a design tool, however, as always, the tradeoff is complexity/functionality against time/difficulty, you pays your money, you takes your chance.

I don't have huge amounts of spare time (family, job etc) so I couldn't commit to anything, but should anyone want more information, I have 15 or so years of AutoCAD experience I can contribute, even if It's only in advisory capacity.

* Vicomt waves at anyone who remembers the HLMapExport application ;) *

*disclaimer - I like blowing my own trumpet at times :P

MelloHero

  • Bay Watcher
  • 無基督、我無也。
    • View Profile
Re: DF in AutoCAD
« Reply #3 on: October 14, 2009, 05:09:12 pm »

I was also thinking about making it presentable on its own, as you said, a visualizer. My problem there, I think, is that my university class for CAD, hasn't progressed beyond 2D drawings yet. I'm currently hung up on surfaces, especially pertaining to channels and open space. Would you make 1 sheet per Z-level, or would it be doable all in one sheet? I can imagine them both, but I'm not sure which would be best.
Also, two real noob questions here: Can you change the "justification" of a polyline, like so the points you click will be on an edge of the polyline instead of the center, and is there any easier way to move around the sheet than zooming and selecting objects? I'd kill for a grabby hand in this program...
« Last Edit: October 14, 2009, 05:30:04 pm by MelloHero »
Logged
Even if you have dwarves decked out in cotton candy they will still have fun with clowns.

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: DF in AutoCAD
« Reply #4 on: October 14, 2009, 05:47:30 pm »

*warning - wall of text incoming*

ok, if you're just talking about using native AutoCAD stuff for simplicity, then you still have a lot you can do design wise depending on what you need it to look like. First lets talk a bit about the organisation of the drawing.

1 - Model space - this is where your geometry goes, use layers to represent each Z level, name them something like "Level 0 : Entrance", "Level -1 : Finished Goods Storage" (you may need to play about with the naming to get AutoCAD to list the layers in the correct order in the layer window) - more about what to put in here shortly....

2 - Layouts - one layout per Z-level, you can set which layers are on or off within the viewport separately from the layout settings within the model. you can also put titles and notes in text within the layout to annote the drawing

get used to switching between model and layout space, for production drawings it's very useful.

in terms of how to draw the z-level geometry, there's a couple of things to setup first, set your grid to 1, snap to grid, set background colour to black (use options to change this) and define rectangle for the "site boundary", you might want to draw some construction lines/rectangles initially to separate or prototype your design, draw these construction lines onto separate "construction" layers if necessary, you can turn them off later.

I wouldn't worry about drawing anything in 3D, the layer system is a very good analogue of DF's Z-levels

then you'll want to use these constructions lines to create your detailed design, I'd suggest using rectangles and solid hatches that can be coloured according to a key (might want to place the key in each layout as well) to denote the specifics. you can also use layers for each type of industry/stockpile/zone, this will allow you to automatically colour each hatch you place, as the default colour for new bits of drawing is "ByLayer", which is handy once you figure out how to use the layer window to set colours etc.

Moving about the drawing should be as simple as pick and drag, should be middle mouse buton by default, but you can always use the dynamic pan command from deep within the view menu/toolbar/ribbons. It takes a while to learn where all the commands are, there are a helluva lot. btw, ribbons are an AutoCAD 2010 feature, I don't know which version you're using.

If I get chance, I'll try and mock something up very simply as a guide, although I don't know if I'll have the time to do much as I have a pre-release release of our new commercial software coming up at the end of the month, so it's crunch time.

hope this helps as a general overview, if you're still only at a basic level of understanding, it might take a while to get hang of some of the concepts as AutoCAD is a beast of a package in some regards. any specific problem/query you think of, just post here, I'm watching the thread, and maybe others will like to read or contribute.

have fun ;)

MelloHero

  • Bay Watcher
  • 無基督、我無也。
    • View Profile
Re: DF in AutoCAD
« Reply #5 on: October 14, 2009, 05:57:40 pm »

Thanks, mate! I've got 2010 and I think I'm getting the hang of things here, just the polyline thickness thing getting me: is there a way to define the line from the edge instead of the axis?
Logged
Even if you have dwarves decked out in cotton candy they will still have fun with clowns.

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: DF in AutoCAD
« Reply #6 on: October 14, 2009, 06:31:22 pm »

to be honest, I wouldn't bother with thickness, use lines/polylines rectangles without thickness as your construction tools, use the coloured solid fill hatch as your main design primitive, boundary detection hatching (with solid fill) can be done with any enclosed or crossing line/polyline/rectangle/arc geometry. I think by default, solid fills are "associative" which means that if you move/stretch/scale the geometry, the hatch will regenerate to the new boundary (or tell you if you don't have a closed area any more). this IMHO makes it much more useful than "dumb" thickness.

anyway, I'm out for the night, work in 6 hours :(

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: DF in AutoCAD
« Reply #7 on: October 15, 2009, 03:26:00 am »

I've knocked up a (very) simple drawing, however, I don't have access to anywhere to put it atm, if you PM me your email address, I'll get it sent to you.

Lord Shonus

  • Bay Watcher
  • Angle of Death
    • View Profile
Re: DF in AutoCAD
« Reply #8 on: October 15, 2009, 06:03:19 am »

I've done a bit with Inventor 10.
Logged
On Giant In the Playground and Something Awful I am Gnoman.
Man, ninja'd by a potentially inebriated Lord Shonus. I was gonna say to burn it.