Skip to content
This repository has been archived by the owner on Apr 8, 2024. It is now read-only.

Commit

Permalink
ci: release trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonTheSourcerer authored Feb 5, 2021
2 parents 6e7e8dd + b8ccbdd commit ebe66d9
Show file tree
Hide file tree
Showing 50 changed files with 937 additions and 174 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions .Documentation/articles/images/xr/availableRigs.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions .Documentation/articles/images/xr/interaction-rig-loader.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions .Documentation/articles/images/xr/xr-samples.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions .Documentation/articles/images/xr/xr-simulator.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# XR Setup
# Project Setup

## VR Headset SDK
## XR Setup

You need to add an SDK package for every VR headset you want to use with your application.
You need to add an SDK package for every HMD you want to use with your application.

### XR Plugin Management

If you use an Oculus headset, go to `Unity > Edit > Project Settings... > XR Plug-in Management`. Press `Install XR Plug-in Management`. Let Unity import assets and click `Install Oculus XR Plugin`.

Expand All @@ -12,6 +14,25 @@ If you use Windows Mixed Reality, go to `Unity > Edit > Project Settings... > XR

![XR Plugin Management](../images/xr-plugin-management.png "XR Plug-in Management settings window")

### OpenVR (legacy)

If you use an HTC Vive, Valve Index, or similar headsets, then there is no SteamVR/OpenVR XR Plugin yet. Unity Technologies works on it and will release it soon. For now, go to `Unity > Edit > Project Settings... > Player > XR Settings > Deprecated Settings`. Toggle `Enable Virtual Reality Supported`. Let Unity import assets. Click on the `+` button under the `Virtual Reality SDKs` and add `OpenVR` to the list.

![XR Deprecated Settings](../images/xr-deprecated.png "XR Settings window (deprecated)")

> This configuration is deprecated and only available in Unity 2019 LTS
## Input System

The Innoactive Creator is compatible with the `legacy input system` and the `new input system`, but certain Unity features might work differently according to the chosen configuration.

The active input system can be adjusted as follows:

1. Open **Edit** > **Project Settings**
2. Select the **Player** tab in the opening window.
3. Open the **Other Settings** section and scroll down to **Active Input Handling**.
4. Set it to your desired input system.

![XR Deprecated Settings](../images/project-setup/active-input-handling-setting.png "XR Settings window (deprecated)")

> If `both` is selected, the `legacy input system` and the `new input system` will be active.
14 changes: 10 additions & 4 deletions .Documentation/articles/toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
- name: Unity Setup
href: setup-guides/02-unity-setup.md
- name: Project Setup
href: setup-guides/03-xr-setup.md
href: setup-guides/03-project-setup.md
- name: Innoactive Creator for Designers
href: innoactive-creator/index.md
items:
Expand All @@ -46,8 +46,6 @@
href: innoactive-creator/default-behaviors.md
- name: Default Conditions
href: innoactive-creator/default-conditions.md
- name: Snap Zones
href: innoactive-creator/snap-zones.md
- name: Suspending Interactions
href: innoactive-creator/suspending-interactions.md
- name: Examples
Expand Down Expand Up @@ -92,7 +90,15 @@
href: pro/01-validation.md
- name: Advanced Spectator
href: pro/02-advanced-spectator.md

- name: XR Interaction Toolkit
href: xr/index.md
items:
- name: Overview
href: xr/index.md
- name: XR Device Simulator
href: xr/xr-device-simulator.md
- name: Snap Zones
href: xr/snap-zones.md
- name: Transition Guide to v2.0 for Developers
href: transition-to-v2.0/index.md
items:
Expand Down
25 changes: 25 additions & 0 deletions .Documentation/articles/xr/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# XR Interaction Toolkit

The Innoactive Creator is bundled with the [`XR Interaction Component`](https://github.com/Innoactive/XR-Interaction-Component) an interaction implementation based on the [`XR Interaction Toolkit`](https://blogs.unity3d.com/2019/12/17/xr-interaction-toolkit-preview-package-is-here/), an XR interaction framework made by Unity and defined as follows:

> The XR Interaction Toolkit package is a high-level, component-based, interaction system for creating VR and AR experiences. It provides a framework that makes 3D and UI interactions available from Unity input events. The core of this system is a set of base Interactor and Interactable components, and an Interaction Manager that ties these two types of components together. It also contains helper components that you can use to extend functionality for drawing visuals and hooking in your own interaction events.
The XR Interaction Toolkit is used along with the [`XR Plugin Management`](https://docs.unity3d.com/Packages/com.unity.xr.management@3.2/manual/index.html) to enable XR content creators to build applications in an abstract layer without dealing with hardware or software specifics, speeding up the development process. In other words, an XR application is developed once and can be exported to as many end hardware as desired.

## General Topics

The following articles will help you understand how the `XR Interaction Component` works:

- XR Rigs (coming soon)
- `Locomotion` (comming soon)
- [XR Device Simulator](./xr-device-simulator.md)

## Interactables

- `Interactable Objects` (comming soon)
- `Interactable Highlighter` (comming soon)

## Interactors

- `XR Controllers`(comming soon)
- [Snap Zones](./snap-zones.md)
58 changes: 58 additions & 0 deletions .Documentation/articles/xr/xr-device-simulator.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# XR Device Simulator

The [XR Device Simulator](https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@0.10/manual/samples.html#xr-device-simulator) is a tool bundled within `XR Interaction Toolkit` starting from its version `1.0.0-pre.2`. It handles mouse and keyboard input from the user and uses it to drive simulated XR controllers and an XR head-mounted display (HMD).

The XR Device Simulator is only supported when using [Actions](https://docs.unity3d.com/Packages/com.unity.inputsystem@1.0/manual/Actions.html), for which the [new input system](https://blogs.unity3d.com/2019/10/14/introducing-the-new-input-system/) is required.

[![Open the Step Inspector](../images/xr/xr-simulator.gif "XR Device Simulator.")](../images/xr/xr-simulator.gif)

## Prerequisites

- The `new input system` must be enabled.

> [How to set up the new input system.](../setup-guides/03-project-setup.md#input-system)
- The `XR Interaction Toolkit`package must be at least at version `1.0.0-pre.2`.

> [How to change a package version.](https://docs.unity3d.com/Manual/upm-ui-update.html)
- Make sure you have imported the `Default Input Actions` and `XR Device Simulator` [samples](https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@0.10/manual/samples.html).

![Delete Obsolete Rig](../images/xr/xr-samples.png "XR Interaction Toolkit Samples")


## Initial Setup

If in your scene you are missing the `[INTERACTION_RIG_LOADER]` then you need to [Setup the Training Configuration](../innoactive-creator/training-configuration.md#setup-the-training-configuration-in-the-current-scene), you can do this by selecting in the toolbar `Innoactive` > `Setup Training Scene`.

[![Open the Step Inspector](../images/xr/how-to-set-up-the-xr-simulator.gif "How to set up the XR Device Simulator.")](../images/xr/how-to-set-up-the-xr-simulator.gif)

The `[INTERACTION_RIG_LOADER]` contains a list of available XR rigs, including an `XR Simulator`. The `[INTERACTION_RIG_LOADER]` will spawn the first available rig going from top to bottom of the list, the list can be rearranged.

![Delete Obsolete Rig](../images/xr/interaction-rig-loader.png "A pop-up allows you to delete the obsolete `[XR Setup]` object from the scene")

> In order to try out the simulator, make sure to position the XR Simulator at the top of the list.
## Simulator Controls (Input Actions)

The XR Device Simulator uses a sample [Input Action Set](https://docs.unity3d.com/Packages/com.unity.xr.interaction.toolkit@0.10/manual/samples.html#input-actions-asset-1), you can find and [edit](https://docs.unity3d.com/Packages/com.unity.inputsystem@1.0/manual/ActionAssets.html#editing-input-action-assets) it in the `Assets\Samples\XR Interaction Toolkit\[version]\XR Device Simulator Controls` folder.

The `XR Device Simulator Controls` is divided in two `Action Maps`:

- **Main**

Actions like `Manipulate Left Hand`, `Manipulate Right Hand`, `Manipulate Head`, and `Toggle Coursor Lock` can be found here.

![Delete Obsolete Rig](../images/xr/xr-simulator-controls-main.png "A pop-up allows you to delete the obsolete `[XR Setup]` object from the scene")

- **Input Controls**

Actions like `Grip`, `Trigger`, `Primary Button`, `Primary Touch`, and `Menu`can be found here.

![Delete Obsolete Rig](../images/xr/xr-simulator-controls-input-controls.png "A pop-up allows you to delete the obsolete `[XR Setup]` object from the scene")

## Disclaimer

The `XR Device Simulator` is a tool developed and maintained by `Unity Technologies`, it is not distributed with the `Innoactive Creator`.

Do you have more questions? Let us know about your experience in our [community](https://innoactive.io/creator/community?tab=posts).
16 changes: 1 addition & 15 deletions .azure-documentation-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,18 +76,4 @@ jobs:
targetPath: 'Creator/.Documentation/_site'
artifact: 'documentation'
publishLocation: 'pipeline'
displayName: Store Documentation

- task: FtpUpload@2
displayName: "Uploading to server and publish"
condition: or(eq(variables['Build.SourceBranchName'], 'master'), ${{ parameters.release }})
inputs:
credentialsOption: 'serviceEndpoint'
serverEndpoint: 'FTP Documentation Server'
rootDirectory: 'Creator/.Documentation/_site'
filePatterns: '**'
remoteDirectory: 'training.hub.innoactive.de/docs/v$(Version)/'
clean: false
cleanContents: false
preservePaths: true
trustSSL: false
displayName: Store Documentation
10 changes: 7 additions & 3 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,18 @@ See more about [Pull Requests](https://help.github.com/en/github/collaborating-w

## Maintainers

Meet out maintainers:
Meet our maintainers:

[<img alt="aleksei-korolev" src="https://github.com/aleksei-korolev.png" width="110">](https://github.com/aleksei-korolev) | [<img alt="SimonTheSourcerer" src="https://github.com/SimonTheSourcerer.png" width="110">](https://github.com/SimonTheSourcerer) |
[<img alt="SimonTheSourcerer" src="https://github.com/SimonTheSourcerer.png" width="110">](https://github.com/SimonTheSourcerer) | [<img alt="Tomwim" src="https://github.com/tomwim.png" width="110">](https://github.com/Tomwim)
:---: | :---: |
[Aleksei Korolev](mailto:aleksei.korolev@innoactive.de) | [Simon L](mailto:simon.lerch@innoactive.de)
[Simon L](mailto:simon.lerch@innoactive.de) | [Thomas W](mailto:thomas.wimmer@innoactive.de)


Maintainers are responsible for this repository and its community.

### Former Maintainers
[Aleksei Korolev](https://github.com/aleksei-korolev)

## Coding Conventions

By encouraging coding conventions we ensure:
Expand Down
2 changes: 1 addition & 1 deletion Editor/Configuration/DefaultEditorConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public virtual string AllowedMenuItemsSettingsAssetPath
/// <inheritdoc />
public virtual ICourseSerializer Serializer
{
get { return new NewtonsoftJsonCourseSerializer(); }
get { return new ImprovedNewtonsoftJsonCourseSerializer(); }
}

/// <inheritdoc />
Expand Down
45 changes: 19 additions & 26 deletions Editor/DefaultEditingStrategy.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
using System.Linq;
using UnityEditor;
using UnityEngine;
using Innoactive.Creator.Core;
Expand All @@ -15,30 +16,19 @@ internal class DefaultEditingStrategy : IEditingStrategy
private StepWindow stepWindow;

public ICourse CurrentCourse { get; protected set; }
public IChapter CurrentChapter { get; protected set; }

/// <inheritdoc/>
public void HandleNewCourseWindow(CourseWindow window)
{
if (courseWindow != null && courseWindow != window)
{
courseWindow.Close();
}

courseWindow = window;

courseWindow.SetCourse(CurrentCourse);
}

/// <inheritdoc/>
public void HandleNewStepWindow(StepWindow window)
{
if (stepWindow != null && stepWindow != window)
{
stepWindow.Close();
}

stepWindow = window;

if (courseWindow == null || courseWindow.Equals(null))
{
HandleCurrentStepChanged(null);
Expand Down Expand Up @@ -66,21 +56,11 @@ public void HandleCourseWindowClosed(CourseWindow window)
{
CourseAssetManager.Save(CurrentCourse);
}

if (stepWindow != null)
{
stepWindow.Close();
}
}

/// <inheritdoc/>
public void HandleStepWindowClosed(StepWindow window)
{
if (stepWindow != window)
{
return;
}

if (CurrentCourse != null)
{
CourseAssetManager.Save(CurrentCourse);
Expand All @@ -97,6 +77,10 @@ public void HandleStartEditingCourse()
courseWindow = EditorWindow.GetWindow<CourseWindow>();
courseWindow.minSize = new Vector2(400f, 100f);
}
else
{
courseWindow.Focus();
}
}

/// <inheritdoc/>
Expand All @@ -114,6 +98,7 @@ public void HandleCurrentCourseChanged(string courseName)
private void LoadCourse(ICourse newCourse)
{
CurrentCourse = newCourse;
CurrentChapter = null;

if (newCourse != null && EditorConfigurator.Instance.Validation.IsAllowedToValidate())
{
Expand All @@ -123,11 +108,14 @@ private void LoadCourse(ICourse newCourse)
if (courseWindow != null)
{
courseWindow.SetCourse(CurrentCourse);
if (stepWindow != null)
{
stepWindow.SetStep(courseWindow.GetChapter()?.ChapterMetadata.LastSelectedStep);
}
}

if (stepWindow != null)
else if (stepWindow != null)
{
stepWindow.SetStep(courseWindow.GetChapter()?.ChapterMetadata.LastSelectedStep);
stepWindow.SetStep(null);
}
}

Expand All @@ -149,7 +137,7 @@ public void HandleCurrentStepChanged(IStep step)
{
if (stepWindow != null)
{
if (step != null && EditorConfigurator.Instance.Validation.IsAllowedToValidate())
if (step != null && EditorConfigurator.Instance.Validation.IsAllowedToValidate())
{
EditorConfigurator.Instance.Validation.Validate(step.Data, CurrentCourse);
}
Expand All @@ -166,6 +154,11 @@ public void HandleStartEditingStep()
}
}

public void HandleCurrentChapterChanged(IChapter chapter)
{
CurrentChapter = chapter;
}

/// <inheritdoc/>
public void HandleProjectIsGoingToUnload()
{
Expand Down
13 changes: 13 additions & 0 deletions Editor/GlobalEditorHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,14 @@ internal static ICourse GetCurrentCourse()
return strategy.CurrentCourse;
}

/// <summary>
/// Returns the current active chapter, can be null.
/// </summary>
internal static IChapter GetCurrentChapter()
{
return strategy.CurrentChapter;
}

/// <summary>
/// Notifies selected <see cref="IEditingStrategy"/> when a new <see cref="CourseWindow"/> was just opened.
/// </summary>
Expand Down Expand Up @@ -98,6 +106,11 @@ internal static void SetCurrentCourse(string courseName)
strategy.HandleCurrentCourseChanged(courseName);
}

internal static void SetCurrentChapter(IChapter chapter)
{
strategy.HandleCurrentChapterChanged(chapter);
}

/// <summary>
/// Notifies selected <see cref="IEditingStrategy"/> when user wants to start working on the current course.
/// </summary>
Expand Down
Loading

0 comments on commit ebe66d9

Please sign in to comment.