Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ contributing to Canopy, especially via bug reports, feature proposals and pull r

Before contributing to the engine, it's recommend you read the [engine details](https://github.com/canopyengine/canopy-docs/tree/main/markdown/engine-details) documents.

You can check the full guidelines in the [Contribution Guidelines](https://github.com/canopyengine/canopy-docs/blob/main/markdown/contributing/contributing.md)

## Table of contents

Expand All @@ -21,7 +22,7 @@ Before contributing to the engine, it's recommend you read the [engine details](
Report bugs [here](https://github.com/canopyengine/canopy/issues/new?assignees=&labels=&template=bug_report.md).
Please follow the instructions in the template when you do.

> [!IMPORTANT]
> [!CAUTION]
> Make sure that the bug you are experiencing is reproducible in the latest Canopy releases.

If you run into a bug which wasn't present in an earlier Canopy version (what we call a _regression_), please mention it
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
Canopy is a:
* node-based
* declarative
* 2D game engine built in[Kotlin](https://kotlinlang.org/)
* 2D game engine built in [Kotlin](https://kotlinlang.org/)

It's designed to be **Kotlin-native**, built with declarative APIs, node composition, and reactive patterns in mind to
create games in a clean, expressive, and maintainable way.
Expand Down Expand Up @@ -85,12 +85,12 @@ EmptyNode("level"){

You can see important information about the engine here:

| Section | Description |
|-----------------------------------------------------------------------| ---------------------- |
| [Introduction](docs/articles/introduction.md) | Overview of the engine |
| Section | Description |
|----------------------------------------------------------------------|------------------------|
| [Introduction](docs/articles/introduction.md) | Overview of the engine |
| [Official Documentation](https://github.com/canopyengine/canopy-docs) | Complete engine manual |
| [Release Notes](docs/releases/releases.md) | Changelogs |
| [Roadmap](docs/roadmap.md) | Planned development |
| [Release Notes](docs/releases/releases.md) | Changelogs |
| [Roadmap](docs/roadmap.md) | Planned development |


# License
Expand Down
16 changes: 8 additions & 8 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,19 @@ subprojects {
apply(plugin = "maven-publish")

extensions.configure<JavaPluginExtension> {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17

toolchain {
languageVersion = JavaLanguageVersion.of(21)
}

sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
withSourcesJar()
// withJavadocJar()
}

tasks.withType<KotlinCompile>().configureEach {
compilerOptions.jvmTarget.set(JvmTarget.JVM_17)
compilerOptions.jvmTarget.set(JvmTarget.JVM_21)
}

dependencies {
Expand All @@ -72,11 +77,6 @@ subprojects {
"testImplementation"(libs.junit.jupiter)
"testImplementation"(libs.assertj.core)
"testImplementation"(libs.mockk)

// natives classifier for tests
val gdxPlatform = libs.gdx.platform.get().module
val gdxVer = libs.versions.gdx.get()
"testRuntimeOnly"("$gdxPlatform:$gdxVer:natives-desktop")
}

// ---- Publishing to ~/.m2 ----
Expand Down
6 changes: 3 additions & 3 deletions engine/app/app-core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ plugins {

dependencies {
// Canopy deps
api(projects.engine.core)
api(projects.engine.logging)
api(projects.engine.data.dataCore)
implementation(projects.engine.core)
implementation(projects.engine.logging)
implementation(projects.engine.data.dataCore)

// Ktx
api(libs.ktx.app)
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ plugins {

dependencies {
// Canopy deps
api(projects.engine.app.appCore)
// implementation(projects.engine.logging)
implementation(projects.engine.app.appCore)
implementation(projects.engine.logging)

// Gdx
api(libs.gdx.backend.headless)
Expand Down
3 changes: 3 additions & 0 deletions engine/app/app-test/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ dependencies {

// Gdx
implementation(libs.gdx.backend.headless)
val gdxPlatform = libs.gdx.platform.get().module
val gdxVer = libs.versions.gdx.get()
api("$gdxPlatform:$gdxVer:natives-desktop")

// JSON
}
20 changes: 2 additions & 18 deletions engine/core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,12 @@ val enableGraalNative: Boolean = providers

dependencies {
// Canopy
implementation(projects.engine.utils)
implementation(projects.engine.logging)

// Gdx
api(libs.gdx.core)

// Ktx
api(libs.ktx.app)
api(libs.ktx.assets.async)
api(libs.ktx.assets)
api(libs.ktx.async)
api(libs.ktx.log)
api(libs.ktx.math)
api(projects.engine.utils)
api(projects.engine.logging)

// Logging
api(libs.slf4j.api)
runtimeOnly(libs.logback.classic)

// Graal helper only when enabled
if (enableGraalNative) {
implementation(libs.graal.helper.annotations)
}
}

// Canopy custom tasks
Expand Down
4 changes: 1 addition & 3 deletions engine/input/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,5 @@ dependencies {
implementation(projects.engine.data.dataCore)
implementation(projects.engine.data.dataSaving)
implementation(projects.engine.utils)

// JSON
implementation(libs.kotlinx.serialization.json)
implementation(projects.engine.logging)
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ package io.canopy.engine.input

import com.badlogic.gdx.Input
import io.canopy.engine.data.saving.registerSaveModule
import ktx.log.logger
import io.canopy.engine.logging.logger
import kotlinx.serialization.builtins.serializer

/**
* Maintains runtime mappings between **input actions** and **physical input binds**.
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ org.gradle.logging.level=quiet
enableGraalNative=false

# Canopy settings
canopyVersion = 0.1.0.alpha1
canopyVersion = 0.1.0-dev1
7 changes: 2 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,12 @@ slf4j = "2.0.16"
logback = "1.5.32"
logstash="9.0"

#Misc
# Misc
graalHelper = "2.0.1"

# TOML
tomlkt = "0.6.0"

# Release
axion-release = "1.21.1"

#####
#####

Expand Down Expand Up @@ -90,7 +87,7 @@ tomlkt = { module = "dev.eav.tomlkt:tomlkt", version.ref = "tomlkt" }
#####

[plugins]
# Kotlin
kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
ktlint = { id = "org.jlleitschuh.gradle.ktlint", version.ref = "ktlint" }
axion-release = {id = "pl.allegro.tech.build.axion-release", version.ref = "axion-release" }
51 changes: 23 additions & 28 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,33 +22,28 @@ plugins {
}

rootProject.name = "canopy"
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")

// Root modules
include(
":engine:core",
":engine:input",
//":engine:graphics",
//":engine:physics",
":engine:logging"
)

// App modules -
include(
":engine:app:app-core",
//":engine:app:app-desktop",
":engine:app:app-headless",
":engine:app:app-test"
)

// Data modules -
include(
":engine:data:data-core",
":engine:data:data-saving",
)

// Misc modules -
include(
":engine:utils"
)
/* ===================================== */
/* Canopy Modules Dependencies */
/* ===================================== */

enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
// Root modules
include(":engine:core")
include(":engine:input")
// include(":engine:graphics")
// include(":engine:physics")
include(":engine:logging")

// App modules
include(":engine:app:app-core")
// include(":engine:app:app-desktop")
include(":engine:app:app-terminal")
include(":engine:app:app-test")

// Data modules
include(":engine:data:data-core")
include(":engine:data:data-saving")

// Misc modules
include(":engine:utils")
Loading