159b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta/*
259b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta * To change this template, choose Tools | Templates
359b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta * and open the template in the editor.
459b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta */
559b2e6871c65f58fdad78cd7229c292f6a177578Scott Bartapackage com.jme3.bullet.control;
659b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta
759b2e6871c65f58fdad78cd7229c292f6a177578Scott Bartaimport com.jme3.bullet.PhysicsSpace;
859b2e6871c65f58fdad78cd7229c292f6a177578Scott Bartaimport com.jme3.scene.control.Control;
959b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta
1059b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta/**
1159b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta *
1259b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta * @author normenhansen
1359b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta */
1459b2e6871c65f58fdad78cd7229c292f6a177578Scott Bartapublic interface PhysicsControl extends Control {
1559b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta
1659b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta    public void setPhysicsSpace(PhysicsSpace space);
1759b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta
1859b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta    public PhysicsSpace getPhysicsSpace();
1959b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta
2059b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta    /**
2159b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     * The physics object is removed from the physics space when the control
2259b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     * is disabled. When the control is enabled  again the physics object is
2359b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     * moved to the current location of the spatial and then added to the physics
2459b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     * space. This allows disabling/enabling physics to move the spatial freely.
2559b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     * @param state
2659b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta     */
2759b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta    public void setEnabled(boolean state);
2859b2e6871c65f58fdad78cd7229c292f6a177578Scott Barta}
29