mirror of
https://github.com/overte-org/overte.git
synced 2025-04-08 04:34:38 +02:00
Update destructibleEntity to also be growable
This commit is contained in:
parent
3cddf65ba1
commit
83ec0063c0
1 changed files with 10 additions and 6 deletions
|
@ -146,13 +146,17 @@ var TEXTURE_NAME = "tex.health1";
|
|||
props.position.y += props.dimensions.y;
|
||||
Entities.addEntity(props);
|
||||
},
|
||||
startNearTrigger: function () {
|
||||
print("launch.js | got start near trigger");
|
||||
this.growBlock();
|
||||
startDistanceGrab: function () {
|
||||
print("launch.js | got start distance grab");
|
||||
this.startGrabTime = Date.now();
|
||||
},
|
||||
startFarTrigger: function () {
|
||||
print("launch.js | got start far trigger");
|
||||
this.growBlock();
|
||||
releaseGrab: function() {
|
||||
print("launch.js | release grab");
|
||||
var grabbedForMs = Date.now() - this.startGrabTime;
|
||||
print("launch.js | grab time:", grabbedForMs);
|
||||
if (grabbedForMs < 300) {
|
||||
this.growBlock();
|
||||
}
|
||||
},
|
||||
clickDownOnEntity: function () {
|
||||
print("launch.js | got click down");
|
||||
|
|
Loading…
Reference in a new issue