From 5cf2e69e44c07432d33481c9ee9cb5a5b37fd632 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Sun, 2 Mar 2025 22:47:00 -0500 Subject: [PATCH 01/21] Adding Child Entities Tab Adding Child Entities Tab --- .../entityProperties/html/tabs/children.png | Bin 0 -> 762 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 scripts/system/create/entityProperties/html/tabs/children.png diff --git a/scripts/system/create/entityProperties/html/tabs/children.png b/scripts/system/create/entityProperties/html/tabs/children.png new file mode 100644 index 0000000000000000000000000000000000000000..8bafc9ba2970029f5b7baa54e0deb59b1a8042d4 GIT binary patch literal 762 zcmW-eYivtl0EXYMr|ZsUZ4YDCuIykW*v6O`!@jdrbz-ia+pyYPN|x9mqLC#|w~jNj zsS05dDsC0FScZ%UOMG)lCT=4mt~J;AL464fI9; zSt;KfnHEe{Dh;^{W4dE|Ss_!OZlbei#leFa2?U*^-Y_q5WePWLP& z>H(!Y>8q^UnImR)tOv#0R%Ng`UG(uRR|)3|5rj@qOFwqZ)0V8BsxWB;8cu(}l@^Jw z^laCKJ0&Fagr+C3b!`cR7b}y#NuQUvyV`rK@@Pc&HRaI<+PQZ`%yVJ0HfqN}?HOfh z%q;6VDZ?GlZp;6b{_ag;GZ$*2EA&6_CI#D4gg?@gqIW-{!GisC?(u?4sp`r=vhEcp zXJog&)q+^(*ow7o-l+G zP3hv`Ia45;kEM0Kwf1K3-M>{yRe`RxMs|ey{~J=WUG!AX088^@?=6WmF``A)DFmN>$p-)#cXPIQgC_@-1j-P=k#t4~g`G?q0TpW)`&Ggocd z Date: Sun, 2 Mar 2025 22:47:54 -0500 Subject: [PATCH 02/21] Adding Child Entities Tab Adding Child Entities Tab --- .../html/js/entityProperties.js | 144 +++++++++++++++--- 1 file changed, 125 insertions(+), 19 deletions(-) diff --git a/scripts/system/create/entityProperties/html/js/entityProperties.js b/scripts/system/create/entityProperties/html/js/entityProperties.js index 408a3771cc..71d05af3b3 100644 --- a/scripts/system/create/entityProperties/html/js/entityProperties.js +++ b/scripts/system/create/entityProperties/html/js/entityProperties.js @@ -3,7 +3,7 @@ // Created by Ryan Huffman on November 13th, 2014 // Copyright 2014 High Fidelity, Inc. // Copyright 2020 Vircadia contributors. -// Copyright 2022-2024 Overte e.V. +// Copyright 2022-2025 Overte e.V. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html @@ -81,6 +81,7 @@ const GROUPS = [ label: "Parent", type: "string", propertyID: "parentID", + buttons: [ { id: "navigateToParentEntity", label: "1", className: "navigation", onClick: navigateToSpecificEntityFromParentID } ], onChange: parentIDChanged, }, { @@ -495,7 +496,7 @@ const GROUPS = [ }, { type: "buttons", - buttons: [ { id: "copy", label: "Copy from Skybox", + buttons: [ { id: "copy", label: "Copy URL from Skybox", className: "black", onClick: copySkyboxURLToAmbientURL } ], propertyID: "copyURLToAmbient", showPropertyRule: { "ambientLightMode": "enabled" }, @@ -2156,28 +2157,39 @@ const GROUPS = [ } ] }, + { + id: "children", + label: "CHILD ENTITIES", + properties: [ + { + label: "Children", + type: "childList", + propertyID: "children", + } + ] + }, ]; const GROUPS_PER_TYPE = { - None: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Shape: [ 'base', 'shape', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Text: [ 'base', 'text', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], + None: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Shape: [ 'base', 'shape', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Text: [ 'base', 'text', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], Zone: [ 'base', 'zone', 'zone_key_light', 'zone_skybox', 'zone_ambient_light', 'zone_haze', 'zone_bloom', 'zone_tonemapping', 'zone_ambient_occlusion', 'zone_avatar_priority', - 'zone_audio', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], - Model: [ 'base', 'model', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Image: [ 'base', 'image', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Web: [ 'base', 'web', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Light: [ 'base', 'light', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Material: [ 'base', 'material', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], + 'zone_audio', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], + Model: [ 'base', 'model', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Image: [ 'base', 'image', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Web: [ 'base', 'web', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Light: [ 'base', 'light', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Material: [ 'base', 'material', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], ParticleEffect: [ 'base', 'particles', 'particles_emit', 'particles_size', 'particles_color', - 'particles_behavior', 'particles_constraints', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], - ProceduralParticleEffect: [ 'base', 'particles_procedural', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], - PolyLine: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - PolyVox: [ 'base', 'polyvox', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], - Grid: [ 'base', 'grid', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], - Sound: [ 'base', 'sound', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics' ], - Multiple: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics' ], + 'particles_behavior', 'particles_constraints', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], + ProceduralParticleEffect: [ 'base', 'particles_procedural', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], + PolyLine: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + PolyVox: [ 'base', 'polyvox', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], + Grid: [ 'base', 'grid', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], + Sound: [ 'base', 'sound', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'physics', 'children' ], + Multiple: [ 'base', 'spatial', 'behavior', 'grabAndEquip', 'scripts', 'collision', 'physics', 'children' ], }; const EDITOR_TIMEOUT_DURATION = 1500; @@ -2440,6 +2452,10 @@ function resetProperties() { setZonesSelectionData(property.elInput, false); break; } + case 'childList': { + setChildListData(property.elInput, undefined, ""); + break; + } case 'icon': { property.elSpan.style.display = "none"; break; @@ -3643,6 +3659,10 @@ function createProperty(propertyData, propertyElementID, propertyName, propertyI property.elInput = createZonesSelection(property, elProperty); break; } + case 'childList': { + property.elInput = createChildList(property, elProperty); + break; + } case 'icon': { property.elSpan = createIconProperty(property, elProperty); break; @@ -4753,6 +4773,75 @@ function setZonesSelectionData(element, isEditable) { displaySelectedZones(element.id, isEditable); } + +/** + * CHILD ENTITIES FUNCTIONS + */ + +function createChildList(property, elProperty) { + let elementID = property.elementID; + elProperty.className = "childEntityList"; + + let elInput = document.createElement('div'); + elInput.setAttribute("id", "childList-" + elementID); + + elProperty.appendChild(elInput); + return elInput; +} + +function setChildListData(element, children, parentID) { + let childListContainer = document.getElementById(element.id); + let renderer = ""; + let i; + if (parentID !== "") { + renderer += "🡅 View Parent
"; + } else { + renderer += "
"; + } + renderer += ""; + renderer += ""; + if (children === undefined) { + renderer += ""; + } else { + if (children.length > 0) { + for (i = 0; i < children.length; i++ ) { + let entityHostTypeClass = ""; + if (children[i].entityHostType !== "domain") { + entityHostTypeClass = " class='" + children[i].entityHostType + "Entity'"; + } + let navigatorBtn = "🡆"; + renderer += ""; + } + } else { + renderer += ""; + } + } + renderer += "
TYPENAMEVIEW
Not applicable
" + children[i].type + "" + children[i].name + "" + navigatorBtn + "
No children
"; + childListContainer.innerHTML = renderer; +} + +function navigateToSpecificEntityFromParentID() { + let parentID = getPropertyInputElement("parentID").value; + if (parentID !== "" && parentID !== "{00000000-0000-0000-0000-000000000000}") { + navigateToSpecificEntity(parentID); + } +} + +function setParentIdNavigationAvailable(selectionLength) { + if (selectionLength === 1) { + $('#property-parentID-button-navigateToParentEntity').attr('disabled', false); + } else { + $('#property-parentID-button-navigateToParentEntity').attr('disabled', true); + } +} + +function navigateToSpecificEntity(id) { + EventBridge.emitWebEvent(JSON.stringify({ + type: "specificEntityNavigation", + id: id + })); +} + /** * MATERIAL TARGET FUNCTIONS */ @@ -4974,6 +5063,8 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { setCopyPastePositionAndRotationAvailability (selections.length, true); disableProperties(); + + setParentIdNavigationAvailable(selections.length); } else { let entityHostType = selections[0].properties.entityHostType; @@ -5006,6 +5097,7 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { disableProperties(); getPropertyInputElement('locked').removeAttribute('disabled'); setCopyPastePositionAndRotationAvailability (selections.length, true); + setParentIdNavigationAvailable(selections.length); } else { enableProperties(); disableSaveUserDataButton(); @@ -5013,6 +5105,7 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { disableSaveParticleUpdateDataButton(); disableSaveParticleRenderDataButton(); setCopyPastePositionAndRotationAvailability (selections.length, false); + setParentIdNavigationAvailable(selections.length); } Object.entries(properties).forEach(function([propertyID, property]) { @@ -5037,7 +5130,9 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { const isSubProperty = propertyData.subPropertyOf !== undefined; if (propertyValue === undefined && !isMultiDiffValue && !isSubProperty) { - return; + if (propertyData.type !== "childList") { + return; + } } if (!shownGroups.includes(property.group_id)) { @@ -5198,6 +5293,14 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { } break; } + case 'childList': { + let parentID = selections[0].properties.parentID; + if (selections.length !== 1 || parentID === "{00000000-0000-0000-0000-000000000000}") { + parentID = ""; + } + setChildListData(property.elInput, propertyValue, parentID); + break; + } case 'icon': { property.elSpan.innerHTML = propertyData.icons[propertyValue]; property.elSpan.style.display = "inline-block"; @@ -5641,6 +5744,9 @@ function loaded() { elScript.parentNode.className = "url refresh"; elServerScripts.parentNode.className = "url refresh"; + let elParentID = getPropertyInputElement("parentID"); + elParentID.parentNode.className = "url refresh"; + // User Data let userDataProperty = properties["userData"]; let elUserData = userDataProperty.elInput; From 52b9972882f1b8a509b05df9407724fe77446cd5 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Sun, 2 Mar 2025 22:48:50 -0500 Subject: [PATCH 03/21] Adding Child Entities Tab Adding Child Entities Tab --- scripts/system/create/edit.js | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/scripts/system/create/edit.js b/scripts/system/create/edit.js index 24df1c9e0f..5cd3fb1a23 100644 --- a/scripts/system/create/edit.js +++ b/scripts/system/create/edit.js @@ -4,7 +4,7 @@ // Persist toolbar by HRS on June 2nd, 2015. // Copyright 2014 High Fidelity, Inc. // Copyright 2020 Vircadia contributors. -// Copyright 2022-2024 Overte e.V. +// Copyright 2022-2025 Overte e.V. // // This script allows you to edit entities with a new UI/UX for mouse and trackpad based editing // @@ -2609,6 +2609,10 @@ entity.properties.keyLight.direction = Vec3.toPolar(entity.properties.keyLight.direction); entity.properties.keyLight.direction.z = 0.0; } + if (selectionManager.selections.length === 1) { + entity.properties.children = createApp.getChildEntitiesList(entity.id); + } + selections.push(entity); } data.selections = selections; @@ -2980,6 +2984,8 @@ type: 'importUi_LOAD_DATA', importUiPersistedData: importUiPersistedData }); + } else if (data.type === "specificEntityNavigation") { + selectionManager.setSelections([data.id], this); } }; @@ -3386,7 +3392,7 @@ } } - createApp.rotateAsNextClickedSurface = function() { + createApp.rotateAsNextClickedSurface = function() { if (!SelectionManager.hasSelection() || !SelectionManager.hasUnlockedSelection()) { audioFeedback.rejection(); Window.notifyEditError("You have nothing selected, or the selection is locked."); @@ -3396,4 +3402,19 @@ } } + createApp.getChildEntitiesList = function(parentID) { + let children = Entities.getChildrenIDs(parentID); + let childList = []; + let i, properties; + if (children.length > 0) { + for (i = 0; i < children.length; i++ ) { + properties = Entities.getEntityProperties(children[i], ["id", "name", "type", "entityHostType"]); + if (properties.name !== undefined && properties.name !== entityShapeVisualizerSessionName) { + childList.push(properties); + } + } + } + return childList; + } + }()); // END LOCAL_SCOPE From b3d9b62971371afd30fccab3527bd47328da927c Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Sun, 2 Mar 2025 22:50:44 -0500 Subject: [PATCH 04/21] Adding Child Entities Tab Adding Child Entities Tab --- scripts/system/html/css/edit-style.css | 29 +++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/scripts/system/html/css/edit-style.css b/scripts/system/html/css/edit-style.css index 3ec78eb6cc..5f344eb3e8 100644 --- a/scripts/system/html/css/edit-style.css +++ b/scripts/system/html/css/edit-style.css @@ -4,7 +4,7 @@ // Created by Ryan Huffman on November 13th, 2014 // Copyright 2014 High Fidelity, Inc. // Copyright 2020 Vircadia contributors. -// Copyright 2022-2024 Overte e.V. +// Copyright 2022-2025 Overte e.V. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html @@ -175,10 +175,21 @@ tr:focus { outline: none; } +th.childrenTableHeader { + height: 26px; + background-color: #1c1c1c; + border-right: 1px solid #575757; + border-bottom: 1px solid #575757; +} + tr.avatarEntity { color: #7fdb98; } +tr.localEntity { + color: #f0d769; +} + tr.selAvatarEntity { color: #000000; background-color: #7fdb98; @@ -446,6 +457,18 @@ input[type=button].glyph, button.hifi-edit-button.glyph { padding: 0; } +input[type=button].navigation, button.hifi-edit-button.navigation { + font-family: HiFi-Glyphs; + font-size: 20px; + text-transform: none; + min-width: 32px; + padding: 0; +} + +input[type=button].navigation:focus, button.hifi-edit-button.navigation:focus { + outline: none; +} + input[type=button].normal, button.hifi-edit-button.normal { font-family: FiraSans-SemiBold; font-size: 15px; @@ -2211,3 +2234,7 @@ div.menu-item-caption { div.menu-item-shortcut { float: right; } + +span.viewParent { + color: #ffffff; +} From df387d29a1761cea950a6a08ca3fc8638fc7ae02 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Mon, 3 Mar 2025 19:13:42 -0500 Subject: [PATCH 05/21] Add: Copy Skybox Color to Ambient Color Add: Copy Skybox Color to Ambient Color --- .../html/js/entityProperties.js | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/scripts/system/create/entityProperties/html/js/entityProperties.js b/scripts/system/create/entityProperties/html/js/entityProperties.js index 71d05af3b3..af0b9c474a 100644 --- a/scripts/system/create/entityProperties/html/js/entityProperties.js +++ b/scripts/system/create/entityProperties/html/js/entityProperties.js @@ -477,6 +477,13 @@ const GROUPS = [ propertyID: "ambientLight.ambientColor", showPropertyRule: { "ambientLightMode": "enabled" }, }, + { + type: "buttons", + buttons: [ { id: "copy", label: "Copy color from Skybox", + className: "black", onClick: copySkyboxColorToAmbientColor } ], + propertyID: "copyColorToAmbient", + showPropertyRule: { "ambientLightMode": "enabled" }, + }, { label: "Ambient Intensity", type: "number-draggable", @@ -2259,6 +2266,7 @@ let currentSpaceMode = PROPERTY_SPACE_MODE.LOCAL; let zonesList = []; let canViewAssetURLs = false; let maSelectedId; +let skyboxColorForCopy; function createElementFromHTML(htmlString) { let elTemplate = document.createElement('template'); @@ -3811,6 +3819,10 @@ function copySkyboxURLToAmbientURL() { updateProperty("ambientLight.ambientURL", skyboxURL, false); } +function copySkyboxColorToAmbientColor() { + updateProperty("ambientLight.ambientColor", skyboxColorForCopy, false); +} + function copyPositionProperty() { EventBridge.emitWebEvent(JSON.stringify({ type: "action", @@ -5014,15 +5026,21 @@ function handleEntitySelectionUpdate(selections, isPropertiesToolUpdate) { selectedEntityIDs = new Set(selections.map(selection => selection.id)); const multipleSelections = currentSelections.length > 1; const hasSelectedEntityChanged = !areSetsEqual(selectedEntityIDs, previouslySelectedEntityIDs); - + if (selections.length === 1) { if (maSelectedId !== selections[0].id) { closeMaterialAssistant(); } maSelectedId = selections[0].id; + if (selections[0].properties.type === "Zone") { + skyboxColorForCopy = selections[0].properties.skybox.color; + } else { + skyboxColorForCopy = undefined; + } } else { closeMaterialAssistant(); maSelectedId = ""; + skyboxColorForCopy = undefined; } requestZoneList(); From 999475aca736a6bacdc2287858adece0c8aff5b3 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Wed, 5 Mar 2025 22:25:15 -0500 Subject: [PATCH 06/21] Css for Create Child Entities Css for Create Child Entities --- .../html/css/createChildEntityAssistant.css | 168 ++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 scripts/system/html/css/createChildEntityAssistant.css diff --git a/scripts/system/html/css/createChildEntityAssistant.css b/scripts/system/html/css/createChildEntityAssistant.css new file mode 100644 index 0000000000..5b728bd544 --- /dev/null +++ b/scripts/system/html/css/createChildEntityAssistant.css @@ -0,0 +1,168 @@ +/* +// createChildEntityAssistant.css +// +// Created by Alezia Kurdis on March 3rd, 2025. +// Copyright 2025 Overte e.V. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +*/ + +#uiCreateChildEntityAssistant { + position: fixed; + display: none; + width: 100%; + top: 0px; + left: 0px; + right: 0px; + bottom: 0px; + border: 0px; + padding: 0px; + background-color: #404040; + z-index: 2; + border-collapse: collapse; +} + +#uiCreateChildEntityAssistant-scrollable { + border-collapse: collapse; + overflow-y: scroll; + height: 100%; +} + +#uiCreateChildEntityAssistant-headerContainer { + width: 98%; + text-align: right; + padding: 6px; + display: flex; +} + +#uiCreateChildEntityAssistant-closeButton { + font-family: Raleway-Bold; + font-size: 18px; + text-align: center; + border: 0px; + padding: 6px; + color: #FFFFFF; +} + +font.uiCreateChildEntityAssistant-Explain{ + background-color: #2E2E2E; + font-family: Raleway-Regular; + text-decoration: Italic; + font-size: 10px; + color: #8ad5ff; +} + +font.uiCreateChildEntityAssistant-label{ + background-color: #2E2E2E; + font-family: Raleway-SemiBold; + text-decoration: none; + font-size: 12px; + color: #D2D2D2; +} + +label.uiCreateChildEntityAssistant-label{ + background-color: #2E2E2E; + font-family: Raleway-SemiBold; + text-decoration: none; + font-size: 12px; + color: #D2D2D2; +} + +font.uiCreateChildEntityAssistant-title{ + background-color: #404040; + font-family: Raleway-Bold; + font-size: 18px; + text-decoration: none; + color: #F2F2F2; + white-space: normal; +} + +#urlCreateChildEntityAssistant { + background-color: #222222; + color: #bbbbbb; + width: 90%; +} + +#childEntityActionsContainer { + width: 100%; + text-align: center; + padding: 3px; +} + +#viewParentContainer { + display: inline-block; + text-align: left; + width: 50%; + vertical-align: middle; +} + +#addChildEntityContainer { + display: inline-block; + width: 50%; + text-align: right; + vertical-align: middle; +} + +span.tileCreateChildEntityAssistant-domain { + border: 2px solid #000000; + background-color: #000000; + padding: 5px; + margin: 10px; + display: inline-block; + text-align: center; + border-radius: 10px; + width: 80px; + height: 80px; + color: #FFFFFF; + font-family: FiraSans-SemiBold; + font-size: 13px; +} + +span.tileCreateChildEntityAssistant-domain:hover { + border: 2px solid #FFFFFF; +} + +span.tileCreateChildEntityAssistant-avatar { + border: 2px solid #000000; + background-color: #000000; + padding: 5px; + margin: 10px; + display: inline-block; + text-align: center; + align-items: center; + border-radius: 10px; + width: 80px; + height: 80px; + color: #7fdb98; + font-family: FiraSans-SemiBold; + font-size: 13px; +} + +span.tileCreateChildEntityAssistant-avatar:hover { + border: 2px solid #7fdb98; +} + +font.iconCreateChildEntityAssistant { + font-family: HiFi-Glyphs; + font-size: 50px; +} + +#typeSelectorCreateChildEntityAssistant { + width: 100%; + text-align: center; +} + +font.addChildEntity-domain { + color: #FFFFFF; +} + +font.addChildEntity-avatar { + color: #7fdb98; +} + +#paramaterCreateChildEntityAssistant { + font-family: FiraSans-SemiBold; + font-size: 14px; + padding: 10px; +} From 074381d336f150427d798e9dea775e1eb00a7279 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Wed, 5 Mar 2025 22:26:41 -0500 Subject: [PATCH 07/21] Add Create Child Entities Add Create Child Entities --- scripts/system/create/edit.js | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/scripts/system/create/edit.js b/scripts/system/create/edit.js index 5cd3fb1a23..6ea9a6d8c6 100644 --- a/scripts/system/create/edit.js +++ b/scripts/system/create/edit.js @@ -542,7 +542,7 @@ localOnly: false }, }; - + var fcreateNewEntity; var toolBar = (function () { var EDIT_SETTING = "io.highfidelity.isEditing"; // for communication with other scripts var that = {}, @@ -552,7 +552,7 @@ dialogWindow = null, tablet = null; - function createNewEntity(requestedProperties) { + function createNewEntity(requestedProperties, entityHostType="domain") { var dimensions = requestedProperties.dimensions ? requestedProperties.dimensions : DEFAULT_DIMENSIONS; var position = createApp.getPositionToCreateEntity(); var entityID = null; @@ -632,7 +632,7 @@ properties.visible = false; } - entityID = Entities.addEntity(properties); + entityID = Entities.addEntity(properties, entityHostType); var dimensionsCheckCallback = function(){ // Adjust position of entity per bounding box after it has been created and auto-resized. @@ -711,7 +711,9 @@ return entityID; } - + + fcreateNewEntity = createNewEntity; + function closeExistingDialogWindow() { if (dialogWindow) { dialogWindow.close(); @@ -2986,6 +2988,8 @@ }); } else if (data.type === "specificEntityNavigation") { selectionManager.setSelections([data.id], this); + } else if (data.type === "createChildEntity") { + fcreateNewEntity(data.properties, data.entityHostType); } }; From 202a6579c9674a65157c43664588e4bf60f18a67 Mon Sep 17 00:00:00 2001 From: Alezia Kurdis <60075796+AleziaKurdis@users.noreply.github.com> Date: Wed, 5 Mar 2025 22:27:27 -0500 Subject: [PATCH 08/21] Add Create Child Entities Add Create Child Entities --- .../create/entityProperties/html/entityProperties.html | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/scripts/system/create/entityProperties/html/entityProperties.html b/scripts/system/create/entityProperties/html/entityProperties.html index 5fd7892fae..8d78d5c6f8 100644 --- a/scripts/system/create/entityProperties/html/entityProperties.html +++ b/scripts/system/create/entityProperties/html/entityProperties.html @@ -5,7 +5,7 @@ // Created by Ryan Huffman on 13 Nov 2014 // Copyright 2014 High Fidelity, Inc. // Copyright 2020 Vircadia contributors. -// Copyright 2022-2024 Overte e.V. +// Copyright 2022-2025 Overte e.V. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html @@ -20,6 +20,7 @@ + @@ -62,6 +63,13 @@ +