mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-06-03 11:40:42 +02:00
Disable debug messages in voxel editing
This commit is contained in:
parent
3df9d6674b
commit
0401b22382
1 changed files with 16 additions and 13 deletions
|
@ -308,7 +308,8 @@ EditVoxels = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function mousePressEvent(event) {
|
function mousePressEvent(event) {
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
|
var attemptChangeOnEmpty = false;
|
||||||
if (!editEnabled || !isActive) {
|
if (!editEnabled || !isActive) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -366,20 +367,22 @@ EditVoxels = function() {
|
||||||
|
|
||||||
// if the PolyVox entity is empty, we can't pick against its "on" voxels. try picking against its
|
// if the PolyVox entity is empty, we can't pick against its "on" voxels. try picking against its
|
||||||
// bounding box, instead.
|
// bounding box, instead.
|
||||||
intersection = Entities.findRayIntersection(pickRay, false); // bounding box picking
|
if (attemptChangeOnEmpty) {
|
||||||
if (intersection.intersects) {
|
intersection = Entities.findRayIntersection(pickRay, false); // bounding box picking
|
||||||
if(attemptVoxelChange(pickRay.direction, intersection)){
|
if (intersection.intersects) {
|
||||||
Script.update.connect(onUpdateHandler);
|
if(attemptVoxelChange(pickRay.direction, intersection)){
|
||||||
isOnUpdateConnected = true;
|
Script.update.connect(onUpdateHandler);
|
||||||
if (wantDebug) {
|
isOnUpdateConnected = true;
|
||||||
print("onUpdateHandler connected");
|
if (wantDebug) {
|
||||||
|
print("onUpdateHandler connected");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function mouseReleaseEvent(event) {
|
function mouseReleaseEvent(event) {
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
|
|
||||||
if (wantDebug) {
|
if (wantDebug) {
|
||||||
print("=============== eV::mouseReleaseEvent BEG =======================");
|
print("=============== eV::mouseReleaseEvent BEG =======================");
|
||||||
|
@ -474,7 +477,7 @@ EditVoxels = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateSphereResizing(delta) {
|
function updateSphereResizing(delta) {
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
var newDistance = getDistanceBetweenControllers();
|
var newDistance = getDistanceBetweenControllers();
|
||||||
var newRadius = (sphereInitialRadius / sphereResizingInitialHandDistance) * newDistance;
|
var newRadius = (sphereInitialRadius / sphereResizingInitialHandDistance) * newDistance;
|
||||||
var newPosition = getEditSpherePosition(newRadius);
|
var newPosition = getEditSpherePosition(newRadius);
|
||||||
|
@ -496,7 +499,7 @@ EditVoxels = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function startSphereResizing() {
|
function startSphereResizing() {
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
if (wantDebug) {
|
if (wantDebug) {
|
||||||
print("=============== eV::startSphereResizing BEG =======================");
|
print("=============== eV::startSphereResizing BEG =======================");
|
||||||
}
|
}
|
||||||
|
@ -518,7 +521,7 @@ EditVoxels = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function stopSphereResizing() {
|
function stopSphereResizing() {
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
if (wantDebug) {
|
if (wantDebug) {
|
||||||
print("=============== eV::stopSphereResizing BEG =======================");
|
print("=============== eV::stopSphereResizing BEG =======================");
|
||||||
}
|
}
|
||||||
|
@ -562,7 +565,7 @@ EditVoxels = function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function onUpdateHandler(delta){
|
function onUpdateHandler(delta){
|
||||||
var wantDebug = true;
|
var wantDebug = false;
|
||||||
//if (wantDebug) {
|
//if (wantDebug) {
|
||||||
//print("=============== eV::onUpdateHandler BEG =======================");
|
//print("=============== eV::onUpdateHandler BEG =======================");
|
||||||
//}
|
//}
|
||||||
|
|
Loading…
Reference in a new issue