Git Product home page Git Product logo

mindport-gmbh / vr-builder Goto Github PK

View Code? Open in Web Editor NEW
61.0 4.0 13.0 4.92 MB

VR Builder lets you create better VR experiences faster. Our code is open source and designed to be extended. Plus, our GUI empowers everyone to create fully functional VR apps - without writing code.

Home Page: https://www.mindport.co/

License: Apache License 2.0

C# 99.83% ShaderLab 0.17%
cross-platform extended-reality metaverse open-source prototyping training unity unity3d unity3d-plugin virtual-reality

vr-builder's People

Contributors

farahsibtain avatar mrwellmann avatar sythelux avatar vacevedod avatar valium09 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

vr-builder's Issues

States and Data Addon: TriggerEventBehaviours.ExecutionStages is not implemented

When ExecuteState is set to "Before Step Execution" on Trigger Event Behaviours, Events a still fired after the Step.
You just implemented the Triggering in the "End" Call of the StageProcess, not the "Start"
Corrected Example for "TriggerEventByRefBehaviour.cs":

  private class TriggerEventProcess : StageProcess<EntityData>
        {
            public TriggerEventProcess(EntityData data, BehaviorExecutionStages executionStages) : base(data)
            {
                Data.ExecutionStages = executionStages;
            }

            /// <inheritdoc />
            public override void Start()
            {
                if (Data.ExecutionStages == BehaviorExecutionStages.Activation || Data.ExecutionStages == BehaviorExecutionStages.ActivationAndDeactivation)
                {
                    Data.EventProperty.Value.TriggerEvent();
                }
            }

            /// <inheritdoc />
            public override IEnumerator Update()
            {
                yield return null;
            }

            /// <inheritdoc />
            public override void End()
            {
                if (Data.ExecutionStages == BehaviorExecutionStages.Deactivation || Data.ExecutionStages == BehaviorExecutionStages.ActivationAndDeactivation)
                {
                    Data.EventProperty.Value.TriggerEvent();
                }
            }

            /// <inheritdoc />
            public override void FastForward()
            {
            }
        }

Set Animator disapears in Step Inspector if the property is deleted

VR-Builder sometimes does not show the entered Behaviour.
Example: Add "Set Animator Boolean" as Behaviour -> drag Camera into slot -> click FixIt -> IAnimationProperty appears on Cam -> delete IAnimationProperty -> error appears in Console. The behaviour remains in the Json file but is no longer displayed in the Step Inspector. However, it throws exceptions in the process flow.

changes to the UniqueName are not persisted

Hi all, I just noticed that changes to the UniqueName of a ProcessSceneObject are not persisted when it is in a Prefab.

Bug repro:

  1. Create GameObject and drag it to a workflow step (PSO with UniqueName is created).
  2. Create prefab from GameObject.
  3. Change UniqueName -> referencing in workflow still works.
  4. Save everything, close project and open again.
  5. Referencing is broken because the name change was not persisted.

best regards

in Unity 2022.1 WebGL builds fail

Hi there,

I get the following error message when trying to create a WebGL build:

