Avance recul dans les fichiers.
[minwii.git] / src / minwii / runminwii.py
1 # -*- coding: utf-8 -*-
2 """
3 lancement de l'application winwii
4
5 $Id$
6 $URL$
7 """
8
9 from optparse import OptionParser
10 import pygame
11 from minwii.app import MinWii
12
13
14 def main(wiimoteSupport, fullscreen) :
15 pygame.init()
16 minwii = MinWii(wiimoteSupport=wiimoteSupport, fullscreen=fullscreen)
17 minwii.run()
18 pygame.quit()
19
20 if __name__ == "__main__" :
21 usage = "%prog [options]"
22 op = OptionParser(usage)
23
24 op.add_option("--no-wii", dest="wiimoteSupport"
25 , action="store_false"
26 , default=True
27 , help = u"désactivation du support des wiimotes"
28 u" [%default]")
29
30 op.add_option("--no-fullscreen", dest="fullscreen"
31 , action="store_false"
32 , default=True
33 , help = u"désactivation du mode plein écran"
34 u" [%default]")
35 options, args = op.parse_args()
36 main(options.wiimoteSupport, options.fullscreen)