Skip to content

Commit

Permalink
Remove useless and redundant backslashes
Browse files Browse the repository at this point in the history
  • Loading branch information
Linkid committed Jul 11, 2015
1 parent 9c6fafc commit d2204b0
Show file tree
Hide file tree
Showing 7 changed files with 39 additions and 39 deletions.
4 changes: 2 additions & 2 deletions fofix/core/Data.py
Expand Up @@ -197,8 +197,8 @@ def __init__(self, resource, svg):
resource.load(self,f[1],f[0], synch = True)


self.fontDict = {"font": self.font, "bigFont": self.bigFont, "pauseFont": self.pauseFont, "scoreFont": self.scoreFont, \
"streakFont": self.streakFont, "songFont": self.songFont, "streakFont2": self.streakFont2, \
self.fontDict = {"font": self.font, "bigFont": self.bigFont, "pauseFont": self.pauseFont, "scoreFont": self.scoreFont,
"streakFont": self.streakFont, "songFont": self.songFont, "streakFont2": self.streakFont2,
"songListFont": self.songListFont, "shadowFont": self.shadowFont, "loadingFont": self.loadingFont}

assert self.fontDict['font'] == self.font
Expand Down
4 changes: 2 additions & 2 deletions fofix/core/GameEngine.py
Expand Up @@ -82,8 +82,8 @@
i = len(themes)
if i == 0:
if os.name == 'posix':
Log.error("No valid theme found!\n"+\
"Make sure theme files are properly cased "+\
Log.error("No valid theme found!\n" +
"Make sure theme files are properly cased " +
"e.g. notes.png works, Notes.png doesn't\n")
else:
Log.error("No valid theme found!")
Expand Down
4 changes: 2 additions & 2 deletions fofix/core/Image.py
Expand Up @@ -59,8 +59,8 @@ def clear(self, r = 0, g = 0, b = 0, a = 0):
glClearColor(r, g, b, a)
glClear(GL_COLOR_BUFFER_BIT | GL_STENCIL_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)

def drawImage(image, scale = (1.0, -1.0), coord = (0, 0), rot = 0, \
color = (1,1,1,1), rect = (0,1,0,1), stretched = 0, fit = CENTER, \
def drawImage(image, scale = (1.0, -1.0), coord = (0, 0), rot = 0,
color = (1,1,1,1), rect = (0,1,0,1), stretched = 0, fit = CENTER,
alignment = CENTER, valignment = CENTER):
"""
Draws the image/surface to screen
Expand Down
14 changes: 7 additions & 7 deletions fofix/core/Player.py
Expand Up @@ -131,11 +131,11 @@ def sortOptionsByKey(dict):
drum5s = []
bassdrums = []

guitarkeynames = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Fret 1", "Solo Fret 1", "Fret 2", "Solo Fret 2", "Fret 3", \
guitarkeynames = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Fret 1", "Solo Fret 1", "Fret 2", "Solo Fret 2", "Fret 3",
"Solo Fret 3", "Fret 4", "Solo Fret 4", "Fret 5", "Solo Fret 5", "Action 1", "Action 2", "Star Key", "Effects Key"]
drumkey4names = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Drum 4", "Drum 4 B", "Drum 1", "Drum 1 B", "Drum 2", "Drum 2 B", \
drumkey4names = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Drum 4", "Drum 4 B", "Drum 1", "Drum 1 B", "Drum 2", "Drum 2 B",
"Drum 3", "Drum 3 B", "None", "None", "Bass Drum", "Bass Drum B", "Star Key", "None"]
drumkey5names = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Drum 5", "Drum 5 B", "Drum 1", "Drum 1 B", "Cymbal 2", "Cymbal 2 B", \
drumkey5names = ["Left", "Right", "Up", "Down", "Cancel", "Select", "Drum 5", "Drum 5 B", "Drum 1", "Drum 1 B", "Cymbal 2", "Cymbal 2 B",
"Drum 3", "Drum 3 B", "Cymbal 4", "Cymbal 4 B", "Bass Drum", "Bass Drum B", "Star Key", "None"]

menuUp = []
Expand Down Expand Up @@ -902,22 +902,22 @@ def reset(self):
def configController(self):
if self.keyList:
if self.controlType == 1:
self.keys = [self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5], \
self.keys = [self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5],
self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5]]
self.soloKeys = [self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5]]
else:
self.keys = [self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5], \
self.keys = [self.keyList[KEY1], self.keyList[KEY2], self.keyList[KEY3], self.keyList[KEY4], self.keyList[KEY5],
self.keyList[KEY1A], self.keyList[KEY2A], self.keyList[KEY3A], self.keyList[KEY4A], self.keyList[KEY5A]]
self.soloKeys = [self.keyList[KEY1A], self.keyList[KEY2A], self.keyList[KEY3A], self.keyList[KEY4A], self.keyList[KEY5A]]
self.soloShift = self.keyList[KEY1A]
self.drumSolo = []
self.actions = [self.keyList[ACTION1], self.keyList[ACTION2]]
self.drums = [self.keyList[DRUMBASS], self.keyList[DRUM1], self.keyList[DRUM2], self.keyList[DRUM3], self.keyList[DRUM5], \
self.drums = [self.keyList[DRUMBASS], self.keyList[DRUM1], self.keyList[DRUM2], self.keyList[DRUM3], self.keyList[DRUM5],
self.keyList[DRUMBASSA], self.keyList[DRUM1A], self.keyList[DRUM2A], self.keyList[DRUM3A], self.keyList[DRUM5A]]
if self.controlType == 1:
self.progressKeys = [self.keyList[KEY1], self.keyList[CANCEL], self.keyList[START], self.keyList[KEY2]]
else:
self.progressKeys = [self.keyList[KEY1], self.keyList[KEY1A], self.keyList[CANCEL], self.keyList[START], self.keyList[KEY2], \
self.progressKeys = [self.keyList[KEY1], self.keyList[KEY1A], self.keyList[CANCEL], self.keyList[START], self.keyList[KEY2],
self.keyList[KEY2A]]
if self.controlType == 4:
self.soloSlide = True
Expand Down
2 changes: 1 addition & 1 deletion fofix/game/Credits.py
Expand Up @@ -169,7 +169,7 @@ def __init__(self, engine, songName = None):
self.videoLayer = False
self.background = None

vidSource = os.path.join(Version.dataPath(), 'themes', self.themename, \
vidSource = os.path.join(Version.dataPath(), 'themes', self.themename,
'menu', 'credits.ogv')
if os.path.isfile(vidSource):
try:
Expand Down
30 changes: 15 additions & 15 deletions fofix/game/Dialogs.py
Expand Up @@ -1445,30 +1445,30 @@ def __init__(self, engine, control, prompt = ""):

if self.type < 2 or self.type == 4:
self.fretColors = self.engine.theme.noteColors
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"), \
_("Select"), _("Fret #1"), _("Solo #1"), _("Fret #2"), _("Solo #2"), \
_("Fret #3"), _("Solo #3"), _("Fret #4"), _("Solo #4"), _("Fret #5"), \
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"),
_("Select"), _("Fret #1"), _("Solo #1"), _("Fret #2"), _("Solo #2"),
_("Fret #3"), _("Solo #3"), _("Fret #4"), _("Solo #4"), _("Fret #5"),
_("Solo #5"), _("Pick!"), _("Pick!"), _("Starpower!"), _("Whammy")]
elif self.type == 2:
colors = self.engine.theme.noteColors
self.fretColors = [colors[1], colors[2], colors[3], colors[0]]
self.bassColor = colors[4]
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"), \
_("Select"), _("Drum #1"), None, _("Drum #2"), None, \
_("Drum #3"), None, None, None, _("Drum #4"), \
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"),
_("Select"), _("Drum #1"), None, _("Drum #2"), None,
_("Drum #3"), None, None, None, _("Drum #4"),
None, _("Bass Drum"), None, _("Starpower!"), _("None")]
elif self.type == 5:
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"), \
_("Select"), None, None, None, None, \
None, None, None, None, None, \
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"),
_("Select"), None, None, None, None,
None, None, None, None, None,
None, None, None, _("Starpower!"), None]
else:
colors = self.engine.theme.noteColors
self.fretColors = [colors[1], colors[2], colors[3], colors[4], colors[0]]
self.bassColor = self.engine.theme.colors[5]
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"), \
_("Select"), _("Drum #1"), None, _("Cymbal #2"), None, \
_("Drum #3"), None, _("Cymbal #4"), None, _("Drum #5"), \
self.names = [_("Left"), _("Right"), _("Up"), _("Down"), _("Start"),
_("Select"), _("Drum #1"), None, _("Cymbal #2"), None,
_("Drum #3"), None, _("Cymbal #4"), None, _("Drum #5"),
None, _("Bass Drum"), None, _("Starpower!"), _("None")]

self.tsFret = _("Fret")
Expand Down Expand Up @@ -1817,7 +1817,7 @@ def render(self, visibility, topMost):

elif self.type > 1:
if self.type == 2:
drumList = [self.keyList[Player.DRUM1], self.keyList[Player.DRUM1A], self.keyList[Player.DRUM2], self.keyList[Player.DRUM2A], \
drumList = [self.keyList[Player.DRUM1], self.keyList[Player.DRUM1A], self.keyList[Player.DRUM2], self.keyList[Player.DRUM2A],
self.keyList[Player.DRUM3], self.keyList[Player.DRUM3A], self.keyList[Player.DRUM5], self.keyList[Player.DRUM5A]]
for i in range(4):
if self.controls.getState(drumList[(2*i)]) or self.controls.getState(drumList[(2*i)+1]):
Expand All @@ -1829,8 +1829,8 @@ def render(self, visibility, topMost):
wText, hText = font.getStringSize(text)
font.render(text, ((.2 + .2 * i)-wText/2, .4 + v))
else:
drumList = [self.keyList[Player.DRUM1], self.keyList[Player.DRUM1A], self.keyList[Player.DRUM2], self.keyList[Player.DRUM2A], \
self.keyList[Player.DRUM3], self.keyList[Player.DRUM3A], self.keyList[Player.DRUM4], self.keyList[Player.DRUM4A], \
drumList = [self.keyList[Player.DRUM1], self.keyList[Player.DRUM1A], self.keyList[Player.DRUM2], self.keyList[Player.DRUM2A],
self.keyList[Player.DRUM3], self.keyList[Player.DRUM3A], self.keyList[Player.DRUM4], self.keyList[Player.DRUM4A],
self.keyList[Player.DRUM5], self.keyList[Player.DRUM5A]]
for i in range(5):
if self.controls.getState(drumList[(2*i)]) or self.controls.getState(drumList[(2*i)+1]):
Expand Down
20 changes: 10 additions & 10 deletions fofix/game/Lobby.py
Expand Up @@ -492,16 +492,16 @@ def __init__(self, engine):
self.lefty = {0: 1, 1: -1}
neckDict = {0: _("Default Neck"), 1: _("Theme Neck"), 2: _("Select a Neck")}
self.values = (self.dictEnDisable, self.dictEnDisable, self.dictEnDisable, {0: _("Disabled"), 1: _("Easy Assist"), 2: _("Medium Assist")}, self.dictEnDisable, neckDict)
self.options = [(_("Name"), _("Name your character!")), \
(_("Lefty Mode"), _("Flip the guitar frets for left-handed playing!")), \
(_("Drum Flip"), _("Flip the drum sounds - snare becomes crash, and so on")), \
(_("Auto-Kick Bass"), _("Feet uncooperative? Broke your pedal? Not to worry!")), \
(_("Assist Mode"), _("Play hard and expert, even when you're not that good!")), \
(_("Two-Chord Max"), _("For those still playing with uncooperative keyboards.")), \
(_("Neck"), _("Give the endless procession of notes a bit of flair!")), \
(_("Upload Name"), _("To the internet, you are GUITARGOD23047124!")), \
(_("Choose Avatar"), _("A 256x256 window into your soul.")), \
(_("Delete Character"), _("Quitter.")), \
self.options = [(_("Name"), _("Name your character!")),
(_("Lefty Mode"), _("Flip the guitar frets for left-handed playing!")),
(_("Drum Flip"), _("Flip the drum sounds - snare becomes crash, and so on")),
(_("Auto-Kick Bass"), _("Feet uncooperative? Broke your pedal? Not to worry!")),
(_("Assist Mode"), _("Play hard and expert, even when you're not that good!")),
(_("Two-Chord Max"), _("For those still playing with uncooperative keyboards.")),
(_("Neck"), _("Give the endless procession of notes a bit of flair!")),
(_("Upload Name"), _("To the internet, you are GUITARGOD23047124!")),
(_("Choose Avatar"), _("A 256x256 window into your soul.")),
(_("Delete Character"), _("Quitter.")),
(_("Done"), _("All finished? Let's do this thing!"))]
themename = self.engine.data.themeLabel
self.engine.data.loadAllImages(self, os.path.join("themes",themename,"lobby","creator"))
Expand Down

0 comments on commit d2204b0

Please sign in to comment.