four-column.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:MVP2 作者: critterandguitari 项目源码 文件源码
def draw(screen, mvp):
    global count, rany, ranx

    if True: #mvp.note_on :

        count += 1  
        if count > mvp.knob3 // 20:
            count = 0
            #screen.fill((0,0,0))
            rany = random.randrange(0,screen.get_height())#random.randomrange(0, screen.get_height())
            ranx = random.randrange(0,screen.get_width())#random.randomrange(0, screen.get_width())

        x=ranx + count * 4
        y=rany + count * 4
        size = 20 + count
        color = (random.randrange(0,250), random.randrange(0,250), random.randrange(0,255))

        pos = (x,y)#pygame.mouse.get_pos()
        pygame.draw.circle(screen,color,pos,size, 0)
        time.sleep(.05)
#        pygame.gfxdraw.aacircle(screen, x, y, size, color)
#        pygame.gfxdraw.filled_circle(screen, x, y, size, color)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号