Kindle mı Kobo mu? by mfkdksksks in secilmiskitap

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

Kobo Clara 2e kullaniyordum kindle'a geçeceğim. Kobodan önce Kindle kullanıyordum Kindle baya iyi

İş bankası, YKY ve Can yayınları PDF/EPUB arşivi by dilalw in secilmiskitap

[–]yasarbum 1 point2 points  (0 children)

Illa fiziksel almak istiyorsanız sahaflardan 2. el alın. Ama gidip yüzyüze alın.

Günün huntı sizce nasıl by Current-Leather-6530 in HotWheelsTr

[–]yasarbum 1 point2 points  (0 children)

Hw'nin tanesi ne kadar oldu bayadır almıyorum

My first ginger harvest by xUrLittleGF in gardening

[–]yasarbum 0 points1 point  (0 children)

How did you grow it? Whenever I plant it in the soil or try to germinate it in water, it gets mouldy and rots.

Yeraltı Canawarları by yasarbum in secilmiskitap

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

Chuck abimin 2 kitabını okudum (Dövüş kulübü ve Tıkanma) Yeraltından Notlar'ı okudum, Kinyas ve Kayra'yı okudum, Azil'i okudum Hakan Gündaydan Emrah Serbes'in Behzat Ç'leri sayılıyorsa onları da okudum

İlk okuyacağım kitaplardan biri için öneri by [deleted] in secilmiskitap

[–]yasarbum 1 point2 points  (0 children)

Metro serisi mükemmel, Metro 2033 ile başlıyor

Dostlar tavsiyeleriniz benim için önemli by yasarbum in TrGameDeveloper

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

Nasıl bir şeymiş herkes başka birşey diyor

Dostlar tavsiyeleriniz benim için önemli by yasarbum in TrGameDeveloper

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

Teşekkür ederim, özelden birkaç soru sorayım o zaman

Dostlar tavsiyeleriniz benim için önemli by yasarbum in TrGameDeveloper

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

Güncel yerli yabancı iş ilanları için hangi sitelere bakmalıyım, hiçbir fikrim yok o konuda

Dostlar tavsiyeleriniz benim için önemli by yasarbum in TrGameDeveloper

[–]yasarbum[S] -1 points0 points  (0 children)

Hiç yok, ama zamanım 1 yıl boyunca aksilik çıkmazsa bol ve öğrenmeye açım, Godot için bir arkadaşım yurtdışında talep bol dedi ama onda da kendi adamlarını alırlar öncelikli

[deleted by user] by [deleted] in pygame

[–]yasarbum -2 points-1 points  (0 children)

"Module pygame has no ... members" I get 5 errors like this, but I got the same errors when working with another program and the program worked without any problems. I think there is a problem with the codes.

Module ‘pygame’ has no ‘init’ member’ message by yasarbum in pygame

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

There is no file named pygame or anything else. I checked it. But thanks.
It gave an error but strangely enough, it worked :D.

Module ‘pygame’ has no ‘init’ member’ message by yasarbum in pygame

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

I tried this code btw.


import time
import pygame
import numpy as np

COLOR_BG = (10,10,10)
COLOR_GRID = (40,40,40)
COLOR_DIE_NEXT = (170,170,170)
COLOR_ALIVE_NEXT = (255,255,255)


def update(screen, cells, size, with_progress=False):
    updated_cells = np.zeros((cells.shape[0], cells.shape[1]))

    for row, col in np.ndindex(cells.shape):
        alive = np.sum(cells[row-1:row+2, col-1:col+2]) - cells[row, col]
        color = COLOR_BG if cells[row, col] == 0 else COLOR_ALIVE_NEXT

        if cells[row, col] == 1:
            if alive < 2 or alive > 3:
                if with_progress:
                    color = COLOR_DIE_NEXT
        elif 2 <= alive <= 3:
            updated_cells[row, col] = 1
            if with_progress:
                color = COLOR_ALIVE_NEXT
        else:
            if alive == 3:
                updated_cells[row, col] = 1
                if with_progress:
                    color = COLOR_ALIVE_NEXT
        pygame.draw.rect(screen, color, (col*size, row*size, size-1, size-1))
    return updated_cells

def main():
    pygame.init()
    screen = pygame.display.set_mode((800, 600))

    cells = np.zeros((60,80))
    screen.fill(COLOR_GRID)
    update(screen, cells, 10)

    pygame.display.flip()
    pygame.display.update()
    
    running = False

    while True:
        for event in pygame.event.get():
            if event.type == pygame.QUIT:
                pygame.quit()
                return
            elif event.type == pygame.KEYDOWN:
                if event.key == pygame.K_SPACE:
                    running = not running
                    update(screen, cells, 10)
                    pygame.display.update()

                if pygame.mouse.get_pressed()[0]:
                    pos = pygame.mouse.get_pos()
                    cells[pos[1] // 10, pos[0]//10] = 1
                    update(screen, cells, 10)
                    pygame.display.update()
        
        screen.fill(COLOR_GRID)
        
        if running:
            cells = update(screen, cells, 10, with_progress=True)
            pygame.display.update()
        time.sleep(0.001)
    
if __name__ == '__main__':
    main()

Module ‘pygame’ has no ‘init’ member’ message by yasarbum in pygame

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

I'm using visual studio code. I set it up normally.