Merge branch 'main' of https://git.personal.imadumbass.dog/Brosef/RussianRoulette
This commit is contained in:
@ -48,6 +48,13 @@ class Game:
|
|||||||
self.spinning = False
|
self.spinning = False
|
||||||
self.spinInc = 0
|
self.spinInc = 0
|
||||||
|
|
||||||
|
#render variables
|
||||||
|
self.screenMid = self.size[0]/2
|
||||||
|
self.gunScale = self.size[1]/1080
|
||||||
|
self.gunMid = self.screenMid-(self.gun[0][0].size[0]*self.gunScale/2)
|
||||||
|
# TODO
|
||||||
|
# Make the gun scale based on width of screen as well as height
|
||||||
|
|
||||||
def fire(self):#LETS GO GAMBLING
|
def fire(self):#LETS GO GAMBLING
|
||||||
if randint(1,6) == 6:
|
if randint(1,6) == 6:
|
||||||
self.playSound(self.gunShot)
|
self.playSound(self.gunShot)
|
||||||
@ -95,7 +102,7 @@ class Game:
|
|||||||
|
|
||||||
#screen code
|
#screen code
|
||||||
self.surface.fill("black")
|
self.surface.fill("black")
|
||||||
self.surface.blit(self.gun[self.spinInc][0],(0,0))#draw the gun
|
self.surface.blit(pygame.transform.scale_by(self.gun[self.spinInc][0],self.gunScale),(self.gunMid,0))#draw the gun
|
||||||
#screen.blit(pygame.transform.scale_by(MainSurface,1),(0,yOffset))#renders the main surface to the screen, while also scaling it for the required display resolution
|
#screen.blit(pygame.transform.scale_by(MainSurface,1),(0,yOffset))#renders the main surface to the screen, while also scaling it for the required display resolution
|
||||||
|
|
||||||
# TODO:
|
# TODO:
|
||||||
|
|||||||
Reference in New Issue
Block a user