expose instance id + add docs

This commit is contained in:
Dmitry Stepanov
2025-08-16 12:20:55 +03:00
parent 25652975e0
commit 056db07914
2 changed files with 7 additions and 3 deletions
@@ -169,6 +169,7 @@ use crate::{
},
},
};
use fyrox::scene::base::SceneNodeId;
pub mod animation;
pub mod font;
@@ -319,6 +320,8 @@ pub fn make_property_editors_container(
container.insert(make_status_enum_editor_definition());
container.insert(InspectablePropertyEditorDefinition::<SceneNodeId>::new());
container.insert(EnumPropertyEditorDefinition::<LodGroup>::new_optional());
container.insert(InheritablePropertyEditorDefinition::<Option<LodGroup>>::new());
+4 -3
View File
@@ -296,7 +296,6 @@ pub enum NodeScriptMessage {
Deserialize,
)]
#[repr(transparent)]
#[reflect(hide_all)]
pub struct SceneNodeId(pub Uuid);
impl Visit for SceneNodeId {
@@ -520,8 +519,10 @@ pub struct Base {
#[reflect(hidden)]
pub(crate) original_handle_in_resource: Handle<Node>,
#[reflect(read_only)]
#[reflect(hidden)]
/// Unique id of a node, that could be used as a reliable "index" of the node. This id is mostly
/// useful for network games. Keep in mind, that this id **will** be randomized in case if you're
/// instantiating a prefab. In other words, all instances of a prefab will have unique instance
/// id.
pub(crate) instance_id: SceneNodeId,
// Scripts of the scene node.