Game uml
---
config:
theme: forest
---
classDiagram
GridCell --|> RotatingSpriteGameObject
class GridCell{
+ string cellState
+ bool bottomRow
+ DetectBottomRow() void
+ Rotate() void
}
Grid --|> GameObjectList
Grid *-- GridCell
Grid *-- BallObject
class Grid {
- Int _rows
- Int _columns
- Int _cellSpacing
- Vector2 origin
- float _bottomRowY
- Int _bottomRowIndex
- InitializeGrid() void
- SpawnBall() void
- CheckCollision() void
- CollisionLogic() void
- GetBottomRow() float
- CheckForWinner() void
- RotateGrid() void
- ReinitializeGrid() void
}
class GameObjectList {
+ Add()
+ Update()
+ Draw(GameTime gameTime, SpriteBatch spriteBatch) void
}
SpriteGameObject <|-- BallObject : collision + sprites
class SpriteGameObject {
# String SpriteSheet
+ CollidesWith() bool
+ Draw(GameTime gameTime, SpriteBatch spriteBatch) void
}
class BallObject {
+ string Team
+ bool falling
- GetSpritePathForTeam()
# SetSprite()
# GetBottomRow()
}
class RotatingSpriteGameObject{
+ float Angle
+ float Degrees
+ Update() void
}
Player --|> SpriteGameObject
Grid --> Player
class Player{
- int _currentColumn
- SpriteGameObject _ghostPiece
- HandleInput()
- UpdatePosition()
+ GetCurrentColumn()
}
Last update:
May 22, 2025