diff options
Diffstat (limited to 'src/game/GameController.cpp')
| -rw-r--r-- | src/game/GameController.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/game/GameController.cpp b/src/game/GameController.cpp index 80f45ff..a4a99c2 100644 --- a/src/game/GameController.cpp +++ b/src/game/GameController.cpp @@ -241,6 +241,25 @@ void GameController::DrawPoints(int toolSelection, queue<ui::Point*> & pointQueu } } +void GameController::StampRegion(ui::Point point1, ui::Point point2) +{ + int saveSize; + unsigned char * saveData; + saveData = gameModel->GetSimulation()->Save(point1.X, point1.Y, point2.X, point2.Y, saveSize); + if(saveData && saveSize) + gameModel->AddStamp(saveData, saveSize); +} + +void GameController::CopyRegion(ui::Point point1, ui::Point point2) +{ + int saveSize; + unsigned char * saveData; + saveData = gameModel->GetSimulation()->Save(point1.X, point1.Y, point2.X, point2.Y, saveSize); + + if(saveData && saveSize) + gameModel->SetClipboard(saveData, saveSize); +} + void GameController::Update() { gameModel->GetSimulation()->update_particles(); |
