Dvorak porting

Last pyweek, a few of us ported all the alphabet-key using games to be dvorak-friendly. Might as well do it again.

esehara: ROBOT1.0.0-final: http://pastebin.com/VQ6YSvbn

(log in to comment)

Comments

nordshippen: nordshippen: http://pastebin.com/FUFf4gNf
=== modified file 'nordshippen/player.py'
--- old/nordshippen/player.py	2011-04-11 22:18:37 +0000
+++ new/nordshippen/player.py	2011-04-11 22:22:35 +0000
@@ -56,8 +56,8 @@ class Player(Moveable):
         self.effectiveRadius = self.radius * self.scale
     
     # Update motion based on keyboard
-    dx = (0 if Game.instance.keys[key.A] else 1) - (0 if Game.instance.keys[key.D] else 1)
-    dy = (0 if Game.instance.keys[key.S] else 1) - (0 if Game.instance.keys[key.W] else 1)
+    dx = (0 if Game.instance.keys[key.A] else 1) - (0 if Game.instance.keys[key.E] else 1)
+    dy = (0 if Game.instance.keys[key.O] else 1) - (0 if Game.instance.keys[key.COMMA] else 1)
     self.vel = Vector2(dx,dy).normalize() * self.maxSpeed
 
     # cache the shot angle to avoid the heavy sqrt
PyN00b/CrossFire: http://pastebin.com/55z9VaTk
 
=== modified file 'CrossFire/main.py'

--- old/CrossFire/main.py 2011-04-12 15:36:34 +0000
+++ new/CrossFire/main.py 2011-04-12 15:37:53 +0000
@@ -280,7 +280,7 @@ def main():
                     if event.key == pygame.K_ESCAPE:
                         main_loop = False
                    
-                    if event.key == pygame.K_z or event.key == pygame.K_x or event.key == pygame.K_SPACE or event.key == pygame.K_RETURN:
+                    if event.key == pygame.K_SEMICOLON or event.key == pygame.K_q or event.key == pygame.K_SPACE or event.key == pygame.K_RETURN:
                         if title_menu_choice == 0:
                             # Start new game... reset values to defaults
                             start_sound.play()
@@ -345,7 +345,7 @@ def main():
                     if event.key == pygame.K_ESCAPE:
                         game_mode = TITLE_SCREEN_MODE
                     # Has bottom player fired?
-                    if event.key == pygame.K_z and player_fire_delay_left > player_fire_rate and game_over == False:
+                    if event.key == pygame.K_SEMICOLON and player_fire_delay_left > player_fire_rate and game_over == False:
                         # Pop off a few projectiles...                    
                         for count in range(PLAYER_BULLETS):
                             if (player_bullets[count].active == False): # Find a 'free' bullet for the bottom ship
@@ -358,7 +358,7 @@ def main():
                                 player_shoot_sound.play()                                
                                 break
                     # Has side player fired
-                    if event.key == pygame.K_x and player_fire_delay_right > player_fire_rate and game_over == False:
+                    if event.key == pygame.K_q and player_fire_delay_right > player_fire_rate and game_over == False:
                         for count in range(PLAYER_BULLETS):
                             if (player_bullets[count].active == False):
                                 player_bullets[count].active = True
tblob/Ninth_Bullet: http://pastebin.com/KwCMB5uS
 
=== modified file 'NinthBullet.py'
--- old/NinthBullet.py 2011-04-13 11:17:55 +0000
+++ new/NinthBullet.py 2011-04-13 11:52:20 +0000
@@ -335,7 +335,7 @@ class Player(pygame.sprite.Sprite):
  self.vector.x /= 1.5
  if int(self.vector.x) in list(xrange(-2, 2)):
  self.vector.x = 0
- if keys[pygame.K_z]:
+ if keys[pygame.K_SEMICOLON]:
  if self.jumping == True:
  self.vector.y -= self.yaccel
  else:
@@ -554,7 +554,7 @@ class BulletHandler():
  global screen, font, shoot
 
  self.group.update(level)
- if lastevent.type == pygame.KEYDOWN and lastevent.key == pygame.K_x:
+ if lastevent.type == pygame.KEYDOWN and lastevent.key == pygame.K_q:
  if self.player.facing == 'right' and self.ammo > 0:
  if self.player.crouch == False:
  self.createBullet([self.player.rect.right, self.player.rect.centery-9], [20, 0])
@@ -737,7 +737,7 @@ def mainloop(player, level):
  if e.key == pygame.K_ESCAPE:
  pygame.quit()
  exit()
- elif e.key == pygame.K_q or e.key == pygame.K_r:
+ elif e.key == pygame.K_QUOTE or e.key == pygame.K_o:
  screen.unlock()
  return None, None, None, None
  elif e.key == pygame.K_p: