mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 09:28:46 +02:00
whitespace + "waiting for entity server"
No functionality changes, but now prints "waiting for entity server" once if waiting for more than X seconds in startup().
This commit is contained in:
parent
c25d8857d9
commit
e723a5c0fd
1 changed files with 1087 additions and 1076 deletions
|
@ -985,7 +985,7 @@ var PLATFORM_SHAPE_DIMENSIONS_RANGE = [ 0.001, 2.0 ]; // axis-aligned entity dim
|
|||
/// Setup the UI. Creates a bunch of sliders for setting the platform radius, density, and entity color / shape properties.
|
||||
/// The entityCount slider is readonly.
|
||||
function _setupUI (platform) {
|
||||
var layoutContainer = makePanel("+y", { visible: true });
|
||||
var layoutContainer = makePanel("+y", { visible: false });
|
||||
// layoutContainer.setPosition(10, 280);
|
||||
// makeDraggable(layoutContainer);
|
||||
_export.onScreenResize = function () {
|
||||
|
@ -1173,7 +1173,7 @@ var CATCH_ERRORS_FROM_EVENT_UPDATES = false;
|
|||
}
|
||||
|
||||
// Delays startup until / if entities can be spawned.
|
||||
this.startup = function () {
|
||||
this.startup = function (dt) {
|
||||
if (Entities.canAdjustLocks() && Entities.canRez()) {
|
||||
Script.update.disconnect(this.startup);
|
||||
|
||||
|
@ -1202,8 +1202,19 @@ var CATCH_ERRORS_FROM_EVENT_UPDATES = false;
|
|||
Controller.mousePressEvent.connect(UI.handleMousePress);
|
||||
Controller.mouseMoveEvent.connect(UI.handleMouseMove);
|
||||
Controller.mouseReleaseEvent.connect(UI.handleMouseRelease);
|
||||
} else {
|
||||
if (!startup.printedWarnMsg) {
|
||||
startup.timer = startup.timer || startup.ENTITY_SERVER_WAIT_TIME;
|
||||
if ((startup.timer -= dt) < 0.0) {
|
||||
logMessage("Waiting for entity server");
|
||||
startup.printedWarnMsg = true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
startup.ENTITY_SERVER_WAIT_TIME = 0.2; // print "waiting for entity server" if more than this time has elapsed in startup()
|
||||
|
||||
Script.update.connect(this.startup);
|
||||
})();
|
||||
|
||||
|
|
Loading…
Reference in a new issue