Skip to content
Snippets Groups Projects
Commit 3b00fbec authored by tobias's avatar tobias
Browse files

dokk: modified to german, changed box size and timer color

git-svn-id: https://dng.biozentrum.unibas.ch/svn/openstructure/trunk@2005 5a81b35b-ba03-0410-adc8-b2c5c5119f08
parent 9fcd4b5f
No related branches found
No related tags found
No related merge requests found
[Level]
NAME: Tutorial 1
DIFFICULTY: Basic Training
DIFFICULTY: Einfhrungs Training
TIME: 60000
SAVE: 0
GOAL: 1.0
......
[Level]
NAME: Tutorial 2
DIFFICULTY: Advanced Training
DIFFICULTY: Fortgeschrittenes Training
TIME: 60000
SAVE: 0
GOAL: 1.0
......
......@@ -55,7 +55,12 @@ class DokkGLCanvas(QGLWidget):
painter.setPen(QPen(QColor(255,255,255), Qt.SolidLine))
painter.setFont(QFont("Verdana",20))
painter.drawText(QPoint(10, 25), "Sie sind %.1f von der Lsung entfernt" % self.dokk.GetLevel().GetRMSD())
painter.drawText(QPoint(self.width()-230, 25), "noch %.0f sekuden" % self.dokk.GetLevel().GetRemainingTime())
if self.dokk.GetLevel().IsStarted():
time_col=self.dokk.GetLevel().GetRemainingTime()/10
if time_col>1:
time_col=1
painter.setPen(QPen(QColor(255,255*time_col,255*time_col), Qt.SolidLine))
painter.drawText(QPoint(self.width()-250, 25), "noch %.0f Sekunden" % self.dokk.GetLevel().GetRemainingTime())
if self.hud is not None:
self.hud.Paint(painter)
self.dokk.GetLevel().CheckSolved()
......
......@@ -81,7 +81,7 @@ class LevelDetails(QtCore.QObject):
self.hud_bg = None
def Start(self):
name_len = len(self.name)
name_len = max(len(self.name),len(self.difficulty)/2)
xpos = dokk.Dokk().gl_win.Width()/2 - (name_len*30)/2
rect = QtCore.QRect(QtCore.QPoint(xpos, 55), QtCore.QSize(name_len*30, 105))
self.hud_bg = RectHUDObject(-1,rect, bg_color=QtGui.QColor(128,128,128,200))
......@@ -113,4 +113,4 @@ class DemoCam(QtCore.QTimer):
def OnTimer(self):
gfx.Scene().Apply(gfx.InputEvent(gfx.INPUT_DEVICE_MOUSE, gfx.INPUT_COMMAND_ROTY, 0.25), False)
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment