6 import pygame.locals as pgl
8 from naja.constants import KEYS
9 from naja.scenes.scene import Scene
10 from naja.widgets.text import TextWidget, TextBoxWidget
11 from naja.widgets.image_box import ImageBox
12 from naja.events import SceneChangeEvent
15 class CreditsScene(Scene):
17 List those responsible.
20 def __init__(self, state):
21 super(CreditsScene, self).__init__(state)
23 background = ImageBox(
24 (0, 0), "screens/splash.png")
27 (400, 300), 'CREDITS', colour='white', centre=True))
29 self.add(TextBoxWidget(
30 (400, 340), '\n'.join([
31 'A game about robots and bits and other things',
35 u'Adrianna PiĆska, David Sharpe, Jeremy Thurgood, '
36 u'Neil Muller, Simon Cross & Stefano Rivera',
41 'for snacks and tutorial inspiration',
43 'Bearnard Hibbins, Graham Inggs,',
44 'and William Stewart',
45 'for playtesting and finding bugs',
47 'Music by Rolemusic:',
48 'http://rolemusic.sawsquarenoise.com/',
50 'Out of credits. Insert coin.',
51 '(Press ESC to return to the menu.)',
53 colour='white', padding=1,
54 bg_colour=(0, 0, 0, 0), centre=True,
55 box_width=780, view_port=(780, 250)))
57 def handle_scene_event(self, ev):
58 if ev.type == pgl.KEYDOWN and ev.key in KEYS.QUIT:
59 from naja.scenes.menu import MenuScene
60 SceneChangeEvent.post(MenuScene)