You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Just putting this here for future reference. @Azaezel and I were working on this a few weeks ago but I'm not sure we found a conclusive fix.
Quick summary of the problems with setHidden():
1). Parts of the engine assume that setHidden() is an editor-only function that will only be called while the world editor is open (see SimObject::setHidden()). This results in weird behavior like hidden objects being rendered when the mission is reloaded, setHidden() not working at all on certain classes (like StaticShapes and Precipitation), etc.
2). The engine 'hides' an object by just removing it from the scene manager which conflicts with how objects are ghosted. Objects marked GhostAlways typically hide/show correctly for all clients due to the ghost objects being forcibly removed but objects that are marked Ghostable won't have their 'hidden' status propagated correctly. This results in desyncs and issues with things like collision (client thinks the object is visible & collidable but the server doesn't).
The world editor deals with this issue by manually calling setHidden() on every clientside ghost (see WorldEditor::onEditorEnable).
The text was updated successfully, but these errors were encountered:
Bloodknight
added
QoL Enhancement
Non functional enhancements that make work easier (New or improved UI parts for example)
and removed
QoL Enhancement
Non functional enhancements that make work easier (New or improved UI parts for example)
labels
Aug 9, 2020
Just putting this here for future reference. @Azaezel and I were working on this a few weeks ago but I'm not sure we found a conclusive fix.
Quick summary of the problems with setHidden():
1). Parts of the engine assume that setHidden() is an editor-only function that will only be called while the world editor is open (see SimObject::setHidden()). This results in weird behavior like hidden objects being rendered when the mission is reloaded, setHidden() not working at all on certain classes (like StaticShapes and Precipitation), etc.
2). The engine 'hides' an object by just removing it from the scene manager which conflicts with how objects are ghosted. Objects marked GhostAlways typically hide/show correctly for all clients due to the ghost objects being forcibly removed but objects that are marked Ghostable won't have their 'hidden' status propagated correctly. This results in desyncs and issues with things like collision (client thinks the object is visible & collidable but the server doesn't).
The world editor deals with this issue by manually calling setHidden() on every clientside ghost (see WorldEditor::onEditorEnable).
The text was updated successfully, but these errors were encountered: