]> git.pld-linux.org Git - packages/Slune.git/blob - Slune-soya.patch
- tabs in preamble
[packages/Slune.git] / Slune-soya.patch
1 --- Slune-1.0.12rc1.orig/slune  2006-09-24 13:25:25.000000000 +0200
2 +++ Slune-1.0.12rc1/slune       2006-09-24 15:11:04.000000000 +0200
3 @@ -36,10 +36,8 @@
4    sys.path.insert(0, APPDIR)
5  
6  import slune.globdef as globdef, soya
7 -soya.init(width = globdef.SCREEN_WIDTH, height = globdef.SCREEN_HEIGHT, fullscreen = globdef.FULLSCREEN, sound = 1, sound_doppler_factor = 0.005, sound_reference_distance = 3.0)
8 -#soya.init(width = globdef.SCREEN_WIDTH, height = globdef.SCREEN_HEIGHT, fullscreen = globdef.FULLSCREEN)
9 +soya.init(width = globdef.SCREEN_WIDTH, height = globdef.SCREEN_HEIGHT, fullscreen = globdef.FULLSCREEN)
10  soya.set_quality(globdef.QUALITY)
11 -soya.set_sound_volume(globdef.SOUND_VOLUME)
12  
13  LEVEL        = ""
14  PARRAIN_HOST = None
15 --- Slune-1.0.12rc1.orig/level.py       2006-09-24 13:25:26.000000000 +0200
16 +++ Slune-1.0.12rc1/level.py    2006-09-24 15:11:04.000000000 +0200
17 @@ -264,9 +264,7 @@
18      for child in self.children: child.advance_time(proportion)
19      soya.root_widget.widget_advance_time(proportion)
20      
21 -  def render(self):
22 -    for i in soya.BEFORE_RENDER: i()
23 -    soya.render()
24 +  def render(self): soya.render()
25      
26    def end_round(self):
27      current = time.time()
28 --- Slune-1.0.12rc1.orig/sound.py       2006-09-24 13:25:25.000000000 +0200
29 +++ Slune-1.0.12rc1/sound.py    2006-09-24 15:11:04.000000000 +0200
30 @@ -26,9 +26,9 @@
31  def clean_mem    (*args): pass
32  
33  if globdef.MUSIC or globdef.SOUND:
34 -  def play_music   (filename):
35  
36 -    soya.SoundPlayer(soya.IDLER, soya.Sound.get(filename), play_in_3D = 0, loop = 1)
37 +  def play_music   (filename):
38 +       def play(filename, position = None, speed = None, looping = 0, gain = 0): pass
39  
40  
41    def end_music    ():
42 @@ -38,7 +38,7 @@
43    def play         (filename, position = None, speed = None, looping = 0, gain = 1.0):
44      while position and (not isinstance(position, soya.World)): position = position.parent
45      if position:
46 -      soya.SoundPlayer(position, soya.Sound.get(filename), loop = looping, gain = gain)
47 +       def play(filename, position = None, speed = None, looping = 0, gain = 0): pass
48      elif soya.IDLER:
49 -      soya.SoundPlayer(soya.IDLER, soya.Sound.get(filename), play_in_3D = 0, loop = looping, gain = gain)
50 -      
51 +       def play(filename, position = None, speed = None, looping = 0, gain = 0): pass
52 +
53 --- Slune-1.0.12rc1.orig/gui_gl.py      2006-09-24 13:25:25.000000000 +0200
54 +++ Slune-1.0.12rc1/gui_gl.py   2006-09-24 15:12:52.000000000 +0200
55 @@ -264,11 +264,10 @@
56      menu_h_option.choices[1].value = menu_h_option.choices[1].range[globdef.FULLSCREEN]
57      menu_h_option.choices[2].value = menu_h_option.choices[2].range[globdef.QUALITY]
58      menu_h_option.choices[3].value = globdef.MAX_VISION
59 -    #menu_h_option.choices[4].value = menu_h_option.choices[4].range[globdef.SOUND]
60 -    #menu_h_option.choices[5].value = menu_h_option.choices[5].range[globdef.MUSIC]
61 +    menu_h_option.choices[4].value = menu_h_option.choices[4].range[globdef.SOUND]
62 +    menu_h_option.choices[5].value = menu_h_option.choices[5].range[globdef.MUSIC]
63      #menu_h_option.choices[6].value = menu_h_option.choices[6].range[globdef.ASYNC_LOAD_MUSIC]
64      #menu_h_option.choices[7].value = globdef.SOUND_SYSTEM
65 -    menu_h_option.choices[4].value = str(int(round(globdef.SOUND_VOLUME * 100)))
66      set_current_menu(menu_h_option)
67  
68    def back_h_option():
69 @@ -278,15 +277,13 @@
70      globdef.FULLSCREEN       = (menu_h_option.choices[1].value == _('on'))
71      globdef.QUALITY          = menu_h_option.choices[2].range.index(menu_h_option.choices[2].value)
72      globdef.MAX_VISION       = float(menu_h_option.choices[3].value)
73 -    #globdef.SOUND            = (menu_h_option.choices[4].value == _('on'))
74 -    #globdef.MUSIC            = (menu_h_option.choices[5].value == _('on'))
75 +    globdef.SOUND            = (menu_h_option.choices[4].value == _('on'))
76 +    globdef.MUSIC            = (menu_h_option.choices[5].value == _('on'))
77      #globdef.ASYNC_LOAD_MUSIC = (menu_h_option.choices[6].value == _('on'))
78      #globdef.SOUND_SYSTEM     = menu_h_option.choices[7].value
79 -    globdef.SOUND_VOLUME     = int(menu_h_option.choices[4].value) / 100.0
80      soya.set_quality(globdef.QUALITY)
81      soya.set_video(globdef.SCREEN_WIDTH, globdef.SCREEN_HEIGHT, globdef.FULLSCREEN, 1)
82 -    soya.set_sound_volume(globdef.SOUND_VOLUME)
83 -    #import slune.sound; reload(slune.sound)
84 +    import slune.sound; reload(slune.sound)
85      go_back()
86  
87    def show_p_option():
88 @@ -369,9 +366,8 @@
89      soya.widget.Choice(_('Fullscreen'), None, None, checkbox),
90      soya.widget.Choice(_('Graphic quality'), None, None, [_('Low'), _('Medium'), _('High')]),
91      soya.widget.Choice(_('Max vision distance'), None, None, [0.5, 2.0], 0.1),
92 -    soya.widget.Choice(_('Sound volume'), None, None, ['0', '10', '20', '30', '40', '50', '60', '70', '80', '90', '100']),
93 -    #soya.widget.Choice(_('Sounds'), None, None, checkbox),
94 -    #soya.widget.Choice(_('Music'), None, None, checkbox),
95 +    soya.widget.Choice(_('Sounds'), None, None, checkbox),
96 +    soya.widget.Choice(_('Music'), None, None, checkbox),
97      #soya.widget.Choice(_('Async load music'), None, None, checkbox),
98      #soya.widget.Choice(_('Sound system'), None, None, ["OpenAL", "OpenAL (old)", "SDL_mixer"]),
99      soya.widget.Choice(_('Back'), back_h_option)
This page took 0.033683 seconds and 3 git commands to generate.