예제 #1
0
def mousePressed():
    global caja, x, y
    caja = FBox(4, 4)
    caja.setStaticBody(True)
    caja.setStroke(255)
    caja.setFill(255)
    caja.setRestitution(0.9)
    mundo.add(caja)

    x = mouseX
    y = mouseY
예제 #2
0
def mousePressed():
    global caja, x, y
    caja = FBox(4, 4)
    caja.setStaticBody(True)
    caja.setStroke(255)
    caja.setFill(255)
    caja.setRestitution(0.9)
    mundo.add(caja)

    x = mouseX
    y = mouseY
예제 #3
0
def setup():
    global world, pala
    size(400, 400)
    smooth()
    Fisica.init(this)
    world = FWorld()
    pala = FBox(50, 20)
    pala.setPosition(width / 2, height - 40)
    pala.setStatic(True)
    pala.setFill(0)
    pala.setRestitution(0)
    world.add(pala)
예제 #4
0
def setup():
    global world, pala
    size(400, 400)
    smooth()
    Fisica.init(this)
    world = FWorld()
    pala = FBox(50, 20)
    pala.setPosition(width/2, height - 40)
    pala.setStatic(True)
    pala.setFill(0)
    pala.setRestitution(0)
    world.add(pala)
예제 #5
0
def setup():
    global world, obstacle
    size(400, 400)
    smooth()
    Fisica.init(this)
    world = FWorld()
    obstacle = FBox(150,150)
    obstacle.setRotation(PI/4)
    obstacle.setPosition(width/2, height/2)
    obstacle.setStatic(True)
    obstacle.setFill(0)
    obstacle.setRestitution(0)
    world.add(obstacle)
예제 #6
0
def setup():
    global world, obstacle
    size(400, 400)
    smooth()
    Fisica.init(this)
    world = FWorld()
    obstacle = FBox(150, 150)
    obstacle.setRotation(PI / 4)
    obstacle.setPosition(width / 2, height / 2)
    obstacle.setStatic(True)
    obstacle.setFill(0)
    obstacle.setRestitution(0)
    world.add(obstacle)