Possible to plan ships movements on the map (UI only)

This commit is contained in:
Khopa
2020-12-03 01:01:15 +01:00
parent bf275fe564
commit 72ac806cb8
4 changed files with 95 additions and 10 deletions

View File

@@ -1,5 +1,4 @@
from PySide2.QtGui import QFont
from PySide2.QtWidgets import QGraphicsScene
from PySide2.QtWidgets import QGraphicsScene, QGraphicsSceneMouseEvent
import qt_ui.uiconstants as CONST
@@ -11,3 +10,9 @@ class QLiberationScene(QGraphicsScene):
item = self.addText("Go to \"File/New Game\" to setup a new campaign or go to \"File/Open\" to load an existing save game.",
CONST.FONT_PRIMARY)
item.setDefaultTextColor(CONST.COLORS["white"])
def mouseMoveEvent(self, event: QGraphicsSceneMouseEvent):
self.parent().sceneMouseMovedEvent(event)
def mousePressEvent(self, event:QGraphicsSceneMouseEvent):
self.parent().sceneMousePressEvent(event)