From a9013b30b02950aac3cad48e0c5c7251c990485e Mon Sep 17 00:00:00 2001 From: LimePotato Date: Mon, 30 Oct 2023 11:45:19 -0600 Subject: [PATCH] Catppuccify --- .../ouroboros/potrogue/builders/GameColors.kt | 11 +++++----- .../potrogue/builders/GameTileRepository.kt | 22 +++++++++---------- .../potrogue/data/config/GameConfig.kt | 15 +++++++++++-- 3 files changed, 29 insertions(+), 19 deletions(-) diff --git a/src/main/kotlin/group/ouroboros/potrogue/builders/GameColors.kt b/src/main/kotlin/group/ouroboros/potrogue/builders/GameColors.kt index 469530a..f009bb9 100644 --- a/src/main/kotlin/group/ouroboros/potrogue/builders/GameColors.kt +++ b/src/main/kotlin/group/ouroboros/potrogue/builders/GameColors.kt @@ -3,14 +3,13 @@ package group.ouroboros.potrogue.builders import org.hexworks.zircon.api.color.TileColor object GameColors { - //TODO: Change these colors to our own custom theme //We set some colors for tiles - val WALL_FOREGROUND = TileColor.fromString("#75715E") - val WALL_BACKGROUND = TileColor.fromString("#3E3D32") + val wallForegroundColor = TileColor.fromString("#1e1e2e") + val wallBackgroundColor = TileColor.fromString("#cba6f7") - val FLOOR_FOREGROUND = TileColor.fromString("#75715E") - val FLOOR_BACKGROUND = TileColor.fromString("#1e2320") + val floorForegroundColor = TileColor.fromString("#1e1e2e") + val floorBackgroundColor = TileColor.fromString("#11111b") // Player Color? - val ACCENT_COLOR = TileColor.fromString("#FFCD22") + val accentColor = TileColor.fromString("#94e2d5") } \ No newline at end of file diff --git a/src/main/kotlin/group/ouroboros/potrogue/builders/GameTileRepository.kt b/src/main/kotlin/group/ouroboros/potrogue/builders/GameTileRepository.kt index 9f26bc4..7f65b81 100644 --- a/src/main/kotlin/group/ouroboros/potrogue/builders/GameTileRepository.kt +++ b/src/main/kotlin/group/ouroboros/potrogue/builders/GameTileRepository.kt @@ -1,10 +1,10 @@ package group.ouroboros.potrogue.builders -import group.ouroboros.potrogue.builders.GameColors.ACCENT_COLOR -import group.ouroboros.potrogue.builders.GameColors.FLOOR_BACKGROUND -import group.ouroboros.potrogue.builders.GameColors.FLOOR_FOREGROUND -import group.ouroboros.potrogue.builders.GameColors.WALL_BACKGROUND -import group.ouroboros.potrogue.builders.GameColors.WALL_FOREGROUND +import group.ouroboros.potrogue.builders.GameColors.accentColor +import group.ouroboros.potrogue.builders.GameColors.floorBackgroundColor +import group.ouroboros.potrogue.builders.GameColors.floorForegroundColor +import group.ouroboros.potrogue.builders.GameColors.wallBackgroundColor +import group.ouroboros.potrogue.builders.GameColors.wallForegroundColor import org.hexworks.zircon.api.data.CharacterTile import org.hexworks.zircon.api.data.Tile import org.hexworks.zircon.api.graphics.Symbols @@ -19,22 +19,22 @@ object GameTileRepository { //Floor Tile val FLOOR: CharacterTile = Tile.newBuilder() .withCharacter(Symbols.INTERPUNCT) - .withForegroundColor(FLOOR_FOREGROUND) - .withBackgroundColor(FLOOR_BACKGROUND) + .withForegroundColor(floorForegroundColor) + .withBackgroundColor(floorBackgroundColor) .buildCharacterTile() //Wall Tile val WALL: CharacterTile = Tile.newBuilder() .withCharacter('▒') - .withForegroundColor(WALL_FOREGROUND) - .withBackgroundColor(WALL_BACKGROUND) + .withForegroundColor(wallForegroundColor) + .withBackgroundColor(wallBackgroundColor) .buildCharacterTile() //Player Tile val PLAYER: CharacterTile = Tile.newBuilder() .withCharacter('☺') - .withBackgroundColor(FLOOR_BACKGROUND) - .withForegroundColor(ACCENT_COLOR) + .withBackgroundColor(floorBackgroundColor) + .withForegroundColor(accentColor) .buildCharacterTile() } \ No newline at end of file diff --git a/src/main/kotlin/group/ouroboros/potrogue/data/config/GameConfig.kt b/src/main/kotlin/group/ouroboros/potrogue/data/config/GameConfig.kt index 318c3d1..6f94484 100644 --- a/src/main/kotlin/group/ouroboros/potrogue/data/config/GameConfig.kt +++ b/src/main/kotlin/group/ouroboros/potrogue/data/config/GameConfig.kt @@ -3,14 +3,15 @@ package group.ouroboros.potrogue.data.config import group.ouroboros.potrogue.GAME_ID import group.ouroboros.potrogue.GAME_VER import org.hexworks.zircon.api.CP437TilesetResources -import org.hexworks.zircon.api.ColorThemes +import org.hexworks.zircon.api.ColorThemes.newBuilder import org.hexworks.zircon.api.application.AppConfig +import org.hexworks.zircon.api.color.TileColor import org.hexworks.zircon.api.data.Size3D + object GameConfig { // look & feel var TILESET = CP437TilesetResources.rogueYun16x16() - val THEME = ColorThemes.cyberpunk() val WORLD_SIZE = Size3D.create(Config().windowWidth * 3, Config().windowHeight * 3 , Config().dungeonLevels) val GAME_AREA_SIZE = Size3D.create( @@ -25,4 +26,14 @@ object GameConfig { .withTitle("$GAME_ID | $GAME_VER") .withIcon("assets/icon.png") .build() + + var catppuccinMocha = newBuilder() + .withAccentColor(TileColor.fromString("#b4befe")) + .withPrimaryForegroundColor(TileColor.fromString("#f5c2e7")) + .withSecondaryForegroundColor(TileColor.fromString("#cba6f7")) + .withPrimaryBackgroundColor(TileColor.fromString("#1e1e2e")) + .withSecondaryBackgroundColor(TileColor.fromString("#11111b")) + .build() + + val THEME = catppuccinMocha }