Skip to content

Commit

Permalink
Tagging 4.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
tomcashman committed Jan 22, 2017
1 parent 7e14cc4 commit fd93c10
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 17 deletions.
1 change: 1 addition & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[4.1.0]
- XML config now stores previously generated data
- Plugin now accepts directory as argument

[4.0.0]
- Removed Slick dependency, images now generate in headless JVM
Expand Down
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,25 @@ A Gradle plugin and command line utility for packing individual tile images into
Gradle
---------

First, include the mini2Dx repositories in your buildscripts section. This is where tilepacker is deployed to.

```gradle
buildscript {
repositories {
mavenLocal()
mavenCentral()
}
dependencies {
classpath 'org.mini2Dx:tilepacker-gradle-plugin:3.0.1'
classpath 'org.mini2Dx:tilepacker-gradle-plugin:4.1.0'
}
}
```

Then define a task for packing up your tiles into tilesets.
Then define a task for packing up your tiles into tilesets. The tilesDirectory is where your tiles and configuration file are.

```gradle
task tilePack(type: org.tilepacker.gradle.TilePackerTask) {
configFile file('config.xml')
tilesDirectory file("path/to/tiles/folder")
//Change to true if you do not want to use previously stored order of tiles
rewrite false
}
```

Expand All @@ -38,20 +38,20 @@ A sample configuration file can be found [here](https://raw.githubusercontent.co

Command Line
---------
On the command line, the application takes a single argument - the path to the configuration file. The configuraiton file tells tilepacker which settings to apply and which files to pack into tilesets.
On the command line, the application takes a single argument - the path to the directory of the tiles and configuration file. The configuraiton file tells tilepacker which settings to apply and which files to pack into tilesets.

A sample configuration file can be found [here](https://raw.githubusercontent.com/tomcashman/tilepacker/master/config.sample.xml).

Windows

```bash
tilepacker-core.bat ./path/to/config.xml
tilepacker-core.bat ./path/to/tiles/folder
```

Mac OS X / Linux

```bash
./tilepacker-core ./path/to/config.xml
./tilepacker-core ./path/to/tiles/folder
```


Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ subprojects {
}

group = 'org.mini2Dx'
version = '4.1.0-SNAPSHOT'
version = '4.1.0'

sourceCompatibility = 1.7
targetCompatibility = 1.7
Expand Down
18 changes: 10 additions & 8 deletions config.sample.xml
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
<tilePackerConfig>
<tileWidth>32</tileWidth>
<tileHeight>32</tileHeight>
<tileWidth>8</tileWidth>
<tileHeight>8</tileHeight>
<tilesetWidth>512</tilesetWidth>
<tilesetHeight>512</tilesetHeight>
<tilePadding>2</tilePadding>
<outputFormat>PNG</outputFormat>
<outputPath>./</outputPath>
<outputPath>../core/assets/maps</outputPath>
<preventTearing>true</preventTearing>
<premultiplyAlpha>false</premultiplyAlpha>
<backgroundColor>255,0,255</backgroundColor>
<premultiplyAlpha>true</premultiplyAlpha>
<tiles class="java.util.ArrayList">
<string>./tile1.png</string>
<string>./tile2.png</string>
<string>./tile3.png</string>
<tileConfig>
<path>example.png</path>
</tileConfig>
<tileConfig>
<path>subfolder/example.png</path>
</tileConfig>
</tiles>
</tilePackerConfig>

0 comments on commit fd93c10

Please sign in to comment.