mirror of
https://github.com/overte-org/overte.git
synced 2025-06-18 07:40:09 +02:00
try again on string startswith
This commit is contained in:
parent
c27766facb
commit
b417abc3de
3 changed files with 2 additions and 8 deletions
|
@ -104,7 +104,7 @@ function entityIsGrabbedByOther(entityID) {
|
||||||
if (tag == getTag()) {
|
if (tag == getTag()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (tag.startsWith("grab-")) {
|
if (tag.slice(0, 5) == "grab-") {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@ function entityIsGrabbedByOther(entityID) {
|
||||||
if (tag == getTag()) {
|
if (tag == getTag()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (tag.startsWith("grab-")) {
|
if (tag.slice(0, 5) == "grab-") {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -179,9 +179,3 @@ pointInExtents = function(point, minPoint, maxPoint) {
|
||||||
(point.y >= minPoint.y && point.y <= maxPoint.y) &&
|
(point.y >= minPoint.y && point.y <= maxPoint.y) &&
|
||||||
(point.z >= minPoint.z && point.z <= maxPoint.z);
|
(point.z >= minPoint.z && point.z <= maxPoint.z);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeof String.prototype.startsWith != 'function') {
|
|
||||||
String.prototype.startsWith = function (str){
|
|
||||||
return this.slice(0, str.length) == str;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in a new issue