Skip to content

Commit

Permalink
Updated visuals for walls and arrows
Browse files Browse the repository at this point in the history
  • Loading branch information
akirbaes committed Aug 25, 2019
1 parent 7e0fc8b commit 0ef8cc1
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 11 deletions.
21 changes: 13 additions & 8 deletions game_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,16 +144,21 @@ def draw(self,screen):
#screen.blit(cbnasurf, (0,0))
for i in range(7):
for j in range(11):
color=tuple(a*(j+3)/14 for a in colors[i])
pygame.draw.rect(screen, color, (gx+ts*j, gy+ts*i, ts, ts))

if(data[i][j]=="B"):
color=(0,0,0)
pygame.draw.rect(screen, color, (gx+ts*j, gy+ts*i, ts, ts))
else:
color=tuple(a*(j+3)/14 for a in colors[i])
pygame.draw.rect(screen, color, (gx+ts*j, gy+ts*i, ts, ts))
if(i==6):
screen.blit(gradtile, (gx+j*ts, gy+i*ts))
if(data[i][j]=="D"):
#color=(0,0,0)
#pygame.draw.rect(screen, color, (gx+ts*j, gy+ts*i, ts, ts))
screen.blit(wall, (gx+j*ts, gy+i*ts))
if(i==6):
screen.blit(gradtile, (gx+j*ts, gy+i*ts))
if(self.data[i][j]=="D"):
screen.blit(natural_boostdown, (gx+j*ts, gy+i*ts))
elif(data[i][j]=="D"):
screen.blit(boostdown, (gx+j*ts, gy+i*ts))
elif(self.data[i][j]=="U"):
screen.blit(natural_boostup, (gx+j*ts, gy+i*ts))
elif(data[i][j]=="U"):
screen.blit(boostup, (gx+j*ts, gy+i*ts))
elif(data[i][j]=="V"):
Expand Down
Binary file added graphics/wall.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion levels/level0.rawdata
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
1
0
abcdefghijk
123456789GH
0123456789G
Expand Down
7 changes: 7 additions & 0 deletions sprites_load.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
boostup = pygame.image.load(os.path.join('graphics', 'boostup.png'))
#boostup.convert_alpha(screen)
boostdown=pygame.transform.flip(boostup,False,True)
natural_boostup = pygame.image.load(os.path.join('graphics', 'natural_boostup.png'))
#boostup.convert_alpha(screen)
natural_boostdown=pygame.transform.flip(natural_boostup,False,True)
boostingsurf= pygame.image.load(os.path.join('graphics', 'boosting.png'))
#boostingsurf.convert_alpha(screen)
heartsurf= pygame.image.load(os.path.join("graphics", "heart.png"))
Expand All @@ -38,6 +41,8 @@
boost_socket=pygame.image.load(os.path.join("graphics", "boost_socket.png"))
boost_icon=pygame.image.load(os.path.join("graphics", "boost_icon.png"))

wall=pygame.image.load(os.path.join("graphics", "wall.png"))

marker=pygame.image.load(os.path.join("graphics","marker.png"))
#marker.convert_alpha(screen)
#from spt import FONTSIZE,myfont,font2
Expand All @@ -49,6 +54,8 @@
for j in range(ts):
for i in range(ts):
gradtile.set_at((i,j),(0,0,0,(j/ts)**1.5*260*(j%2)*(i%2)))
if not(j%2 or i%2):
gradtile.set_at((i,j),(255,255,255,(j/ts)**4*200))
#pygame.draw.line(gradtile, (0,0,0,128-i*128/ts), (0,i),(ts,i))

def reload_character():
Expand Down
4 changes: 2 additions & 2 deletions spt.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ def menu_loop(screen,clock):
#print("Is this it?")
loader.r()
step=0
title="7 floors + 3 things"
title="Ups and downs"
title=myfont.render(title,False,(255,255,255))
mark=pygame.image.load(os.path.join("graphics","marker.png"))
mark=pygame.transform.flip(mark,True,False)
names="Tutorial","Play","Quit","Characters"
names="Tutorial","Rush mode","Quit","Characters"
secret=myfont.render("Puzzle",False,(255,255,255))
messages=[myfont.render(txt,False,(255,255,255)) for txt in names]
while not quit and not game:
Expand Down

0 comments on commit 0ef8cc1

Please sign in to comment.