[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions.php on line 4586: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765) [phpBB Debug] PHP Warning: in file /includes/functions.php on line 4588: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765) [phpBB Debug] PHP Warning: in file /includes/functions.php on line 4589: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765) [phpBB Debug] PHP Warning: in file /includes/functions.php on line 4590: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765) [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 122: preg_match_all(): The /e modifier is no longer supported, use preg_replace_callback instead [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 124: array_unique() expects parameter 1 to be array, null given [phpBB Debug] PHP Warning: in file /includes/functions_reimg.php on line 126: Invalid argument supplied for foreach() WorldWorksGames • View topic - Scripting GIMP and OpenOffice to streamline kitbashing
Post subject: Scripting GIMP and OpenOffice to streamline kitbashing
Posted: 10-20-2014, 11:46 AM
Dirigible Joined: 12-06-2010, 07:16 AM Posts: 1487 Location: Massachusetts
I finally spent enough time today to learn how to script GIMP. I'm officially dangerous! My next step will be to document my convention for storing layers, since my scripts will rely on that, and to package it up as a gimp plugin. At that point, if any kitbasher wants to give it a go, I'll be happy to help get set up. I think part of my documentation will be a "template" file for tiles that doesn't have any WWG templates baked into it, but provides layer groups and guidelines to make it easy to set up.
If you're adventurous and would like some rough tools, PM me and I'll try to share what I have as soon as I have it. I just added edges to and created three pages of anchors for 10 6" tiles in about 15 seconds. I'll need to do something similar for hallway tiles and 3" tiles. After that, I'll work on writing a script that will export images for all of the tiles with different grids and with or without anchors.
Last edited by mproteau on 11-03-2014, 05:37 PM, edited 1 time in total.
Post subject: Re: Scripting GIMP and OpenOffice to streamline kitbashing
Posted: 11-03-2014, 05:51 PM
Dirigible Joined: 12-06-2010, 07:16 AM Posts: 1487 Location: Massachusetts
Well, I had some success scripting OpenOffice Draw to pull in a directory of images and lay them out on new slides for easy export. Now, I click a button, paste in a directory name, wait for the tediously slow OpenOffice to do its things, then export.
If you're interested, the script available, at least for a while, in my dropbox folder:
Not sure how to set up the macro in OpenOffice Draw?
1) Tools > Macros > Organize Macros > OpenOffice BASIC... 2) Select My Macros > Standard > Module1 3) Click Edit 4) Overwrite with the contents of my draw_script.txt file and close the window. 5) Tools > Macros > Organize Macros > OpenOffice BASIC... 6) Select My Macros > Standard > Module1 7) Select Import_Directory 8) Click Assign... 9) Under Toolbar Content, I clicked Add... to add a new toolbar button and moved it where I wanted it. You can rename it, and pick an icon for it.
When you run the macro, it will prompt you for a directory. It will walk the directory looking for any .jpg or .png file. It will create a new document with each image on a page. By convention, I name my pages like "tile 01.jpg" "tile 02.jpg" etc.
To export a PDF from OpenOffice Draw, go to the File menu and select Export as PDF... On the General tab, I set Images to JPEG compression, with a quality of 75% and I reduce image resolution to 300 dpi. I have export bookmarks checked. From the initial view tab, I select Thumbnails and page.
I have that as the defaults, and I map Ctrl+Shift+E to that menu item, so I can quickly export, hit enter, then type in my pdf filename.
The script isn't the greatest. Since I follow a naming convention for directories and files, I'm sure I could pretty easily point at the root of my intermediate images and have it build up and export automatically ALL of my pdfs. But, this shaves enough off my normal process that I'm going to work on more fun things now.
Post subject: Re: Scripting GIMP and OpenOffice to streamline kitbashing
Posted: 11-03-2014, 06:48 PM
Dirigible Joined: 12-06-2010, 07:16 AM Posts: 1487 Location: Massachusetts
I've got a couple of scripts for GIMP for making anchors and edging 6" tiles over on . Still very much for early adopters, but I've commented the files enough to hopefully explain how the scripts want to see files organized. PM me if you'd like to try them out and don't know how to get going, or run into any problems.
Next up for my scripts will be finishing up the hall and 3" tiles. Between this and the OpenOffice script, it now takes only a few minutes to go from a list of 6" tiles (like, say, converted from Swampwood) to new PDFs. More time for doing the creative stuff!
Post subject: Re: Scripting GIMP and OpenOffice to streamline kitbashing
Posted: 11-06-2014, 02:10 PM
Dirigible Joined: 12-06-2010, 07:16 AM Posts: 1487 Location: Massachusetts
I updated my plugin to do the Hallway tile edges and anchors. 3" tiles will be next, but I've been exporting the tiles as I complete them. The TLX hut base tiles are looking pretty good. I haven't tackled the round tiles yet. Slow and steady...
Forgive the thread necro, but I finally tried out your script 'cuz I've been getting nothing done on my Castle Korvosa build in the last few months. My group is getting closer to starting the last book of the AP, so the pressure is mounting. And I'm off from work from the 15th all the way to Jan 4th (or else I lose the PTO) so my plan was to spend this time catching up, but it hasn't been happening. I've been dreading all the editing I need to do with the Himmelveil Streets tiles to remove the green lines for the TLX tabs. For some reason, cutting, edging, gluing, and assembling wasn't feeling like work. It was editing the files. So, I figured I had to try out your script to see if it would work well.
Holy buckets, dude! Once I imported all the 6" tiles from Himmelveil Streets and setup the layers your script requires, it just went to town and hammered out all the edges for 15 different tiles in less than a minute. It doesn't have the dashed lines indicating where to score, but for anyone who has done a few TLX builds, that's really not necessary. And for someone like me who robocuts every tile, it's even less necessary. Your script has saved me a TON of time. If we ever end up at the same gaming convention, I will happily buy you dinner.
Users browsing this forum: No registered users and 1 guest
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum