Chunk Stories is a big project made out of many components that all slot in one another. The three big projects, chunkstories-api
, chunkstories-core
and chunkstories
form the basis of what is considered “the base game” and are effectively what is distributed in the client downloads section.
This apparent complexity is not without it's load of advantages: since no mod code will be written against chunkstories
, an Android port, with a completely different codebase could still run all the content it wants, as long as it implements their correct version of the API. Another benefit is for contributors that would otherwise be confused by the breadth and complexity of the implementation code, they can stick to only editing the core project to add in the gameplay stuff.
This however does mean if one wants to write mods against a bleeding (unreleased) version of the game, one has to install the entire development environment. Fortunately, it's not nearly as complicted as it looks and requires mostly cloning 3 github repos ( and keeping the up to date ) and running one command in each of them, in order.
First you need to clone both chunkstories-api
and chunkstories-core
as both are needed to compile this. You can try to build from the artifacts in the repo, but only those used in released versions of the games are guaranteed to be present.
mkdir git; cd git
git clone https://github.com/Hugobros3/chunkstories-api.git
git clone https://github.com/Hugobros3/chunkstories-core.git
git clone https://github.com/Hugobros3/chunkstories.git
./gradlew install
./gradlew install
chunkstories
folder and you can now build the implementation and run the game !The local maven repository on your computer (.m2 folder) now contains copies of both the api and core content the chunkstories engine requires. These are not automatically rebuilt when building the implementation as they are completly seperate projects, so keep that in mind.
./gradlew client:shadowJar
builds the Client executable (chunkstories.jar)./gradlew server:shadowJar
builds the Server executable (server.jar)./gradlew converter:shadowJar
builds the Map converter executable (converter.jar)./gradlew launcher:createExe
builds the launcher executables (.exe and .jar as well)./gradlew buildAll
builds all of the above./build_local_deps.sh
will automatically build both api and core, assuming they are in the same parent folder as this../debug-client.sh
will start the client jar under debug conditions: Java remote debugging enabled, using the current directory as it's work directory ( and not .chunkstories ), and using ../chunkstories-core/res as it's core content distribution../debug-server.sh
will start the server jar under debug conditions: Java remote debugging enabled, using the current directory as it's work directory ( and not .chunkstories ), and using ../chunkstories-core/res as it's core content distribution.