Changes
Page history
Added Model.People package to Class Diagram
authored
Mar 01, 2021
by
Kovács Gergely Zsolt
Show whitespace changes
Inline
Side-by-side
Class-Diagram.md
View page @
cb4695c0
...
@@ -19,9 +19,56 @@ package Model.Common {
...
@@ -19,9 +19,56 @@ package Model.Common {
}
}
class Singleton {
class Singleton {
- {static} instance :
Singleton
- {static} instance :
T
- Singleton()
- Singleton()
+ {static} GetInstance() : Singleton
+ {static} GetInstance() : T
}
Singleton <|-- Simulation
class Simulation {
- people : Person[]
- Simulation()
}
Simulation --> Park
Singleton <|-- Park
IInspectable <|-- Park
class Park {
- balance : int
- entryFee : int
- buildings : Building[]
- Park()
+ GetBalance() : int
+ GetEntryFee() : int
+ GetBuildings() : Building[]
+ ModifyBalance(int)
+ AddBuilding(Building)
+ SetEntryFee(int)
}
IDisplayable <|-- WorldEntity
class WorldEntity {
- position : Vector2
- visible : bool
# WorldEntity(Vector2)
+ GetPosition() : Vector2
+ GetVisible() : bool
+ SetPosition(Vector2)
+ SetVisible(bool)
}
Singleton <|-- MaintenanceDispatcher
Simulation ---> MaintenanceDispatcher
class MaintenanceDispatcher {
- maintainers : MaintenanceGuy[]
- MaintenanceDispatcher()
+ {static} GameBroken(Building)
}
}
}
}
...
@@ -42,6 +89,7 @@ package Model.Nav {
...
@@ -42,6 +89,7 @@ package Model.Nav {
}
}
package Model.Map {
package Model.Map {
WorldEntity <|-- MapObject
abstract class MapObject {
abstract class MapObject {
+ Enter(Person) : Vector2? {abstract}
+ Enter(Person) : Vector2? {abstract}
...
@@ -64,7 +112,10 @@ package Model.Map {
...
@@ -64,7 +112,10 @@ package Model.Map {
class Placement {
class Placement {
+ Pos : Vector2
+ Pos : Vector2
}
}
Placement "1" *-- Orientation
Placement "1" *-- Orientation
Simulation "1" *- Map
class Map {
class Map {
+ Map(Vector2)
+ Map(Vector2)
...
@@ -89,44 +140,7 @@ package Model.Map {
...
@@ -89,44 +140,7 @@ package Model.Map {
}
}
Singleton <|-- Simulation
package Model.People {
class Simulation {
- people : Person[]
- Simulation()
}
Simulation --> Park
Singleton <|-- Park
IInspectable <|-- Park
class Park {
- balance : int
- entryFee : int
- buildings : Building[]
- Park()
+ GetBalance() : int
+ GetEntryFee() : int
+ GetBuildings() : Building[]
+ ModifyBalance(int)
+ AddBuilding(Building)
+ SetEntryFee(int)
}
IDisplayable <|-- WorldEntity
class WorldEntity {
- position : Vector2
- visible : bool
# WorldEntity(Vector2)
+ GetPosition() : Vector2
+ GetVisible() : bool
+ SetPosition(Vector2)
+ SetVisible(bool)
}
Simulation *-- "-people\n*" Person
Simulation *-- "-people\n*" Person
IInspectable <|--- Person
IInspectable <|--- Person
ITickable <|--- Person
ITickable <|--- Person
...
@@ -138,6 +152,7 @@ class Person {
...
@@ -138,6 +152,7 @@ class Person {
- speed : float {readonly}
- speed : float {readonly}
- pavement : Pavement
- pavement : Pavement
- routeHandle : RouteHandle
- routeHandle : RouteHandle
- name : string
# Person(Vector2, float)
# Person(Vector2, float)
+ Tick() {override}
+ Tick() {override}
+ GetProperties() {override}
+ GetProperties() {override}
...
@@ -188,29 +203,15 @@ class CleaningLady {
...
@@ -188,29 +203,15 @@ class CleaningLady {
Staff <|-- MaintenanceGuy
Staff <|-- MaintenanceGuy
MaintenanceDispatcher *-- "-maintainers\n*" MaintenanceGuy
class MaintenanceGuy {
class MaintenanceGuy {
+ MaintenanceGuy(Vector2, float)
+ MaintenanceGuy(Vector2, float)
+ Tick() {override}
+ Tick() {override}
+ GetProperties() {override}
+ GetProperties() {override}
}
}
Singleton <|-- MaintenanceDispatcher
Simulation ---> MaintenanceDispatcher
class MaintenanceDispatcher {
- maintainers : MaintenanceGuy[]
- MaintenanceDispatcher()
+ {static} GameBroken(Building)
}
}
MaintenanceDispatcher *-- "-maintainers\n*" MaintenanceGuy
Simulation "1" *- Map
WorldEntity <|-- MapObject
package Model.Landscape {
package Model.Landscape {
package Blueprints {
package Blueprints {
...
...
...
...