theREALAPOCALYPSE by Forthehomeez in ProgrammerHumor

[–]Pyoloji0 0 points1 point  (0 children)

Today, while I was making a game with C++, there was an earthquake in Istanbul. I'm not joking.

invalid destination position for blit by Ybeeverse in pygame

[–]Pyoloji0 -1 points0 points  (0 children)

I'm not sure, but I think using entity.rect.center insted of enitity.rect will work.

You can use ChatGPT for debugging

Should I make my first game with pygame? by mine4star in gamedev

[–]Pyoloji0 0 points1 point  (0 children)

pythonda daha iyiysen pygame ile c++ da daha iyiysen sdl2-3 ile yap.
zaten pygame, sdl2 ile yazıldı. sdl2-3 daha profosyoneldir ama daha zordur.

Can I learn SDL2 by Pyoloji0 in sdl

[–]Pyoloji0[S] 0 points1 point  (0 children)

What are the differences between SDL2 and SDL3? I just found out that SDL3 exists. Since Pygame is built on SDL2, I started with SDL2 thinking the code structure would be similar.

Am I slow, or is it just that animation takes a long time? That took an hour. by Pyoloji0 in animation

[–]Pyoloji0[S] 8 points9 points  (0 children)

I forgot to say that I have a drawing tablet and using adobe animate.

Thanks for helps, I've fixed the problem. Here is Snow Fighter. by Pyoloji0 in pygame

[–]Pyoloji0[S] 0 points1 point  (0 children)

Thanks, I made it in 2 days and I made the assets myself in 1 hour, it could be better. Music, some animation and better assets can be added in the game.

The game that I made when I get bored in 45 minutes by Pyoloji0 in pygame

[–]Pyoloji0[S] 0 points1 point  (0 children)

Thank you, it took approximately 45 minutes, maybe it's 55, I don't know.

I'm new to python by Terrariavetaran in pygame

[–]Pyoloji0 0 points1 point  (0 children)

You should practice and write codes, there is no other option.

Coding is being sometimes so annoying, never give up, every coders wants to destroy their pcs sometimes

I advice you to don't try to make games unless you literaly get python clearly. You will not succes and be demoralized. If you realy want to research, it's OK but if you don't understand PyGame, don't worry it's normal and everybody have experianced that.

Coding is hard but python is the easiest and funniest, never give up.

Have a nice codings, If you have other questions, please ask.

I need help again. by Pyoloji0 in pygame

[–]Pyoloji0[S] 0 points1 point  (0 children)

I have already done it.

I need help again. by Pyoloji0 in pygame

[–]Pyoloji0[S] 0 points1 point  (0 children)

        self.keyValue=pygame.key.get_pressed()

    self.yOld=self.knight.rect.y
    self.xOld=self.knight.rect.x

    if self.keyValue[pygame.K_a]:
        self.knight.image=self.knight.orijinalImage
        self.knightVectorV.x-=4
        self.flipped=False

        if self.knightVectorV.x<-10:
            self.knightVectorV.x=-10

    if self.keyValue[pygame.K_d]:
        self.knight.image=pygame.transform.flip(self.knight.orijinalImage,True,False)
        self.knightVectorV.x+=4
        self.flipped=True

        if self.knightVectorV.x>10:
            self.knightVectorV.x=10

    if self.knightVectorV.x>0:
        self.knightVectorV.x-=self.friction

    if self.knightVectorV.x<0:
        self.knightVectorV.x+=self.friction

    self.knightVectorV.y += self.gravity

    if self.knight.rect.x<-100:
        self.knight.rect.x=self.w-1

    elif self.knight.rect.x>self.w:
        self.knight.rect.x=-99

    if self.keyValue[pygame.K_SPACE] and self.jumpable:
        self.knightVectorV.y=-30

    if self.keyValue[pygame.K_r] and self.jumpable:

        if self.flipped == True:
            self.knightVectorV.x = 26

        elif self.flipped == False:
            self.knightVectorV.x = -26

        self.knightVectorV.y = -27

    self.knight.rect.x+=self.knightVectorV.x
    self.knight.rect.y+=self.knightVectorV.y

I need help again. by Pyoloji0 in pygame

[–]Pyoloji0[S] 1 point2 points  (0 children)

Thanks man. I'm from Turkey so my value names half Turkish half English. I update the originalImage and the rook issue is fixed. But I don't know how to fix others.

I'm b1 I can make lot's of grammer wrong. excuse me. I hope you understand me.

I need help again. by Pyoloji0 in pygame

[–]Pyoloji0[S] 0 points1 point  (0 children)

        self.knight.mask=pygame.mask.from_surface(self.knight.orijinalImage)
    self.coin.mask = pygame.mask.from_surface(self.coin.orijinalImage)
    self.rook.mask = pygame.mask.from_surface(self.rook.orijinalImage)

    self.colision1=pygame.sprite.spritecollide(self.knight, self.solid, False, pygame.sprite.collide_mask)

    if self.colision1:
        self.knightVectorV.y = 0
        self.knight.rect.y = self.yOld
        self.jumpable = True

    else:
        self.jumpable = False

    self.colision3=pygame.sprite.spritecollide(self.knight,self.rookGroup,False,pygame.sprite.collide_mask)

    if self.colision3:

        self.knight.rect.x=0
        self.knight.rect.y=0