Building Library\Bee\artifacts\WebGL\ManagedStripped failed with output:
C:\Program Files\Unity\Hub\Editor\2022.1.23f1\Editor\Data\il2cpp\build\deploy\UnityLinker.exe --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/WebGLSupport/Managed --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/TextToSpeech-Component/Extensions/Plugins/NAudio --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/PackageCache/[email protected]/Runtime/AOT --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/PackageCache/[email protected]/Runtime/VisualScripting.Flow/Dependencies/NCalc --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/TextToSpeech-Component/Extensions/Plugins/SpeechLib --search-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/Core/Extensions/Plugins/CommandLine/Plugins --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux/Facades --out=Library/Bee/artifacts/WebGL/ManagedStripped --include-link-xml=D:/Projekte/Unity/_temp/2022.1_Clean/Temp/StagingArea/Data/Managed\TypesInScenes.xml --include-link-xml=D:/Projekte/Unity/_temp/2022.1_Clean/Temp/StagingArea/Data/Managed\SerializedTypes.xml --include-link-xml=D:/Projekte/Unity/_temp/2022.1_Clean/Assets\..\Temp\InputSystemLink.xml --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/WebGLSupport/Managed --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/TextToSpeech-Component/Extensions/Plugins/NAudio --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/PackageCache/[email protected]/Runtime/AOT --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Library/PackageCache/[email protected]/Runtime/VisualScripting.Flow/Dependencies/NCalc --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/TextToSpeech-Component/Extensions/Plugins/SpeechLib --include-directory=D:/Projekte/Unity/_temp/2022.1_Clean/Assets/MindPort/VR Builder/Core/Source/Core/Extensions/Plugins/CommandLine/Plugins --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux/Facades --dotnetprofile=unityaot-linux --dotnetruntime=Il2Cpp --architecture=EmscriptenJavaScript --platform=WebGL --use-editor-options --enable-engine-module-stripping --engine-modules-asset-file=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/WebGLSupport/modules.asset --editor-data-file=D:/Projekte/Unity/_temp/2022.1_Clean/Temp/StagingArea/Data/Managed/EditorToUnityLinkerData.json --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/Assembly-CSharp.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/VRBuilder.BasicUI.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/VRBuilder.TextToSpeech.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/VRBuilder.XRInteraction.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/Unity.XR.Interaction.Toolkit.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/Unity.InputSystem.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/UnityEngine.SpatialTracking.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/UnityEngine.UI.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/VRBuilder.BasicInteraction.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/Unity.XR.CoreUtils.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/VRBuilder.Core.dll --include-unity-root-assembly=D:/Projekte/Unity/_temp/2022.1_Clean/Library/Bee/PlayerScriptAssemblies/Unity.Postprocessing.Runtime.dll --print-command-line
Fatal error in Unity CIL Linker
Mono.Linker.LinkerFatalErrorException: ILLink: error IL1005: SpeechLib.ISpeechObjectTokens.GetEnumerator(): Error processing method 'SpeechLib.ISpeechObjectTokens.GetEnumerator()' in assembly 'SpeechLib.dll'
 ---> Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'CustomMarshalers, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null'
   at Unity.IL2CPP.Common.MissingMethodStubber.GetTypeModule(TypeReference type, IEnumerable`1 assemblies)
   at Unity.Linker.Steps.AddUnresolvedStubsStep.MarkAssemblyOfType(UnityLinkContext context, TypeReference type)
   at Unity.Linker.Steps.Marking.UnresolvedStubMarking.HandleUnresolvedType(TypeReference reference)
   at Unity.Linker.Steps.UnityMarkStep.HandleUnresolvedType(TypeReference reference)
   at Mono.Linker.Steps.MarkStep.MarkType(TypeReference reference, DependencyInfo reason, IMemberDefinition sourceLocationMember)
   at Mono.Linker.Steps.MarkStep.MarkMarshalSpec(IMarshalInfoProvider spec, DependencyInfo& reason, IMemberDefinition sourceLocationMember)
   at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method, DependencyInfo& reason)
   at Unity.Linker.Steps.UnityMarkStep.ProcessMethod(MethodDefinition method, DependencyInfo& reason)
   at Mono.Linker.Steps.MarkStep.ProcessQueue()
   --- End of inner exception stack trace ---
   at Mono.Linker.Steps.MarkStep.ProcessQueue()
   at Mono.Linker.Steps.MarkStep.ProcessPrimaryQueue()
   at Mono.Linker.Steps.MarkStep.Process()
   at Mono.Linker.Steps.MarkStep.Process(LinkContext context)
   at Unity.Linker.Steps.UnityMarkStep.Process(LinkContext context)
   at Unity.Linker.UnityPipeline.ProcessStep(LinkContext context, IStep step)
   at Mono.Linker.Pipeline.Process(LinkContext context)
   at Unity.Linker.UnityDriver.UnityRun(Boolean noProfilerAllowed, ILogger customLogger)
   at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling(ILogger customLogger, Boolean noProfilerAllowed)
   at Unity.Linker.UnityDriver.RunDriver()
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

The basis was a new and thus absolutely empty project and the main branch of the VR Builder in the directory "\Assets\MindPort\VR Builder\Core". The same picture arises when using the branch release/2.7.0.

Because "SpeechLib" appears in the error message, out of curiosity I also tried the branch feature/tts-refactor... with success! With this, the WebGL build works.

Since I'm desperate for WebGL builds, I can only continue with these for now, but would be happy if it gets fixed.

Best regards
Rob

Persistant Scene Object References over multiple scenes

I know you're working on a new system to reference scene object in the processes, so I want to describe my case for you to fix it in the refactoring:

Two scenes, one with a process scene object and the other one with a process configuration and a process controller
Referencing the process scene object in the process of the other scene works and the references are kept during runtime as long as both scenes are open (and loaded in the correct order) but as soon as I unload the first scene, all references of the process scene object are deleted and the process is stored without me having control over this.

I want the reference of the process scene object to be kept and restored when reloading the other scene to make scene-overarching processes possible.

[PROCESS_RUNNER] remains after scene unloading

Hello there,
We are working with scenes that are loaded additively. The loading already works, but the unloading of the scene that contains a VR-Builder workflow still puzzles me, because the [PROCESS_RUNNER] (PR) remains after the unloading and thus causes an error.
So concretely: There is an InitScene that does nothing more than load further SceneAddressables. From this, another scene is loaded additively that contains a VR-Builder workflow. But the PR object is not created in the newly loaded scene, but in the InitScene. If the workflow scene is completely unloaded, the PR naturally lacks the other VR Builder components. Do you have an idea how this problem could be solved?

Thank you and best regards

Adding ProcessSceneObject to UnlockedObject more than one time does not get cleaned up correctly

When I manually add a ProcessSceneObject to the UnlockList in more than one Step, the Lock State never gets back to Locked, because the Object is Unlocking, but does not get locked again, when the next Step Contains the ProcessSceneObject in their unlocklist.
This results in the first step to stay in the unlockers List of of LockableProperty.cs forever, resulting in canlock always be false.

video.mp4

Bug: DefaultFileSystem.cs doesn't work in WebGL

I currently verifying if this Framework could work for WebXR and non XR-WebGL and yes it does, with a few modifications. I found out, that it won't run in browser only due to a minimal issue. The DefaultFileSystem.cs does a "File.exists" on the Streaming assets folder.

https://github.com/MindPort-GmbH/VR-Builder/blob/main/Source/Core/Runtime/IO/DefaultFileSystem.cs#L148

It should do a UnitWebRequest.HEAD and later GET to verify the file. I made an implementation of that. Sadly it required me making the Whole ProcessLoading setup async. So that tiny issue turned into a bit of a refactor. I can make you a pull request ready. I wouldn't mind if it does not lands in this Repo, due to that seemingly big refactor. I thought for a day and didn't find a way to make a synchronous request in that moment (it should also not be synchronous) preloading assets like in android won't work either.

I just want to point on the Problem. If anyone runs into the same issue. I would have a fix ready.

Timing Problem with Locked/Unlocked State and EnableObject Behaviour

I noticed that a deactivated Scene Object, which gets Enabled with a "Enable Object by Reference" Behaviour does not get It's Unlocked Events to react in the same Step in a Transition.
I do

protected override void OnEnable() {
     base.OnEnable();
     Locked += OnLocked;
     Unlocked += OnUnlocked;
}

and OnUnlocked does not get called although I see it under the Unlocked Objects in Step Inspector. It does get called however if I activate the Object one Step before.

Process Scene Object is lost when changes are made in the prefab.

If an object contains a Process Scene Object (PSO) and is contained in a prefab, in the Step Inspector the link to this PSO get lost, if the prefab is changed.

When adding and changing objects in the prefab, the link to completely uninvolved PSOs is lost. See the attached video.

PSO.geht.in.Prefab.verloren.webm

Best regards

Feature Request: Dropdown Drawer for Custom Behaviours

I'm searching for an easy way to create a Behaviour MenuItem with data selectable from a specific set of choices (eg. selecting and Item from a List/Dictionary). You already use this kind of drawer for Selecting Tags in the Enable/Disable Objects by Tag Behaviour but this does not seem to be customizable to use with Lists or other values. I've seen the enumdrawer, but I need values to be adjustable at execution time.
Is there already a way to do this? Otherwise this would be a feature request.

ProcessSceneObject missing for deactivated GameObjects on additively loaded scene

Hi there,
if a ProcessSceneObject (PSO) is on a deactivated GameObject, then the PSO is not recognised when loading the scene with the option LoadSceneMode.Additive. Or in other words, disabled GameObjects with VR-Builder PSOs on them are no problem if the scene is loaded directly in the editor or with the option LoadSceneMode.Single. That works. But as soon as the scene is loaded additively from another scene, the well-known MissingEntityException: Could not find scene entity 'XYZ-PSO' comes up for every PSO that is on a disabled GameObject.

tl;dr:
SceneManager.LoadScene(scenename); or SceneManager.LoadSceneAsync(scenename); -> no Problem.
but
SceneManager.LoadScene(scenename, LoadSceneMode.Additive); or SceneManager.LoadSceneAsync(scenename, LoadSceneMode.Additive); -> MissingEntityException on disabled GameObjects.

The same happens if Addressables comes into play. For Example via myAssetReference.LoadSceneAsync(LoadSceneMode.Additive, false);.

Best regards
Rob

ISceneObjects in Scenes without ProcessConfigurator or Runner stays in the SceneObjectRegistry and cannot be checked for null

ISceneObject.gameobject immediately throws a NullReferenceException, even if I just want to check if the gameobject is null. Is there another way to check if the underlying gameobject is valid or do I always have to wrap a try/catch around this?

var allWithTag = RuntimeConfigurator.Configuration.SceneObjectRegistry.GetByTag(GetTag(label).Guid);
foreach (ISceneObject taggedObject in allWithTag) {
    if (taggedObject.GameObject != null) {
        Debug.Log( taggedObject.UniqueName + " is Valid");
    }
    else {
        Debug.LogError( taggedObject.UniqueName + " is invalid");
    }
}

The reason that some objects are invalid in the SceneObjectRegistry is because we have some ProcessSceneObjects living in scenes without a ProcessRunner (weird Unity Multi Scene Loading Timing stuff). I'm not finding a way to Clean the SceneObjectRegistry myself.

All displayed referrences in StepInspector get lost

Hi all,

When switching to another process, all references to objects not contained in the current scene that are displayed in the StepInspector are deleted. They are then also missing in the scene that belongs to the process.

Example:

  1. scene-A contains process-A and in it GameObject-A1 and GameObject-A2 in transitions and behaviours.
  2. scene-B contains process-B and in it GameObject-B1 and GameObject-B2 in transitions and behaviours.
  3. if Process-A is selected in Scene-B in the RuntimeConfiguration and the transitions and behaviour are viewed in the StepInspector, the references to GameObject-A1 and GameObject-A2 disappear.
  4. if Process-A is now opened, the references are now also missing there.

Best regards
Rob

Missing: Localization Package and Exception

Hi,
I pulled the latest version 76c0e1c of the repo but get two different errors. First the using block referes to Localization Package but that is missing in Assets/LEFX/VRBuilder/Core/Source/Extended-UI-Component/Runtime/ProcessController/ProcessControllerMenu.cs
I do solved that by adding the package in the asemdef reference Assets/MindPort/VR Builder/Core/Source/Basic-UI-Component/Runtime/VRBuilder.BasicUI.asmdef

And the second error is:

Assets\LEFX\VRBuilder\Core\Source\Extended-XR-Interaction-Component\Source\Runtime\Properties\UIOutlineProperty.cs(27,31): error CS0246: The type or namespace name 'PropertyConfigurationException' could not be found (are you missing a using directive or an assembly reference?)

Best regards

Process Scene Object uniquename is not compatible with Prefab Overrides System

I noticed that uniquename in ProcessSceneObject is not recognized as an override when changed on a Prefab Instance

To reproduce:

  • Add ProcessSceneObject to a Prefab in PrefabContext
  • Save and Go back to Scene
  • Change uniquename
  • Look in overrides, no changes on ProcessSceneObject are recorded

Interestingly, it works correctly when I duplicate a prefab with a ProcessSceneObject on it. Object get a correct new unique name (with "_1") and the change is recognised as a Prefab override.

Exception when calling ProcessRunner.SkipCurrentChapter()

I get an Exception when I'm calling SkipChapter on the last Chapter of a Process.
On further investigation I see that FastForward() in Chapter.cs generates a null Object on the last List Position of pathToChapterEnd.
If this is intentional, this is weird behaviour. I would expect this function to skip the current chapter and if there are no more chapters, just stops the ProcessRunner like normal.

NullReferenceException: Object reference not set to an instance of an object
VRBuilder.Core.EntityOwners.FoldedEntityCollection.FoldedActivatingProcess`1[TEntity].FastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/EntityOwners/Folded/FoldedActivatingProcess.cs:83)
VRBuilder.Core.CompositeProcess.FastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/CompositeProcess.cs:79)
VRBuilder.Core.LifeCycle.FastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/LifeCycle.cs:136)
VRBuilder.Core.LifeCycle.MarkToFastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/LifeCycle.cs:96)
VRBuilder.Core.Chapter+ActivatingProcess.FastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/Chapter.cs:159)
VRBuilder.Core.LifeCycle.FastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/LifeCycle.cs:136)
VRBuilder.Core.LifeCycle.MarkToFastForward () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/LifeCycle.cs:96)
VRBuilder.Core.ProcessRunner.SkipCurrentChapter () (at Assets/MindPort/VR Builder/Core/Source/Core/Runtime/ProcessRunner.cs:227)
ProcessDebugging.Update () (at Assets/MainApplication/Scripts/VRBuilderExtension/ProcessDebugging.cs:15)

