Updated build.
This commit is contained in:
parent
64c2fd0944
commit
9d966d6c53
41 changed files with 283 additions and 133 deletions
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 13c149b5679992c4aad3260153c5f7ae
|
guid: 568c9281a6a80bf4aad73063ed400461
|
||||||
folderAsset: yes
|
folderAsset: yes
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 327c0f7ed6330514791026c2d1ba5a5c
|
guid: 68bab2be1de7761428f5a7732c611ab3
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: cfa76c0e71adc0f439476432ffe37fa3
|
guid: be5bd7e34f38dec44842ae69d0740dd5
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,14 +1,15 @@
|
||||||
using System.Collections.Generic;
|
using UnityEngine;
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
using UnityEngine;
|
using System.Collections.Generic;
|
||||||
using UnityEditor.SceneManagement;
|
|
||||||
|
|
||||||
namespace GitMerge {
|
namespace GitMerge
|
||||||
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The window that lets you perform merges on scenes and prefabs.
|
/// The window that lets you perform merges on scenes and prefabs.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class GitMergeWindow : EditorWindow {
|
public class GitMergeWindow : EditorWindow
|
||||||
private VCS vcs = new VCSGit ();
|
{
|
||||||
|
private VCS vcs = new VCSGit();
|
||||||
|
|
||||||
//EditorPrefs keys for settings
|
//EditorPrefs keys for settings
|
||||||
private const string epAutomerge = "GitMerge_automerge";
|
private const string epAutomerge = "GitMerge_automerge";
|
||||||
|
@ -21,8 +22,10 @@ namespace GitMerge {
|
||||||
//The MergeManager that has the actual merging logic
|
//The MergeManager that has the actual merging logic
|
||||||
private MergeManager manager;
|
private MergeManager manager;
|
||||||
|
|
||||||
public bool mergeInProgress {
|
public bool mergeInProgress
|
||||||
get {
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
return manager != null;
|
return manager != null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,67 +33,83 @@ namespace GitMerge {
|
||||||
private Vector2 scrollPosition = Vector2.zero;
|
private Vector2 scrollPosition = Vector2.zero;
|
||||||
private int tab = 0;
|
private int tab = 0;
|
||||||
|
|
||||||
[MenuItem ("Window/GitMerge")]
|
|
||||||
static void OpenEditor () {
|
[MenuItem("Window/GitMerge")]
|
||||||
var window = EditorWindow.GetWindow (typeof (GitMergeWindow), false, "GitMerge");
|
static void OpenEditor()
|
||||||
|
{
|
||||||
|
var window = EditorWindow.GetWindow(typeof(GitMergeWindow), false, "GitMerge");
|
||||||
//In case we're merging and the scene becomes edited,
|
//In case we're merging and the scene becomes edited,
|
||||||
//the shown SerializedProperties should be repainted
|
//the shown SerializedProperties should be repainted
|
||||||
window.autoRepaintOnSceneChange = true;
|
window.autoRepaintOnSceneChange = true;
|
||||||
window.minSize = new Vector2 (500, 100);
|
window.minSize = new Vector2(500, 100);
|
||||||
}
|
}
|
||||||
|
|
||||||
void OnEnable () {
|
void OnEnable()
|
||||||
LoadSettings ();
|
{
|
||||||
|
LoadSettings();
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void LoadSettings () {
|
private static void LoadSettings()
|
||||||
if (EditorPrefs.HasKey (epAutomerge)) {
|
{
|
||||||
automerge = EditorPrefs.GetBool (epAutomerge);
|
if(EditorPrefs.HasKey(epAutomerge))
|
||||||
} else {
|
{
|
||||||
|
automerge = EditorPrefs.GetBool(epAutomerge);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
automerge = true;
|
automerge = true;
|
||||||
}
|
}
|
||||||
if (EditorPrefs.HasKey (epAutofocus)) {
|
if(EditorPrefs.HasKey(epAutofocus))
|
||||||
autofocus = EditorPrefs.GetBool (epAutofocus);
|
{
|
||||||
} else {
|
autofocus = EditorPrefs.GetBool(epAutofocus);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
autofocus = true;
|
autofocus = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void OnHierarchyChange () {
|
void OnHierarchyChange()
|
||||||
|
{
|
||||||
//Repaint if we changed the scene
|
//Repaint if we changed the scene
|
||||||
this.Repaint ();
|
this.Repaint();
|
||||||
}
|
}
|
||||||
|
|
||||||
//Always check for editor state changes, and abort the active merge process if needed
|
//Always check for editor state changes, and abort the active merge process if needed
|
||||||
void Update () {
|
void Update()
|
||||||
if (MergeAction.inMergePhase &&
|
{
|
||||||
(EditorApplication.isCompiling ||
|
if(MergeAction.inMergePhase
|
||||||
EditorApplication.isPlayingOrWillChangePlaymode)) {
|
&& (EditorApplication.isCompiling
|
||||||
ShowNotification (new GUIContent ("Aborting merge due to editor state change."));
|
|| EditorApplication.isPlayingOrWillChangePlaymode))
|
||||||
AbortMerge ();
|
{
|
||||||
|
ShowNotification(new GUIContent("Aborting merge due to editor state change."));
|
||||||
|
AbortMerge();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void AbortMerge () {
|
private void AbortMerge()
|
||||||
manager.AbortMerge ();
|
{
|
||||||
|
manager.AbortMerge();
|
||||||
manager = null;
|
manager = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
void OnGUI () {
|
void OnGUI()
|
||||||
Resources.DrawLogo ();
|
{
|
||||||
DrawTabButtons ();
|
Resources.DrawLogo();
|
||||||
|
DrawTabButtons();
|
||||||
|
|
||||||
switch (tab) {
|
switch(tab)
|
||||||
|
{
|
||||||
case 0:
|
case 0:
|
||||||
OnGUISceneTab ();
|
OnGUISceneTab();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 1:
|
case 1:
|
||||||
OnGUIPrefabTab ();
|
OnGUIPrefabTab();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
OnGUISettingsTab ();
|
OnGUISettingsTab();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -98,75 +117,91 @@ namespace GitMerge {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Tab that offers scene merging.
|
/// Tab that offers scene merging.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void OnGUISceneTab () {
|
private void OnGUISceneTab()
|
||||||
GUILayout.Label ("Open Scene: " + EditorSceneManager.GetActiveScene().ToString());
|
{
|
||||||
if (EditorSceneManager.GetActiveScene().ToString() != "" &&
|
GUILayout.Label("Open Scene: " + EditorApplication.currentScene);
|
||||||
!mergeInProgress &&
|
if(EditorApplication.currentScene != ""
|
||||||
GUILayout.Button ("Start merging this scene", GUILayout.Height (80))) {
|
&& !mergeInProgress
|
||||||
var mm = new MergeManagerScene (this, vcs);
|
&& GUILayout.Button("Start merging this scene", GUILayout.Height(80)))
|
||||||
if (mm.InitializeMerge ()) {
|
{
|
||||||
|
var mm = new MergeManagerScene(this, vcs);
|
||||||
|
if(mm.InitializeMerge())
|
||||||
|
{
|
||||||
manager = mm;
|
manager = mm;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DisplayMergeProcess ();
|
DisplayMergeProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Tab that offers prefab merging.
|
/// Tab that offers prefab merging.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void OnGUIPrefabTab () {
|
private void OnGUIPrefabTab()
|
||||||
|
{
|
||||||
GameObject prefab;
|
GameObject prefab;
|
||||||
if (!mergeInProgress) {
|
if(!mergeInProgress)
|
||||||
GUILayout.Label ("Drag your prefab here to start merging:");
|
{
|
||||||
if (prefab = EditorGUILayout.ObjectField (null, typeof (GameObject), false, GUILayout.Height (60)) as GameObject) {
|
GUILayout.Label("Drag your prefab here to start merging:");
|
||||||
var mm = new MergeManagerPrefab (this, vcs);
|
if(prefab = EditorGUILayout.ObjectField(null, typeof(GameObject), false, GUILayout.Height(60)) as GameObject)
|
||||||
if (mm.InitializeMerge (prefab)) {
|
{
|
||||||
|
var mm = new MergeManagerPrefab(this, vcs);
|
||||||
|
if(mm.InitializeMerge(prefab))
|
||||||
|
{
|
||||||
manager = mm;
|
manager = mm;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DisplayMergeProcess ();
|
DisplayMergeProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Tab that offers various settings for the tool.
|
/// Tab that offers various settings for the tool.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void OnGUISettingsTab () {
|
private void OnGUISettingsTab()
|
||||||
var vcsPath = vcs.exe ();
|
{
|
||||||
var vcsPathNew = EditorGUILayout.TextField ("Path to git.exe", vcsPath);
|
var vcsPath = vcs.exe();
|
||||||
if (vcsPath != vcsPathNew) {
|
var vcsPathNew = EditorGUILayout.TextField("Path to git.exe", vcsPath);
|
||||||
vcs.SetPath (vcsPathNew);
|
if(vcsPath != vcsPathNew)
|
||||||
|
{
|
||||||
|
vcs.SetPath(vcsPathNew);
|
||||||
}
|
}
|
||||||
|
|
||||||
var amNew = EditorGUILayout.Toggle ("Automerge", automerge);
|
var amNew = EditorGUILayout.Toggle("Automerge", automerge);
|
||||||
if (automerge != amNew) {
|
if(automerge != amNew)
|
||||||
|
{
|
||||||
automerge = amNew;
|
automerge = amNew;
|
||||||
EditorPrefs.SetBool (epAutomerge, automerge);
|
EditorPrefs.SetBool(epAutomerge, automerge);
|
||||||
}
|
}
|
||||||
GUILayout.Label ("(Automerge new/deleted GameObjects/Components upon merge start)");
|
GUILayout.Label("(Automerge new/deleted GameObjects/Components upon merge start)");
|
||||||
|
|
||||||
var afNew = EditorGUILayout.Toggle ("Auto Highlight", autofocus);
|
var afNew = EditorGUILayout.Toggle("Auto Highlight", autofocus);
|
||||||
if (autofocus != afNew) {
|
if(autofocus != afNew)
|
||||||
|
{
|
||||||
autofocus = afNew;
|
autofocus = afNew;
|
||||||
EditorPrefs.SetBool (epAutofocus, autofocus);
|
EditorPrefs.SetBool(epAutofocus, autofocus);
|
||||||
}
|
}
|
||||||
GUILayout.Label ("(Highlight GameObjects when applying a MergeAction to it)");
|
GUILayout.Label("(Highlight GameObjects when applying a MergeAction to it)");
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// If no merge is in progress, draws the buttons to switch between tabs.
|
/// If no merge is in progress, draws the buttons to switch between tabs.
|
||||||
/// Otherwise, draws the "abort merge" button.
|
/// Otherwise, draws the "abort merge" button.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void DrawTabButtons () {
|
private void DrawTabButtons()
|
||||||
if (!mergeInProgress) {
|
{
|
||||||
|
if(!mergeInProgress)
|
||||||
|
{
|
||||||
string[] tabs = { "Merge Scene", "Merge Prefab", "Settings" };
|
string[] tabs = { "Merge Scene", "Merge Prefab", "Settings" };
|
||||||
tab = GUI.SelectionGrid (new Rect (72, 36, 300, 22), tab, tabs, 3);
|
tab = GUI.SelectionGrid(new Rect(72, 36, 300, 22), tab, tabs, 3);
|
||||||
} else {
|
}
|
||||||
GUI.backgroundColor = new Color (1, 0.4f, 0.4f, 1);
|
else
|
||||||
if (GUI.Button (new Rect (72, 36, 300, 22), "Abort merge")) {
|
{
|
||||||
manager.AbortMerge ();
|
GUI.backgroundColor = new Color(1,0.4f,0.4f,1);
|
||||||
|
if(GUI.Button(new Rect(72, 36, 300, 22), "Abort merge"))
|
||||||
|
{
|
||||||
|
manager.AbortMerge();
|
||||||
manager = null;
|
manager = null;
|
||||||
}
|
}
|
||||||
GUI.backgroundColor = Color.white;
|
GUI.backgroundColor = Color.white;
|
||||||
|
@ -176,15 +211,18 @@ namespace GitMerge {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Displays all MergeActions and the "apply merge" button if a merge is in progress.
|
/// Displays all MergeActions and the "apply merge" button if a merge is in progress.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void DisplayMergeProcess () {
|
private void DisplayMergeProcess()
|
||||||
if (mergeInProgress) {
|
{
|
||||||
var done = DisplayMergeActions ();
|
if(mergeInProgress)
|
||||||
GUILayout.BeginHorizontal ();
|
{
|
||||||
if (done && GUILayout.Button ("Apply merge")) {
|
var done = DisplayMergeActions();
|
||||||
manager.CompleteMerge ();
|
GUILayout.BeginHorizontal();
|
||||||
|
if(done && GUILayout.Button("Apply merge"))
|
||||||
|
{
|
||||||
|
manager.CompleteMerge();
|
||||||
manager = null;
|
manager = null;
|
||||||
}
|
}
|
||||||
GUILayout.EndHorizontal ();
|
GUILayout.EndHorizontal();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -192,23 +230,25 @@ namespace GitMerge {
|
||||||
/// Displays all GameObjectMergeActions.
|
/// Displays all GameObjectMergeActions.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>True, if all MergeActions are flagged as "merged".</returns>
|
/// <returns>True, if all MergeActions are flagged as "merged".</returns>
|
||||||
private bool DisplayMergeActions () {
|
private bool DisplayMergeActions()
|
||||||
scrollPosition = GUILayout.BeginScrollView (scrollPosition, false, true);
|
{
|
||||||
GUILayout.BeginVertical (GUILayout.MinWidth (480));
|
scrollPosition = GUILayout.BeginScrollView(scrollPosition, false, true);
|
||||||
|
GUILayout.BeginVertical(GUILayout.MinWidth(480));
|
||||||
|
|
||||||
var textColor = GUI.skin.label.normal.textColor;
|
var textColor = GUI.skin.label.normal.textColor;
|
||||||
GUI.skin.label.normal.textColor = Color.black;
|
GUI.skin.label.normal.textColor = Color.black;
|
||||||
|
|
||||||
var done = true;
|
var done = true;
|
||||||
foreach (var actions in manager.allMergeActions) {
|
foreach(var actions in manager.allMergeActions)
|
||||||
actions.OnGUI ();
|
{
|
||||||
|
actions.OnGUI();
|
||||||
done = done && actions.merged;
|
done = done && actions.merged;
|
||||||
}
|
}
|
||||||
|
|
||||||
GUI.skin.label.normal.textColor = textColor;
|
GUI.skin.label.normal.textColor = textColor;
|
||||||
|
|
||||||
GUILayout.EndVertical ();
|
GUILayout.EndVertical();
|
||||||
GUILayout.EndScrollView ();
|
GUILayout.EndScrollView();
|
||||||
return done;
|
return done;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: aaa504546605b3a479405bee3c11cd04
|
guid: 8ca3e35ac9a2e3640bec16f50af9c42a
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: d9583c639208c1e49b6cc77e128f7ccb
|
guid: c6e29f4ad68b5a54ba8e83efb7d98046
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 9a327ed62a5572a459e54869df134f42
|
guid: bbd2a69f96bdd9d47b5c3d94c8ccb1ed
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 6414ac2f8bebc8b4bb33597977332630
|
guid: a82f3c36b51c6fa4e9a0d6d6718795f7
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 627176a0f25069f46919f6e3489eb8c3
|
guid: 346280e81446cbe4f85ee020862ba3b9
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: f94b44d1572d0d14ea949190ef678a3a
|
guid: d1d6ecf91d1e97047ade8fc0492fc526
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 6c13706c0946b934a95c41957ce759f5
|
guid: 00e7127d975fc44408bcac4e3c13936c
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: fb60feef4712bcc4a9f2d266c289a2d7
|
guid: 5d21fb8a14162d34a8ee3b8f8af1d7e8
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 29139dc665a42db45b67df932a04c810
|
guid: 60bcec554a1d62e4e83a7487e41a92a2
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: b7759967878514e4aace05e726704e8f
|
guid: 80715767d8cb6214d9b3a6dff034c2c3
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
using UnityEditor.SceneManagement;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace GitMerge
|
namespace GitMerge
|
||||||
|
@ -22,7 +21,7 @@ namespace GitMerge
|
||||||
|
|
||||||
public bool InitializeMerge(GameObject prefab)
|
public bool InitializeMerge(GameObject prefab)
|
||||||
{
|
{
|
||||||
if(!EditorSceneManager.SaveCurrentModifiedScenesIfUserWantsTo())
|
if(!EditorApplication.SaveCurrentSceneIfUserWantsTo())
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -39,8 +38,8 @@ namespace GitMerge
|
||||||
ourPrefab = prefab;
|
ourPrefab = prefab;
|
||||||
|
|
||||||
//Open a new Scene that will only display the prefab
|
//Open a new Scene that will only display the prefab
|
||||||
previouslyOpenedScene = EditorSceneManager.GetActiveScene().ToString();
|
previouslyOpenedScene = EditorApplication.currentScene;
|
||||||
EditorSceneManager.NewScene(NewSceneSetup.DefaultGameObjects);
|
EditorApplication.NewScene();
|
||||||
|
|
||||||
//make the new scene empty
|
//make the new scene empty
|
||||||
Object.DestroyImmediate(Camera.main.gameObject);
|
Object.DestroyImmediate(Camera.main.gameObject);
|
||||||
|
@ -142,7 +141,7 @@ namespace GitMerge
|
||||||
{
|
{
|
||||||
if(!string.IsNullOrEmpty(previouslyOpenedScene))
|
if(!string.IsNullOrEmpty(previouslyOpenedScene))
|
||||||
{
|
{
|
||||||
EditorSceneManager.OpenScene(previouslyOpenedScene);
|
EditorApplication.OpenScene(previouslyOpenedScene);
|
||||||
previouslyOpenedScene = "";
|
previouslyOpenedScene = "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: f8db1a549c01168468790b325c85f3c1
|
guid: 154ff8bdf17036848a35b8a200bf45e5
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEditor;
|
using UnityEditor;
|
||||||
using UnityEditor.SceneManagement;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace GitMerge
|
namespace GitMerge
|
||||||
|
@ -18,19 +17,19 @@ namespace GitMerge
|
||||||
isMergingScene = true;
|
isMergingScene = true;
|
||||||
|
|
||||||
//Ask if the scene should be saved, because...
|
//Ask if the scene should be saved, because...
|
||||||
if(!EditorSceneManager.SaveCurrentModifiedScenesIfUserWantsTo())
|
if(!EditorApplication.SaveCurrentSceneIfUserWantsTo())
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
//...we are reloading it to prevent objects from not having a scene id.
|
//...we are reloading it to prevent objects from not having a scene id.
|
||||||
EditorSceneManager.OpenScene(EditorSceneManager.GetActiveScene().ToString());
|
EditorApplication.OpenScene(EditorApplication.currentScene);
|
||||||
|
|
||||||
MergeAction.inMergePhase = false;
|
MergeAction.inMergePhase = false;
|
||||||
|
|
||||||
ObjectDictionaries.Clear();
|
ObjectDictionaries.Clear();
|
||||||
|
|
||||||
//checkout "their" version
|
//checkout "their" version
|
||||||
GetTheirVersionOf(EditorSceneManager.GetActiveScene().ToString());
|
GetTheirVersionOf(EditorApplication.currentScene);
|
||||||
AssetDatabase.Refresh();
|
AssetDatabase.Refresh();
|
||||||
|
|
||||||
//find all of "our" objects
|
//find all of "our" objects
|
||||||
|
@ -38,7 +37,7 @@ namespace GitMerge
|
||||||
ObjectDictionaries.SetAsOurObjects(ourObjects);
|
ObjectDictionaries.SetAsOurObjects(ourObjects);
|
||||||
|
|
||||||
//add "their" objects
|
//add "their" objects
|
||||||
EditorSceneManager.OpenScene(theirFilename);
|
EditorApplication.OpenSceneAdditive(theirFilename);
|
||||||
|
|
||||||
//delete scene file
|
//delete scene file
|
||||||
AssetDatabase.DeleteAsset(theirFilename);
|
AssetDatabase.DeleteAsset(theirFilename);
|
||||||
|
@ -92,7 +91,7 @@ namespace GitMerge
|
||||||
|
|
||||||
ObjectDictionaries.DestroyTheirObjects();
|
ObjectDictionaries.DestroyTheirObjects();
|
||||||
ObjectDictionaries.Clear();
|
ObjectDictionaries.Clear();
|
||||||
EditorSceneManager.SaveOpenScenes();
|
EditorApplication.SaveScene();
|
||||||
|
|
||||||
allMergeActions = null;
|
allMergeActions = null;
|
||||||
|
|
||||||
|
@ -113,7 +112,7 @@ namespace GitMerge
|
||||||
base.AbortMerge();
|
base.AbortMerge();
|
||||||
|
|
||||||
//Save scene
|
//Save scene
|
||||||
EditorSceneManager.SaveOpenScenes();
|
EditorApplication.SaveScene();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 2143b0a739488bb4698c51777c4863fc
|
guid: 15e732f908761074987126952222faa7
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: e2d4344037c6c7c4ca962a1e4037b6fe
|
guid: 2dde64c2ebfea53468c6d06c7d0802bd
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 0ee0303a3ea013b4eaa610e764182b3a
|
guid: 90fb84eaa7f623c4c81ec21f78804ee6
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 03c68a8557b31bf45a299c6f3be7bf10
|
guid: 12a1bb317bccb8e4791515aa6ca12c28
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 67422f4e577bb17409644dcfe6bf75c8
|
guid: 4056f2dd015271e478c0ff4f7f3b2aed
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 718f5b21123c36448b66c0e2ec52031c
|
guid: 23f2a7881b9942048858266fe7cc0fa1
|
||||||
folderAsset: yes
|
folderAsset: yes
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: be9ca0515e031fb4c86b12a6b9ba2410
|
guid: 265831ac550945e4fbba33c677fc8018
|
||||||
TextureImporter:
|
TextureImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
mipmaps:
|
mipmaps:
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: e18ddd74b76685d46a46ca56a3f6380f
|
guid: ce87b5c26f3841f43a96efe7c6b7ec39
|
||||||
TextureImporter:
|
TextureImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
mipmaps:
|
mipmaps:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: a88667aa2092d4b46aa3ad92e778e994
|
guid: 08135f006ce433a4b95bbc49016c702b
|
||||||
NativeFormatImporter:
|
NativeFormatImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: fcbbf2375e3889c4398c97d289eab2ac
|
guid: 86dc4aff09a75a647a736bd7fc08b4ae
|
||||||
TextScriptImporter:
|
TextScriptImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: e055732d013ee174fb764659113f8ea9
|
guid: a489445661855994fa048f02ad7eb1f1
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: a08026e2ac14c0446a85134863995fd0
|
guid: 23e588a0022bd644590704132285a0f6
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 339de811f43309449914e314f1366850
|
guid: ea9f8c789b59fba48af44e74f77c760d
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: b4b1187c33991394a9c66710b250f24b
|
guid: 0cc14050eed7ab3478e52a04b43b67d5
|
||||||
MonoImporter:
|
MonoImporter:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
defaultReferences: []
|
defaultReferences: []
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 785798e4822ed284b8daad687e2df88d
|
guid: 83edaaf63d75acd4a836d454a304b434
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: b364bc2946220bf428dccb47dbcee795
|
guid: 49256941daeb6e1448dfc77257024ee5
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
userData:
|
userData:
|
||||||
|
|
54
Angels and Demons/Logs/Packages-Update.log
Normal file
54
Angels and Demons/Logs/Packages-Update.log
Normal file
|
@ -0,0 +1,54 @@
|
||||||
|
|
||||||
|
=== Sat May 18 17:09:32 2019
|
||||||
|
|
||||||
|
Packages were changed.
|
||||||
|
Update Mode: updateDependencies
|
||||||
|
|
||||||
|
The following packages were added:
|
||||||
|
com.unity.2d.tilemap@1.0.0
|
||||||
|
com.unity.analytics@3.2.2
|
||||||
|
com.unity.purchasing@2.0.6
|
||||||
|
com.unity.ads@2.0.8
|
||||||
|
com.unity.textmeshpro@1.3.0
|
||||||
|
com.unity.package-manager-ui@2.2.0
|
||||||
|
com.unity.collab-proxy@1.2.16
|
||||||
|
com.unity.ext.nunit@1.0.0
|
||||||
|
com.unity.test-framework@1.0.12
|
||||||
|
com.unity.timeline@1.0.0
|
||||||
|
com.unity.2d.sprite@1.0.0
|
||||||
|
com.unity.ide.vscode@1.0.4
|
||||||
|
com.unity.ide.visualstudio@1.0.5
|
||||||
|
com.unity.ide.rider@1.0.4
|
||||||
|
com.unity.modules.ai@1.0.0
|
||||||
|
com.unity.modules.animation@1.0.0
|
||||||
|
com.unity.modules.androidjni@1.0.0
|
||||||
|
com.unity.modules.assetbundle@1.0.0
|
||||||
|
com.unity.modules.audio@1.0.0
|
||||||
|
com.unity.modules.cloth@1.0.0
|
||||||
|
com.unity.modules.director@1.0.0
|
||||||
|
com.unity.modules.imageconversion@1.0.0
|
||||||
|
com.unity.modules.imgui@1.0.0
|
||||||
|
com.unity.modules.jsonserialize@1.0.0
|
||||||
|
com.unity.modules.particlesystem@1.0.0
|
||||||
|
com.unity.modules.physics@1.0.0
|
||||||
|
com.unity.modules.physics2d@1.0.0
|
||||||
|
com.unity.modules.screencapture@1.0.0
|
||||||
|
com.unity.modules.terrain@1.0.0
|
||||||
|
com.unity.modules.terrainphysics@1.0.0
|
||||||
|
com.unity.modules.tilemap@1.0.0
|
||||||
|
com.unity.modules.ui@1.0.0
|
||||||
|
com.unity.modules.uielements@1.0.0
|
||||||
|
com.unity.modules.umbra@1.0.0
|
||||||
|
com.unity.modules.unityanalytics@1.0.0
|
||||||
|
com.unity.modules.unitywebrequest@1.0.0
|
||||||
|
com.unity.modules.unitywebrequestassetbundle@1.0.0
|
||||||
|
com.unity.modules.unitywebrequestaudio@1.0.0
|
||||||
|
com.unity.modules.unitywebrequesttexture@1.0.0
|
||||||
|
com.unity.modules.unitywebrequestwww@1.0.0
|
||||||
|
com.unity.modules.vehicles@1.0.0
|
||||||
|
com.unity.modules.video@1.0.0
|
||||||
|
com.unity.modules.vr@1.0.0
|
||||||
|
com.unity.modules.wind@1.0.0
|
||||||
|
com.unity.modules.xr@1.0.0
|
||||||
|
com.unity.multiplayer-hlapi@1.0.2
|
||||||
|
com.unity.xr.legacyinputhelpers@2.0.2
|
|
@ -1,4 +1,51 @@
|
||||||
{
|
{
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"com.unity.2d.sprite": "1.0.0",
|
||||||
|
"com.unity.2d.tilemap": "1.0.0",
|
||||||
|
"com.unity.ads": "2.0.8",
|
||||||
|
"com.unity.analytics": "3.2.2",
|
||||||
|
"com.unity.collab-proxy": "1.2.16",
|
||||||
|
"com.unity.ext.nunit": "1.0.0",
|
||||||
|
"com.unity.ide.rider": "1.0.4",
|
||||||
|
"com.unity.ide.visualstudio": "1.0.5",
|
||||||
|
"com.unity.ide.vscode": "1.0.4",
|
||||||
|
"com.unity.multiplayer-hlapi": "1.0.2",
|
||||||
|
"com.unity.package-manager-ui": "2.2.0",
|
||||||
|
"com.unity.purchasing": "2.0.6",
|
||||||
|
"com.unity.test-framework": "1.0.12",
|
||||||
|
"com.unity.textmeshpro": "1.3.0",
|
||||||
|
"com.unity.timeline": "1.0.0",
|
||||||
|
"com.unity.xr.legacyinputhelpers": "2.0.2",
|
||||||
|
"com.unity.modules.ai": "1.0.0",
|
||||||
|
"com.unity.modules.androidjni": "1.0.0",
|
||||||
|
"com.unity.modules.animation": "1.0.0",
|
||||||
|
"com.unity.modules.assetbundle": "1.0.0",
|
||||||
|
"com.unity.modules.audio": "1.0.0",
|
||||||
|
"com.unity.modules.cloth": "1.0.0",
|
||||||
|
"com.unity.modules.director": "1.0.0",
|
||||||
|
"com.unity.modules.imageconversion": "1.0.0",
|
||||||
|
"com.unity.modules.imgui": "1.0.0",
|
||||||
|
"com.unity.modules.jsonserialize": "1.0.0",
|
||||||
|
"com.unity.modules.particlesystem": "1.0.0",
|
||||||
|
"com.unity.modules.physics": "1.0.0",
|
||||||
|
"com.unity.modules.physics2d": "1.0.0",
|
||||||
|
"com.unity.modules.screencapture": "1.0.0",
|
||||||
|
"com.unity.modules.terrain": "1.0.0",
|
||||||
|
"com.unity.modules.terrainphysics": "1.0.0",
|
||||||
|
"com.unity.modules.tilemap": "1.0.0",
|
||||||
|
"com.unity.modules.ui": "1.0.0",
|
||||||
|
"com.unity.modules.uielements": "1.0.0",
|
||||||
|
"com.unity.modules.umbra": "1.0.0",
|
||||||
|
"com.unity.modules.unityanalytics": "1.0.0",
|
||||||
|
"com.unity.modules.unitywebrequest": "1.0.0",
|
||||||
|
"com.unity.modules.unitywebrequestassetbundle": "1.0.0",
|
||||||
|
"com.unity.modules.unitywebrequestaudio": "1.0.0",
|
||||||
|
"com.unity.modules.unitywebrequesttexture": "1.0.0",
|
||||||
|
"com.unity.modules.unitywebrequestwww": "1.0.0",
|
||||||
|
"com.unity.modules.vehicles": "1.0.0",
|
||||||
|
"com.unity.modules.video": "1.0.0",
|
||||||
|
"com.unity.modules.vr": "1.0.0",
|
||||||
|
"com.unity.modules.wind": "1.0.0",
|
||||||
|
"com.unity.modules.xr": "1.0.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
Binary file not shown.
|
@ -1 +1,2 @@
|
||||||
m_EditorVersion: 2018.1.0f2
|
m_EditorVersion: 2019.3.0a2
|
||||||
|
m_EditorVersionWithRevision: 2019.3.0a2 (fa7740529556)
|
||||||
|
|
Binary file not shown.
BIN
Angels and Demons/ProjectSettings/VFXManager.asset
Normal file
BIN
Angels and Demons/ProjectSettings/VFXManager.asset
Normal file
Binary file not shown.
10
Angels and Demons/ProjectSettings/XRSettings.asset
Normal file
10
Angels and Demons/ProjectSettings/XRSettings.asset
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"m_SettingKeys": [
|
||||||
|
"VR Device Disabled",
|
||||||
|
"VR Device User Alert"
|
||||||
|
],
|
||||||
|
"m_SettingValues": [
|
||||||
|
"False",
|
||||||
|
"False"
|
||||||
|
]
|
||||||
|
}
|
Reference in a new issue