mirror of
https://github.com/overte-org/overte.git
synced 2025-07-23 12:04:03 +02:00
when adding asset to world set grabbable
This commit is contained in:
parent
5641c59f5f
commit
45b9871fdb
2 changed files with 3 additions and 0 deletions
|
@ -7284,6 +7284,8 @@ void Application::addAssetToWorldAddEntity(QString filePath, QString mapping) {
|
||||||
}
|
}
|
||||||
properties.setCollisionless(true); // Temporarily set so that doesn't collide with avatar.
|
properties.setCollisionless(true); // Temporarily set so that doesn't collide with avatar.
|
||||||
properties.setVisible(false); // Temporarily set so that don't see at large unresized dimensions.
|
properties.setVisible(false); // Temporarily set so that don't see at large unresized dimensions.
|
||||||
|
bool grabbable = (Menu::getInstance()->isOptionChecked(MenuOption::AnimDebugDrawDefaultPose));
|
||||||
|
properties.setUserData(grabbable ? GRABBABLE_USER_DATA : NOT_GRABBABLE_USER_DATA);
|
||||||
glm::vec3 positionOffset = getMyAvatar()->getWorldOrientation() * (getMyAvatar()->getSensorToWorldScale() * glm::vec3(0.0f, 0.0f, -2.0f));
|
glm::vec3 positionOffset = getMyAvatar()->getWorldOrientation() * (getMyAvatar()->getSensorToWorldScale() * glm::vec3(0.0f, 0.0f, -2.0f));
|
||||||
properties.setPosition(getMyAvatar()->getWorldPosition() + positionOffset);
|
properties.setPosition(getMyAvatar()->getWorldPosition() + positionOffset);
|
||||||
properties.setRotation(getMyAvatar()->getWorldOrientation());
|
properties.setRotation(getMyAvatar()->getWorldOrientation());
|
||||||
|
|
|
@ -76,6 +76,7 @@ namespace MenuOption {
|
||||||
const QString CrashOutOfBoundsVectorAccessThreaded = "Out of Bounds Vector Access (threaded)";
|
const QString CrashOutOfBoundsVectorAccessThreaded = "Out of Bounds Vector Access (threaded)";
|
||||||
const QString CrashNewFault = "New Fault";
|
const QString CrashNewFault = "New Fault";
|
||||||
const QString CrashNewFaultThreaded = "New Fault (threaded)";
|
const QString CrashNewFaultThreaded = "New Fault (threaded)";
|
||||||
|
const QString CreateEntitiesGrabbable = "Create Entities As Grabbable (except Zones, Particles, and Lights)";
|
||||||
const QString DeadlockInterface = "Deadlock Interface";
|
const QString DeadlockInterface = "Deadlock Interface";
|
||||||
const QString UnresponsiveInterface = "Unresponsive Interface";
|
const QString UnresponsiveInterface = "Unresponsive Interface";
|
||||||
const QString DecreaseAvatarSize = "Decrease Avatar Size";
|
const QString DecreaseAvatarSize = "Decrease Avatar Size";
|
||||||
|
|
Loading…
Reference in a new issue