Add references count to SearchableGroupListPopup

The SearchableGroupListPopup is used to assign groups to components in multiple places (ProcessSceneObjectEditor, ProcessSceneReferenceDrawer, HasGuidValidationEditor, LockableObjectsDrawer). Having many Tags in a project will make it hard to find the correct Tag especially if there are multiple scenes using different groups.

Sowing the number of times the group is used could help. Rework the SearchableGroupListPopup, SearchableList and SearchableListItem and the so it looks similar to the group list in the ProcessSceneReferenceDrawer

SearchableGroupListPopup.cs / SearchableList.uxml / SearchableListItem.uxml
image

ProcessSceneReferenceDrawer.cs/ ManageGroupsPanel.uxml
image

Nice to have:

  • Make the Parmaers VisualTreeAsset searchableList, VisualTreeAsset listItem in the constructor of SearchableGroupListPopup optional and and use VisualTreeAsset searchableList = ViewDictionary.LoadAsset(ViewDictionary.EnumType.SearchableList); VisualTreeAsset groupListItem = ViewDictionary.LoadAsset(ViewDictionary.EnumType.SearchableListItem);
    as default values if unassigned.
  • Remove the Parameters from the calls to SearchableGroupListPopup in (ProcessSceneObjectEditor, ProcessSceneReferenceDrawer, HasGuidValidationEditor, LockableObjectsDrawer)

