Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def createArrwos(self, MapGrid, number):
- if(number == 0):
- #creates attack arrow pointing top left
- X = self.px+2
- Y = self.py+2
- pygame.draw.polygon(MapGrid, red, [[X, Y], [X+5, Y], [X, Y+5]], 0)
- if(number == 1):
- X = self.px + cardWidth / 2
- Y = self.py + 2
- #creates attack arrow pointing up
- pygame.draw.polygon(MapGrid, white, [[X, Y], [X+r2, Y+r2], [X-r2, Y+r2]], 0)
- if(number == 2):
- #X -2 is creates the location on the card, in this case the top right corner
- X = self.px + cardWidth - 2
- Y = self.py + 2
- pygame.draw.polygon(MapGrid, green, [[X, Y], [X-5, Y], [X, Y+5]], 0)
- if(number == 3):
- X = self.px+cardWidth-2
- Y = self.py+cardHeight/2
- pygame.draw.polygon(MapGrid, yellow, [[X, Y], [X-r2, Y+r2], [X-r2, Y-r2]], 0)
- if(number == 4):
- X = self.px+cardWidth-2
- Y = self.py+cardHeight-2
- pygame.draw.polygon(MapGrid, clearblue, [[X, Y], [X-5, Y], [X, Y-5]], 0)
- if(number == 5):
- X = self.px+cardWidth/2
- Y = self.py+cardHeight-2
- pygame.draw.polygon(MapGrid, white, [[X, Y], [X+r2, Y-r2], [X-r2, Y-r2]], 0)
- if(number == 6):
- X = self.px+2
- Y = self.py+cardHeight-2
- pygame.draw.polygon(MapGrid, brown, [[X, Y], [X+5, Y], [X, Y-5]], 0)
- if(number == 7):
- X = self.px+2
- Y = self.py+cardHeight/2
- pygame.draw.polygon(MapGrid, black, [[X, Y], [X+r2, Y+r2], [X+r2, Y-r2]], 0)
- def createArrwos(self, MapGrid, number):
- if(number == 0):
- #creates attack arrow pointing top left
- X = self.px+2
- Y = self.py+2
- pygame.draw.polygon(MapGrid, red, [[X, Y], [X+5, Y], [X, Y+5]], 0)
- #creates top arrow
- X = self.px + cardWidth / 2
- Y = self.py + 2
- #creates attack arrow pointing up
- pygame.draw.polygon(MapGrid, red, [[X, Y], [X+r2, Y+r2], [X-r2, Y+r2]], 0)
Add Comment
Please, Sign In to add comment