-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 47f3b60
Showing
94 changed files
with
4,845 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/build/ | ||
/.idea/ | ||
/.gradle/ | ||
/*/build/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Xenox | ||
Xonix game implementation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
group = "gargoyle.xenox" | ||
version = "1.0" | ||
description = "xenox" | ||
|
||
repositories { | ||
mavenCentral() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
val javaVersion: String = JavaVersion.VERSION_16.toString() | ||
|
||
group = "gargoyle.xenox" | ||
version = "1.0" | ||
description = "xenox" | ||
|
||
plugins { | ||
`java-library` | ||
kotlin("jvm") version ("1.6.21") | ||
|
||
id("org.javamodularity.moduleplugin") version ("1.8.11") | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
implementation(platform(kotlin("bom"))) | ||
|
||
api(project(":services")) | ||
} | ||
|
||
tasks.compileJava { | ||
modularity.inferModulePath.set(true) | ||
sourceCompatibility = javaVersion | ||
targetCompatibility = javaVersion | ||
options.encoding = Charsets.UTF_8.toString() | ||
} | ||
|
||
tasks.compileKotlin { | ||
destinationDirectory.set(tasks.compileJava.get().destinationDirectory) | ||
targetCompatibility = javaVersion | ||
kotlinOptions { | ||
jvmTarget = javaVersion | ||
} | ||
} | ||
|
||
tasks.jar { | ||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
module Xenox.campaign { | ||
requires kotlin.stdlib; | ||
requires Xenox.services; | ||
|
||
exports gargoyle.xenox.campaign; | ||
provides gargoyle.xenox.info.CampaignInfo with gargoyle.xenox.campaign.TestCampaignInfo; | ||
|
||
} |
10 changes: 10 additions & 0 deletions
10
campaign/src/main/kotlin/gargoyle/xenox/campaign/TestCampaignInfo.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package gargoyle.xenox.campaign | ||
|
||
import gargoyle.xenox.campaign.level1.TestLevelInfo | ||
import gargoyle.xenox.info.CampaignInfo | ||
import gargoyle.xenox.info.LevelInfo | ||
|
||
class TestCampaignInfo : CampaignInfo { | ||
override val name: String = "Test" | ||
override val levels: List<LevelInfo> = listOf(TestLevelInfo) | ||
} |
17 changes: 17 additions & 0 deletions
17
campaign/src/main/kotlin/gargoyle/xenox/campaign/level1/TestLevelInfo.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package gargoyle.xenox.campaign.level1 | ||
|
||
import gargoyle.xenox.info.LevelInfo | ||
import java.net.URL | ||
|
||
object TestLevelInfo : LevelInfo { | ||
override val title: String = "Test" | ||
override val balls: Int = 5 | ||
override val width: Int = 100 | ||
override val height: Int = 50 | ||
override val lives: Int = 10 | ||
override val percent: Int = 80 | ||
override val speed: Int = 50 | ||
override val cover: URL? = javaClass.getResource("cover1.jpg") | ||
override val image: URL? = javaClass.getResource("image1.jpg") | ||
override val music: URL? = javaClass.getResource("music1.au") | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
val javaVersion: String = JavaVersion.VERSION_16.toString() | ||
|
||
val appMainClass: String = "gargoyle.xenox.Xenox" | ||
val appModule: String = "Xenox" | ||
val appName: String = "Xenox" | ||
|
||
val os: org.gradle.internal.os.OperatingSystem = org.gradle.internal.os.OperatingSystem.current() | ||
val appInstallerType: String = "msi" | ||
val appIconIco: String = "game/src/main/resources/gargoyle/xenox/icon.ico" | ||
val appIconPng: String = "game/src/main/resources/gargoyle/xenox/icon.gif" | ||
val appCopyright: String = "Lure of Chaos" | ||
val appVendor: String = "Lure of Chaos" | ||
|
||
group = "gargoyle.xenox" | ||
version = "1.0" | ||
description = "xenox" | ||
|
||
plugins { | ||
java | ||
application | ||
kotlin("jvm") version ("1.6.21") | ||
|
||
id("org.javamodularity.moduleplugin") version ("1.8.11") | ||
id("org.beryx.jlink") version ("2.25.0") | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
constraints { | ||
implementation(kotlin("stdlib-jdk7")) | ||
implementation(kotlin("stdlib-jdk8")) | ||
} | ||
implementation(platform(kotlin("bom"))) | ||
|
||
implementation(project(":util")) | ||
|
||
implementation(project(":services")) | ||
implementation(project(":campaign")) | ||
} | ||
|
||
tasks.compileJava { | ||
modularity.inferModulePath.set(true) | ||
sourceCompatibility = javaVersion | ||
targetCompatibility = javaVersion | ||
options.encoding = Charsets.UTF_8.toString() | ||
} | ||
|
||
tasks.compileKotlin { | ||
destinationDirectory.set(tasks.compileJava.get().destinationDirectory) | ||
targetCompatibility = javaVersion | ||
kotlinOptions { | ||
jvmTarget = javaVersion | ||
} | ||
} | ||
|
||
tasks.jar { | ||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE | ||
} | ||
|
||
tasks.build { | ||
dependsOn += tasks.jpackage | ||
} | ||
|
||
application { | ||
mainClass.set(appMainClass) | ||
mainModule.set(appModule) | ||
} | ||
|
||
jlink { | ||
options.set(listOf("--strip-debug", "--compress", "2", "--no-header-files", "--no-man-pages")) | ||
launcher { | ||
name = appName | ||
mainClass.set(appMainClass) | ||
} | ||
jpackage { | ||
installerType = appInstallerType | ||
installerName = appName | ||
appVersion = project.version.toString() | ||
if (os.isWindows) { | ||
icon = rootProject.file(appIconIco).path | ||
installerOptions = listOf( | ||
"--description", rootProject.description, | ||
"--copyright", appCopyright, | ||
"--vendor", appVendor, | ||
"--win-dir-chooser", | ||
"--win-menu", | ||
"--win-per-user-install", | ||
"--win-shortcut" | ||
) | ||
} | ||
if (os.isLinux) { | ||
icon = rootProject.file(appIconPng).path | ||
installerOptions = listOf( | ||
"--description", rootProject.description, | ||
"--copyright", appCopyright, | ||
"--vendor", appVendor, | ||
"--linux-shortcut" | ||
) | ||
} | ||
if (os.isMacOsX) { | ||
icon = rootProject.file(appIconPng).path | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
module Xenox { | ||
requires kotlin.stdlib; | ||
requires kotlin.stdlib.jdk7; | ||
requires kotlin.stdlib.jdk8; | ||
|
||
requires transitive java.desktop; | ||
requires transitive java.prefs; | ||
|
||
requires Xenox.util; | ||
|
||
exports gargoyle.xenox; | ||
|
||
requires transitive Xenox.services; | ||
requires Xenox.campaign; | ||
uses gargoyle.xenox.info.CampaignInfo; | ||
} |
Oops, something went wrong.