Installation docs

Download and import the VR Builder package from the package manager.

Unless I'm mistaken - this isn't correct. The Package Manager is for UPM packages and VR-Builder is currently an old-style .unitypackage.

Should say something like:

Download the .unitypackage from the Releases page [link] and then go to Assets > Import Package > Custom Package.

(Ideally you'd mention any other prerequsites here as well. Min/max Unity version? Do I need to choose the VR Template or add the VR packages before importing VR-Builder?. Which render pipelines are required/supported? etc.)

And a distinction between "creating a new project with VR-Builder" vs "adding VR-Builder to an existing project would also be useful.

UniqueName (UN) changes while Play

Hello there,
in the attached project, it can be seen at the start of the SampleScene that the UN of "Cube (1)" changes when SceneTwo is loaded additively. This leads to a MissingEntityException. In contrast, SceneTwo can be loaded "single" or opened directly in the editor, in which case the error does not occur. The affected "Cube (1)" is simply a copy of "Cube", which was previously used on the workflow step.
Bug_Repo.7z.zip

Snap zones don't snap correctly objects with attach transform

Objects with attach transform can be oriented incorrectly when snapped to a snap zone.

User Ashes apparently solved this:

The snapzone script has two functions:

  1. ForceSelect
  2. DrawHighlightMesh

These functions are using attachtransform's transform for the snapped object. But there is an assumption here that the AttachTransform is the gameobject having the snapzonepreviewdrawer script. I simply added same condition in both these functions to check if the attachedTransform gameobject is having the snapzonepreviewdrawer script, if not then parent is used. (ofcourse I am assuming as well that the AttachTransform could only be either gameobject with SnapZonePreviewDrawer or direct child that gameobject).

SnapZone.zip

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.