Page 2 of 2 FirstFirst 12
Results 11 to 16 of 16

Thread: A Simple City Generator

  1. #11
      Ramah is offline
    Guild Expert Ramah's Avatar
    Join Date
    Mar 2009
    Location
    Nottinghamshire
    Posts
    1,327
    Blog Entries
    3

    Post

    That's pretty cool.

    Two points to mention from me though.

    The first is, some of the little houses seem a little blurred yet others are pin sharp. Is there a reason for this? I would think it would be better if they could all be as sharp as possible.

    Secondly... how do I actually take the generated city and export it? There are no options to save the image. Do I need to do a screen capture of my whole desktop? Sorry, but I'm a complete noob about stuff like this.
    Royal: I'm very sorry for your loss, your mother was a terribly attractive woman.


    My Cartographer's Guild maps: Finished Maps


    More maps viewable at my DeviantArt page: Ramah-Palmer DeviantArt

  2. #12
    Guild Member
    Join Date
    Oct 2009
    Location
    Denmark
    Posts
    55

    Post

    Quote Originally Posted by Ramah View Post
    That's pretty cool.

    Two points to mention from me though.

    The first is, some of the little houses seem a little blurred yet others are pin sharp. Is there a reason for this? I would think it would be better if they could all be as sharp as possible.

    Secondly... how do I actually take the generated city and export it? There are no options to save the image. Do I need to do a screen capture of my whole desktop? Sorry, but I'm a complete noob about stuff like this.
    Hay.

    Well, the part about the houses i cant answer. as i have newer seen that happen. shouldn't even be posible, since it is pure Vector grapichs :S is it posible fore you to send me a Screendump of this :S if i can ill try to fix it

    second- sadly fore now youll have to make a ScreenDump since my last save function violated Angelfires rules :S but ill try to reprogram it into the downloadable vercion

    Yours ZleapingBear

  3. #13
      su_liam is offline
    Guild Artisan su_liam's Avatar
    Join Date
    Aug 2007
    Location
    Port Alberta, Regina(IRL: Eugene, OR)
    Posts
    709

    Post

    A quick map of the confluence served by the Slapdash Ferryboat Company.
    Attached Thumbnails Attached Thumbnails A Simple City Generator-town.png  

  4. #14
      novice42 is offline
    Guild Novice
    Join Date
    Oct 2008
    Posts
    17

    Post

    Hi,

    another simple city generator: www.mediafire.com/?z0yiuzbmmxz. Sorry, looks dull and has only two or three features because it is the work of a short break (had to use one hand for lunch, the other for typing code). Its a flash swf; open it with any browser you want (Flash Player 9 up).

    At start, it will generate a random distribution of 100 houses consisting of six different types. The houses are slightly scaled and rotated. Because of some highly complicated calculations based on a secret Mayan calendar, I came to the conclusion that the buildings should be rotated by a multiply of 45 degrees (but it wouldn't be too hard to use a totally random rotation if someone wants it). Also, the generator does choose a random background of 5 tileable bitmaps. The random distribution is somewhat more even than in Zleaping Bears generator (though his clusters of houses may look more natural).

    In the panel on the right hand of the generator you can choose (from top to bottom):
    - the number of houses (min 60, max 250). If the number is below the min or over the max value, the min/max value will be used.
    - seven backgrounds (5 bitmaps, two solid colors: white, black, default: random bitmap)
    - six house types (default: all six are displayed). Make sure that you choose at least one, otherwise only a ghost city will be generated
    - simple brush settings: three colors and three sizes (in pixel; default: blue, 5 px) to paint rivers, streets etc (ok, to be sincere: I just wanted to have some coloring fun inside the generator). The last button allows to delete your great paintings.

    To paint simply click on the background and move the mouse; you are always in painting mode. I know, the usability is a pain (i.e., you don't know which color or brush size is activated), there is so much left out (i. e., spray mode: random distribution of plants and trees, import of bitmaps for background, houses etc. and most of all: no saving of your map - you need to take a screenshot).

    edit: minor update (http://www.mediafire.com/?0dnwnmwmz4y). In the panel at the bottom you may find a Gaia category allowing to spray trees (at the moment only one default tree, no randomizing of size, amount button inactive). If using the spray tool you are leaving the paint mode. To return, simply click on one of the brushes. The last button deletes all trees.

    There is a layering order: first comes the background (surprise!), then paint (roads, rivers etc), houses, and at last Gaia (trees, plants etc).

    One quick screen:



    However - have fun
    Attached Thumbnails Attached Thumbnails A Simple City Generator-smallcity1.jpg  
    Last edited by novice42; 11-18-2009 at 03:26 PM.

  5. #15
      Ascension is offline
    Community Leader Ascension's Avatar
    Join Date
    Jun 2008
    Location
    St. Charles, MO
    Posts
    8,216

    Post

    That's pretty cool, too. I'm thinking that maybe we should put these all together in a sticky somewhere for those folks who need something really quick and simple.
    If the radiance of a thousand suns was to burst at once into the sky, that would be like the splendor of the Mighty One...I am become Death, the Shatterer of worlds.
    -J. Robert Oppenheimer (father of the atom bomb) alluding to The Bhagavad Gita (Chapter 11, Verse 32)


    My Maps ~ My Brushes ~ My Tutorials ~ My Challenge Maps

  6. #16
      novice42 is offline
    Guild Novice
    Join Date
    Oct 2008
    Posts
    17

    Post

    Hi,

    Another minor update (http://www.mediafire.com/file/03zwyo...Gen012_cs3.swf).

    Default mode is now building. To switch the modes you can simply click on one of the buttons belonging to the desired mode. To go back to default mode click on a background icon in the panel (if you don't want to change the actual background choose the same bitmap or color). I will later add buttons to switch.

    Click on the color chip in the paint category to open a (small) color palette. The brush thickness can be set by a slider (range 1 to 38 px). Activating the palette or the slider switches to the paint mode. Painting can never start on top of a house (though you can paint "through" a house).

    The rotation of the houses is now totally random.

    There is now a new direction tool called road (rotate) allowing to paint streets or roads and trying to turn nearby houses with their frontside automatically to the street. The upper side of the house icons in the panel represents the frontside. This tool is a little bit tricky and sensitive to the smallest mouse movements. So it may take some time until you get used to it. The distance slider sets the distance how far that effect does reach to each side of the street (in px). Color and width of the road are the same as the settings of the normal paint brush. If you don't want to change the rotation paint the road with the brush tool. The road (rotate) tool paints on its own layer which is below the paint layer (sorry, at present you can't access the layers directly). Now annoying: if you use the special road tool and want to change the color or size, you will leave the road mode. You need to activate it again (will be corrected later)

    Individual houses can be changed on the map (you must be in the building mode):
    - <click> to drag
    - <space><click> to delete
    - <ctrl><click> and move the mouse outside of the house graphic to change the rotation. The frontside will face to the mouse. To stop rotating release the <ctrl>-key.

    You can also delete individual trees (haha, try to kill a 2px tree with the mouse!):
    - <space><click> to delete (in spraying mode; don't move the mouse otherwise you will spray more trees)
    Trees have now randomized size

    Trees and Houses have default shadows (can be turned on and off).

    Sorry, somewhat inconsistent tool, call it a pre alpha of a pre alpha. Maybe its now time to really think about what such a tool should do.

    Have fun

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •