Skip to content

Commit

Permalink
Merge pull request #38 from openbase/new-map
Browse files Browse the repository at this point in the history
Added Tonic Ressources to all Maps + New Maps
  • Loading branch information
DivineThreepwood authored Feb 29, 2024
2 parents 0d9634f + d0a0aa4 commit c0333ab
Show file tree
Hide file tree
Showing 33 changed files with 359 additions and 30 deletions.
3 changes: 3 additions & 0 deletions src/main/kotlin/org/openbase/planetsudo/level/LevelLoader.kt
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,9 @@ class LevelLoader {
"Pentagon",
"UnbekannterWeg",
"Maze",
"LordHelmchen",
"Hexagon",
"WakaWakaVol2",
)

@JvmStatic
Expand Down
3 changes: 2 additions & 1 deletion src/main/kotlin/org/openbase/planetsudo/level/save/AgentK.kt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class AgentK : AbstractLevel() {

override fun loadHomePositions(): List<Base2D> = listOf(
Base2D(1200.0, 100.0, Direction2D.DOWN),
Base2D(1200.0, 1900.0, Direction2D.DOWN),
Base2D(1200.0, 1900.0, Direction2D.UP),
)

override fun loadResourcePlacement(): List<ResourcePlacement> = listOf(
Expand All @@ -48,6 +48,7 @@ class AgentK : AbstractLevel() {
ResourceRandomRectangle(0, 1000, 500, 500, 5, ResourceType.Normal),
ResourceRandomRectangle(0, 0, 500, 500, 5, ResourceType.DoublePoints),
ResourceRandomRectangle(0, 1500, 500, 500, 5, ResourceType.DoublePoints),
ResourceRandomRectangle(0, 0, 50, 2000, 20, ResourceType.Tonic),
)

override fun loadLevelColor(): Color = Color(137, 67, 162)
Expand Down
12 changes: 6 additions & 6 deletions src/main/kotlin/org/openbase/planetsudo/level/save/Arena.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,26 +18,22 @@ import java.awt.Polygon
*/
class Arena : AbstractLevel() {
override fun loadLevelBorderPolygon() = Polygon().apply {
addPoint(0, 0)
addPoint(0, 200)
addPoint(400, 200)
addPoint(400, 0)
addPoint(600, 0)
addPoint(600, 200)
addPoint(1000, 200)
addPoint(1000, 0)
addPoint(1000, 800)
addPoint(600, 800)
addPoint(600, 1000)
addPoint(1000, 1000)
addPoint(0, 1000)
addPoint(400, 1000)
addPoint(400, 800)
addPoint(0, 800)
}

override fun loadHomePositions() = listOf(
Base2D(500.0, 100.0, Direction2D.UP),
Base2D(500.0, 100.0, Direction2D.DOWN),
Base2D(500.0, 900.0, Direction2D.UP),
)

Expand All @@ -46,8 +42,12 @@ class Arena : AbstractLevel() {
ResourceRandomRectangle(300, 325, 400, 50, 10, ResourceType.DoublePoints),
ResourceRandomRectangle(300, 675, 400, 50, 10, ResourceType.DoublePoints),
ResourceRandomRectangle(400, 480, 200, 40, 10, ResourceType.ExtremPoint),
ResourceRandomRectangle(0, 0, 1000, 1000, 5, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 0, 1000, 1000, 10, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 0, 1000, 1000, 5, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 200, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(900, 200, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(0, 700, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(900, 700, 100, 100, 5, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(67, 167, 197)
Expand Down
4 changes: 4 additions & 0 deletions src/main/kotlin/org/openbase/planetsudo/level/save/Atomum.kt
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ class Atomum : AbstractLevel() {
ResourceRandomRectangle(1600, 1300, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(1440, 1450, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(1300, 1600, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(300, 300, 400, 300, 7, ResourceType.Tonic),
ResourceRandomRectangle(300, 1300, 400, 400, 7, ResourceType.Tonic),
ResourceRandomRectangle(1300, 300, 400, 400, 7, ResourceType.Tonic),
ResourceRandomRectangle(1300, 1300, 400, 400, 7, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(169, 249, 4)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ class AtomumLight : AbstractLevel() {
ResourceRandomRectangle(1600, 1300, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(1440, 1450, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(1300, 1600, 100, 100, 3, ResourceType.DoublePoints),
ResourceRandomRectangle(300, 300, 400, 300, 7, ResourceType.Tonic),
ResourceRandomRectangle(300, 1300, 400, 400, 7, ResourceType.Tonic),
ResourceRandomRectangle(1300, 300, 400, 400, 7, ResourceType.Tonic),
ResourceRandomRectangle(1300, 1300, 400, 400, 7, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(169, 249, 4)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class BackToBack : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(390.0, 450.0, Direction2D.RIGHT),
Base2D(390.0, 450.0, Direction2D.LEFT),
Base2D(610.0, 450.0, Direction2D.RIGHT),
)

Expand All @@ -35,6 +35,10 @@ class BackToBack : AbstractLevel() {
ResourceRandomRectangle(400, 800, 200, 200, 10, ResourceType.ExtremPoint),
ResourceRandomRectangle(0, 0, 1000, 1000, 10, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(400, 0, 200, 200, 10, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 0, 50, 50, 5, ResourceType.Tonic),
ResourceRandomRectangle(0, 950, 50, 50, 5, ResourceType.Tonic),
ResourceRandomRectangle(950, 0, 50, 50, 5, ResourceType.Tonic),
ResourceRandomRectangle(950, 950, 50, 50, 5, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(244, 164, 96)
Expand Down
4 changes: 3 additions & 1 deletion src/main/kotlin/org/openbase/planetsudo/level/save/Broken.kt
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class Broken : AbstractLevel() {
}

override fun loadHomePositions(): List<Base2D> = listOf(
Base2D(200.0, 1800.0, Direction2D.DOWN),
Base2D(200.0, 1800.0, Direction2D.UP),
Base2D(1800.0, 200.0, Direction2D.DOWN),
)

Expand All @@ -51,6 +51,8 @@ class Broken : AbstractLevel() {
ResourceRandomRectangle(300, 800, 300, 500, 35, ResourceType.ExtremPoint),
ResourceRandomRectangle(700, 0, 600, 2000, 30, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(700, 0, 600, 2000, 50, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 500, 500, 1000, 15, ResourceType.Tonic),
ResourceRandomRectangle(1500, 500, 500, 1000, 15, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(74, 164, 94)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class ChemStation : AbstractLevel() {

override fun loadHomePositions() = listOf(
Base2D(1400.0, 1000.0, Direction2D.DOWN),
Base2D(1400.0, 1800.0, Direction2D.DOWN),
Base2D(1400.0, 1800.0, Direction2D.UP),
)

override fun loadResourcePlacement() = listOf(
Expand All @@ -42,7 +42,9 @@ class ChemStation : AbstractLevel() {
ResourceRandomRectangle(1600, 1300, 200, 200, 5, ResourceType.ExtremPoint),
ResourceRandomRectangle(400, 400, 600, 2000, 30, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(1800, 400, 600, 2000, 30, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(100, 1200, 2600, 400, 70, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(100, 800, 2600, 1200, 70, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 800, 200, 1200, 15, ResourceType.Tonic),
ResourceRandomRectangle(2600, 800, 200, 1200, 15, ResourceType.Tonic),
)

override fun loadLevelColor(): Color {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ class CircleOfLife : AbstractLevel() {
ResourceRandomRectangle(600, 0, 400, 1000, 5, ResourceType.DoublePoints),
ResourceRandomRectangle(400, 800, 200, 200, 10, ResourceType.ExtremPoint),
ResourceRandomRectangle(400, 0, 200, 200, 10, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 0, 1000, 50, 6, ResourceType.Tonic),
ResourceRandomRectangle(0, 950, 1000, 50, 6, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(255, 153, 0)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ class DasBoot : AbstractLevel() {
ResourceRandomRectangle(350, 750, 375, 300, 10, ResourceType.Normal),
ResourceRandomRectangle(1500, 750, 375, 300, 10, ResourceType.Normal),
ResourceRandomRectangle(750, 375, 675, 375, 15, ResourceType.DoublePoints),
ResourceRandomRectangle(750, 375, 675, 175, 15, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(0, 191, 255)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,18 @@ class Engpass : AbstractLevel() {

override fun loadHomePositions() = listOf(
Base2D(80.0, 500.0, Direction2D.LEFT),
Base2D(920.0, 500.0, Direction2D.LEFT),
Base2D(920.0, 500.0, Direction2D.RIGHT),
)

override fun loadResourcePlacement() = listOf(
ResourceRandomRectangle(0, 0, 1000, 1000, 5, ResourceType.Normal),
ResourceRandomRectangle(0, 0, 450, 450, 5, ResourceType.DoublePoints),
ResourceRandomRectangle(550, 550, 1000, 1000, 5, ResourceType.DoublePoints),
ResourceRandomRectangle(495, 300, 5, 400, 20, ResourceType.ExtremPoint),
ResourceRandomRectangle(0, 0, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(0, 900, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(900, 0, 100, 100, 5, ResourceType.Tonic),
ResourceRandomRectangle(900, 900, 100, 100, 5, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(67, 167, 197)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ class Entropie : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(100.0, 200.0, Direction2D.DOWN),
Base2D(100.0, 1200.0, Direction2D.DOWN),
Base2D(100.0, 200.0, Direction2D.RIGHT),
Base2D(100.0, 1200.0, Direction2D.RIGHT),
)

override fun loadResourcePlacement() = listOf(
Expand All @@ -43,6 +43,7 @@ class Entropie : AbstractLevel() {
ResourceRandomRectangle(150, 600, 300, 200, 50, ResourceType.ExtremPoint),
ResourceRandomRectangle(800, 0, 100, 1400, 20, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(150, 600, 300, 200, 10, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(850, 0, 50, 1400, 6, ResourceType.Tonic),
)

override fun loadLevelColor(): Color {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class FrauenWG : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(750.0, 700.0, Direction2D.DOWN),
Base2D(750.0, 700.0, Direction2D.UP),
Base2D(1600.0, 950.0, Direction2D.DOWN),
)

Expand All @@ -87,6 +87,8 @@ class FrauenWG : AbstractLevel() {
ResourceRandomRectangle(400, 1350, 300, 300, 50, ResourceType.ExtremPoint),
ResourceRandomRectangle(1750, 0, 300, 300, 50, ResourceType.ExtremPoint),
ResourceRandomRectangle(900, 550, 550, 550, 30, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 0, 100, 1650, 15, ResourceType.Tonic),
ResourceRandomRectangle(2350, 0, 100, 1650, 15, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(0, 0, 0)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class HeliLandeplatz : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(200.0, 850.0, Direction2D.DOWN),
Base2D(200.0, 850.0, Direction2D.UP),
Base2D(900.0, 150.0, Direction2D.DOWN),
)

Expand All @@ -44,6 +44,8 @@ class HeliLandeplatz : AbstractLevel() {
ResourceRandomRectangle(400, 300, 300, 300, 3, ResourceType.ExtremPoint),
ResourceRandomRectangle(400, 300, 300, 300, 5, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(400, 300, 300, 300, 10, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 0, 400, 50, 10, ResourceType.Tonic),
ResourceRandomRectangle(700, 950, 400, 50, 10, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(167, 167, 197)
Expand Down
55 changes: 55 additions & 0 deletions src/main/kotlin/org/openbase/planetsudo/level/save/Hexagon.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.openbase.planetsudo.level.save

import org.openbase.planetsudo.geometry.Base2D
import org.openbase.planetsudo.geometry.Direction2D
import org.openbase.planetsudo.level.AbstractLevel
import org.openbase.planetsudo.level.ResourceRandomRectangle
import org.openbase.planetsudo.level.levelobjects.Resource.ResourceType
import java.awt.Color
import java.awt.Polygon

/**
*
* @author Jodi_Pa
*/
class Hexagon : AbstractLevel() {
override fun loadLevelBorderPolygon() = Polygon().apply {
addPoint(500, 0)
addPoint(1500, 0)
addPoint(2000, 866)
addPoint(1500, 1732)
addPoint(500, 1732)
addPoint(0, 866)
}

override fun loadHomePositions() = listOf(
Base2D(500.0, 866.0, Direction2D.RIGHT),
Base2D(1500.0, 866.0, Direction2D.LEFT),
)

override fun loadResourcePlacement() = listOf(
ResourceRandomRectangle(0, 0, 2000, 1732, 15, ResourceType.Normal),
ResourceRandomRectangle(0, 0, 2000, 200, 10, ResourceType.DoublePoints),
ResourceRandomRectangle(0, 1632, 2000, 200, 10, ResourceType.DoublePoints),
ResourceRandomRectangle(950, 0, 100, 1732, 10, ResourceType.ExtremPoint),
ResourceRandomRectangle(500, 433, 1000, 866, 20, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(500, 433, 1000, 866, 15, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 816, 100, 50, 12, ResourceType.Tonic),
ResourceRandomRectangle(1900, 816, 100, 100, 12, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(255, 153, 0)

override fun loadLevelWallPolygons() = listOf(
Polygon().apply {
addPoint(950, 433)
addPoint(1050, 433)
addPoint(1050, 1299)
addPoint(950, 1299)
},
)
}
3 changes: 2 additions & 1 deletion src/main/kotlin/org/openbase/planetsudo/level/save/JD.kt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class JD : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(750.0, 750.0, Direction2D.DOWN),
Base2D(750.0, 750.0, Direction2D.UP),
Base2D(1050.0, 1050.0, Direction2D.DOWN),
)

Expand All @@ -44,6 +44,7 @@ class JD : AbstractLevel() {
ResourceRandomRectangle(0, 0, 1800, 1800, 10, ResourceType.ExtremPoint),
ResourceRandomRectangle(0, 0, 1800, 1800, 10, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(0, 0, 1800, 1800, 10, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(550, 550, 700, 700, 12, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(150, 150, 150)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class Kreuzung : AbstractLevel() {
}

override fun loadHomePositions() = listOf(
Base2D(500.0, 100.0, Direction2D.UP),
Base2D(500.0, 100.0, Direction2D.DOWN),
Base2D(500.0, 900.0, Direction2D.UP),
)

Expand All @@ -34,9 +34,10 @@ class Kreuzung : AbstractLevel() {
ResourceRandomRectangle(375, 350, 300, 10, 8, ResourceType.DoublePoints),
ResourceRandomRectangle(375, 650, 300, 10, 8, ResourceType.DoublePoints),
ResourceRandomRectangle(450, 450, 100, 100, 8, ResourceType.ExtremPoint),
ResourceRandomRectangle(450, 450, 100, 100, 8, ResourceType.Tonic),
ResourceRandomRectangle(400, 400, 200, 200, 0, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(400, 400, 200, 200, 0, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 350, 350, 300, 5, ResourceType.Tonic),
ResourceRandomRectangle(650, 350, 350, 300, 5, ResourceType.Tonic),
)

override fun loadLevelColor(): Color {
Expand Down
57 changes: 57 additions & 0 deletions src/main/kotlin/org/openbase/planetsudo/level/save/LordHelmchen.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.openbase.planetsudo.level.save

import org.openbase.planetsudo.geometry.Base2D
import org.openbase.planetsudo.geometry.Direction2D
import org.openbase.planetsudo.level.AbstractLevel
import org.openbase.planetsudo.level.ResourceRandomRectangle
import org.openbase.planetsudo.level.levelobjects.Resource.ResourceType
import java.awt.Color
import java.awt.Polygon

/**
*
* @author Jodi_Pa
*/
class LordHelmchen : AbstractLevel() {
override fun loadLevelBorderPolygon() = Polygon().apply {
addPoint(300, 0)
addPoint(700, 0)
addPoint(850, 100)
addPoint(1000, 700)
addPoint(0, 700)
addPoint(150, 100)
}

override fun loadHomePositions() = listOf(
Base2D(350.0, 500.0, Direction2D.LEFT),
Base2D(650.0, 500.0, Direction2D.RIGHT),
)

override fun loadResourcePlacement() = listOf(
ResourceRandomRectangle(0, 0, 1000, 700, 4, ResourceType.Normal),
ResourceRandomRectangle(0, 0, 1000, 250, 6, ResourceType.DoublePoints),
ResourceRandomRectangle(400, 0, 200, 100, 4, ResourceType.ExtremPoint),
ResourceRandomRectangle(100, 0, 800, 250, 6, ResourceType.ExtraAgentFuel),
ResourceRandomRectangle(300, 0, 400, 250, 6, ResourceType.ExtraMothershipFuel),
ResourceRandomRectangle(0, 0, 1000, 50, 10, ResourceType.Tonic),
)

override fun loadLevelColor() = Color(255, 153, 0)

override fun loadLevelWallPolygons() = listOf(
Polygon().apply {
addPoint(350, 200)
addPoint(650, 200)
addPoint(650, 300)
addPoint(550, 300)
addPoint(550, 700)
addPoint(450, 700)
addPoint(450, 300)
addPoint(350, 300)
},
)
}
Loading

0 comments on commit c0333ab

Please sign in to comment.