コード例 #1
0
ファイル: rigid_body_bullet.cpp プロジェクト: DSeanLaw/godot
void RigidBodyBullet::main_shape_resetted() {
	if (get_main_shape())
		btBody->setCollisionShape(get_main_shape());
	else
		btBody->setCollisionShape(BulletPhysicsServer::get_empty_shape());
	set_continuous_collision_detection(is_continuous_collision_detection_enabled()); // Reset
}
コード例 #2
0
ファイル: rigid_body_bullet.cpp プロジェクト: DSeanLaw/godot
void RigidBodyBullet::reload_body() {
	if (space) {
		space->remove_rigid_body(this);
		if (get_main_shape())
			space->add_rigid_body(this);
	}
}
コード例 #3
0
ファイル: area_bullet.cpp プロジェクト: Calinou/godot
void AreaBullet::main_shape_changed() {
	CRASH_COND(!get_main_shape())
	btGhost->setCollisionShape(get_main_shape());
}