Skip to main content
=========================================
World Build
=========================================

Tools for computational world building (work in progress)

Overview
--------------------------------
Worldbuild contains tools to build worlds and store the metadata around that, including objects, history, animals, vegetation.

You provide a map of your world and annotate it via a YAML file to define towns with locations - the wiki tool extracts subset of the image to for each town.

You can add additional information to build a rich history around your world.


Quick Start
=========================================

Copy your map file (JPG) or scan a hand drawn map.

Create a YAML file with the following sections


wiki: Yes
world_name: Alrona
contents:
- races
- settlements
maps: [alrona-pen-coloured.jpg]


You need to have a root section for each element in contents, and there needs to be a name and desc element at the minimum.


settlements:
- name: Draeton
continent: Sharnia
coords_x_y: [66,58]
desc: >
This is the largest city on the East side of Sharnia. 3,000 men live in this strongly
defended city
- name: Ambyle
continent: Sharnia
coords_x_y: [64,58]
desc: >
Farming town East of Draeton, known for their famous weekend markets selling exotic produce grown in the warm regions north of the Eastern Desert

Then modify the params and run the wiki.py program to generate the HTML version of your world.


The settlements page shows the description from the yaml file, and also a section of the map based on the coords_x_y parameter

You can extend the wiki with as many sections as you like and each entry can include a file section to import a text (or html) file to be included in that page.



Random Grid Generation
============================
Create a random grid as follows


pip install worldbuild
build_random_grid.py


You can convert this grid to a Tiled TMX file for manual editing

convert_grid_to_tiled_map.py




Dungeon Map Generator
============================
Create a randomnly generated rogue like dungeon grid by running

import worldbuild.dungeon_generator as dg

grid = dg.create_dungeon(grid_y=30, grid_x=80, NUM_ROOMS=16, ROOM_SIZE = 3, NUM_HORIZ = 10)
print(dg.grid_as_str(grid))

# optional - make a path through the grid
print(dg.path_find(grid))

# optional - export as TMX file
dg.convert_grid_to_TileEditor_map('dungeon.tmx', 'samples/ascii_runeset.tsx')


It also uses the pathfinding package to make a path through the map

Optionally, you can uncomment the line to save it as a TMX file for use in Tiled.
Doing this will allow you to use the above grid with a tileset to get better graphics.

Release files for worldbuild 0.0.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for worldbuild 0.0.9
File Size Uploaded
worldbuild-0.0.9.tar.gz 24.8 MB Details

Release files / worldbuild-0.0.9.tar.gz

Download URL worldbuild-0.0.9.tar.gz
Size 24.8 MB
Tags Source
SHA-256 checksum
How to use checksums
789a27ca3c4e3a29a66675992cfcb26e2e3faea5b365b49b6289b011a1faedb4
BLAKE2b-256 checksum
How to use checksums
34f84248d3abe33ab3cfcabe14a2655248f96e80bb90802a9fd79963b0245cd0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.20.1 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.7

Release history Release notifications | RSS feed

This release

0.0.9 This release

1 release file

0.0.8

1 release file

0.0.7

1 release file

0.0.6

1 release file

0.0.5

1 release file

0.0.4

1 release file

0.0.3

1 release file

0.0.2

1 release file

0.0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page