diff --git a/.gitignore b/.gitignore
index 4f11942e..76d8d105 100644
--- a/.gitignore
+++ b/.gitignore
@@ -8,11 +8,14 @@
*~
*.class
*.iml
-
+.project
+.classpath
+**/bin/
/game/data/rsa.pem
/game/data/savedGames
/lib/
*/target/
*/build/
**/build/
-**/out/
\ No newline at end of file
+**/out/
+/vendor/
\ No newline at end of file
diff --git a/build.gradle b/build.gradle
index 4da3f477..c1756fcf 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,6 +1,4 @@
plugins {
- id 'org.asciidoctor.gradle.asciidoctor' version '1.5.1' apply(false)
- id 'org.asciidoctor.convert' version '1.5.3' apply(false)
id 'org.jetbrains.kotlin.jvm' version '1.3.41' apply(false)
id 'org.jetbrains.intellij' version '0.4.9' apply(false)
id 'org.jmailen.kotlinter' version '1.26.0' apply(false)
diff --git a/docs/api/plugin-script/on_button.md b/docs/api/plugin-script/on_button.md
new file mode 100644
index 00000000..bebe6639
--- /dev/null
+++ b/docs/api/plugin-script/on_button.md
@@ -0,0 +1,5 @@
+---
+uid: on_button
+---
+
+`on_button` allows registering @"handlers"
\ No newline at end of file
diff --git a/docs/build.gradle b/docs/build.gradle
index e1358410..afb41f98 100644
--- a/docs/build.gradle
+++ b/docs/build.gradle
@@ -1,13 +1,25 @@
-plugins {
- id 'org.asciidoctor.gradle.asciidoctor'
- id 'org.asciidoctor.convert'
+configurations {
+ doclet {
+ transitive(true)
+ }
}
-repositories {
- mavenCentral()
+dependencies {
+ doclet files("vendor/docfx-doclet-1.0-SNAPSHOT-jar-with-dependencies.jar")
}
-asciidoctor {
- attributes 'source-highlighter': 'prettify',
- 'toc': 'left'
+gradle.projectsEvaluated {
+
+ task generateApiDocs(type: Javadoc) {
+ source = project(":game").sourceSets.main.java.sourceDirectories
+ classpath = project(":game").configurations.runtimeClasspath + project(":game").sourceSets.main.output
+
+ options.encoding 'UTF-8'
+ destinationDir = file("build/generated-files")
+ options.addStringOption("doclet", "com.microsoft.doclet.DocFxDoclet")
+ options.docletpath = configurations.doclet.toList()
+
+ dependsOn(project(":game").assemble)
+ }
+
}
diff --git a/docs/docfx.json b/docs/docfx.json
index f2be8312..29bb2e37 100644
--- a/docs/docfx.json
+++ b/docs/docfx.json
@@ -17,7 +17,7 @@
{
"files": [
"api/**.yml",
- "api/index.md"
+ "api/**.md"
]
},
{
@@ -50,9 +50,7 @@
"dest": "_site",
"globalMetadataFiles": [],
"fileMetadataFiles": [],
- "template": [
- "default"
- ],
+ "template": [ "default", "templates/material" ],
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
diff --git a/docs/guide/plugins/01-what-is-a-plugin.md b/docs/guide/plugins/01-what-is-a-plugin.md
index 0a0868b8..88067479 100644
--- a/docs/guide/plugins/01-what-is-a-plugin.md
+++ b/docs/guide/plugins/01-what-is-a-plugin.md
@@ -1 +1,8 @@
-# What is a plugin?
\ No newline at end of file
+# What is a plugin?
+
+Plugins in Apollo are a mechanism for extending the server with new functionality without having to change any of the core Java code.
+Every plugin is a straight forward Kotlin project with `.plugin.kts` files containing the plugin extension behaviour and optional Kotlin source files containing generic reusable code.
+
+## Plugin framework architecture
+
+Under the hood, the Kotlin compiler transofmrs every `.plugin.kts` file into a class file that extends from @"org.apollo.game.plugin.kotlin.KotlinPluginScript", giving it access to the game @"org.apollo.game.model.World" and @"org.apollo.game.message.handler.MessageHandlerChainSet" the plugin framework is initialized with.
\ No newline at end of file
diff --git a/docs/guide/plugins/02-creating-a-plugin.md b/docs/guide/plugins/02-creating-a-plugin.md
index ef063667..ee9fb8f2 100644
--- a/docs/guide/plugins/02-creating-a-plugin.md
+++ b/docs/guide/plugins/02-creating-a-plugin.md
@@ -10,17 +10,7 @@ branch prior to the release of the Kotlin plugin system for Apollo.
## Create a working environment
-The project maintainers strongly recommend
-[IntelliJ IDEA](https://www.jetbrains.com/idea/).
-After starting IDEA, select *checkout project* with the URL:
-https://github.com/apollo-rsps/apollo.git and continue. Make sure to
-*import using gradle* on the next interface.
-
-Next, checkout the kotlin-experiments branch. To do this via IntelliJ,
-use the navigation bar at the top and 'VCS > Git > Branches >
-origin/kotlin-experiments > Checkout as new branch'. Name the new branch
-something like kotlin-experiments-my-plugin.
## Create the plugin metadata
diff --git a/docs/templates/material/partials/head.tmpl.partial b/docs/templates/material/partials/head.tmpl.partial
new file mode 100644
index 00000000..eaac2fc2
--- /dev/null
+++ b/docs/templates/material/partials/head.tmpl.partial
@@ -0,0 +1,21 @@
+{{!Copyright (c) Oscar Vasquez. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}}
+
+