我正在尝试学习 PyMunk 库,我使用了他们网站上的示例。这是一个代码:
import pymunk # Import pymunk..
space = pymunk.Space() # Create a Space which contain the simulation
space.gravity = 0,-1000 # Set its gravity
body = pymunk.Body(1,1666) # Create a Body with mass and moment
body.position = 50,100 # Set the position of the body
poly = pymunk.Poly.create_box(body) # Create a box shape and attach to body
space.add(body, poly) # Add both body and shape to the simulation
while True: # Infinite loop simulation
space.step(0.02) # Step the simulation one step forward
当我运行它时,窗口没有出现,在 CMD 中它说:Loading chipmunk for Windows (64bit) [C:\Users\Theo\AppData\Local\Programs\Python\Python35\lib\site-packages\pymunk\chipmunk.dll]
并且不加载任何东西。我等了一个小时。问题是什么?