Skip to content

Commit

Permalink
fix: Impeditive bug when building
Browse files Browse the repository at this point in the history
  • Loading branch information
indiegabo committed Dec 4, 2023
1 parent 092533d commit 7fa3353
Show file tree
Hide file tree
Showing 120 changed files with 172 additions and 65 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 1726182683, guid: a4865f1ab4504ed8a368670db22f409c, type: 3}
m_Name: AOTGenerationConfig
m_EditorClassIdentifier:
automateBeforeBuilds: 0
deleteDllAfterBuilds: 1
AutomateForAllAOTPlatforms: 1
automateForPlatforms: 0900000014000000
lastScan: 0
supportSerializedTypes: []

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 188390376, guid: a4865f1ab4504ed8a368670db22f409c, type: 3}
m_Name: ImportSettingsConfig
m_EditorClassIdentifier:
automateBeforeBuild: 1

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Assets/Scenes/SampleScene.unity
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
m_IsActive: 1
--- !u!4 &823617519
Transform:
m_ObjectHideFlags: 0
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements" xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements" noNamespaceSchemaLocation="../../../../../../UIElementsSchema/UIElements.xsd" editor-extension-mode="True">
<Style src="project://database/Packages/com.no-slopes.sprite-animations/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<Style src="project://database/Assets/SpriteAnimations/Editor/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<ui:VisualElement name="header" style="flex-grow: 0; height: 50px; flex-shrink: 0; flex-direction: row; justify-content: space-between; align-items: center; align-self: auto; width: 100%; margin-left: 0; margin-top: 0; margin-right: 0; margin-bottom: 0; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px;">
<ui:VisualElement name="Logo" style="flex-grow: 1; background-image: resource(&apos;Images/logo-min-red-no-bg&apos;); flex-shrink: 0; height: 30px; width: 74px;" />
<ui:VisualElement name="Logo" style="flex-grow: 1; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Images/logo-horizontal-40h.png?fileID=2800000&amp;guid=31ef32b89f86b804e8a9217a8d77542d&amp;type=3#logo-horizontal-40h&apos;); flex-shrink: 0; height: 30px; width: 200px;" />
<ui:VisualElement name="Separator" style="flex-grow: 1; background-image: none; flex-shrink: 0; height: 30px; width: 1px; background-color: rgb(132, 132, 132); margin-right: 5px; margin-left: 5px;" />
<uie:ObjectField label="Sprite Animator" name="animator-selector-field" type="SpriteAnimations.SpriteAnimator, SpriteAnimations" allow-scene-objects="true" style="flex-grow: 1; width: 70%; align-items: center; flex-basis: auto; justify-content: flex-start; flex-direction: row; height: 40px; background-color: rgba(255, 255, 255, 0); color: rgb(243, 243, 243); flex-shrink: 1;" />
<ui:Button text="From Selection" parse-escape-sequences="true" display-tooltip-when-elided="true" name="from-selection-button" tooltip="Selects the Sprite Animator from the current selected GameObject in the inspector" class="primary" style="flex-grow: 1; height: 30px; width: 25%; flex-basis: auto; justify-content: center; color: rgb(255, 255, 255);" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements" xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements" noNamespaceSchemaLocation="../../../../../../UIElementsSchema/UIElements.xsd" editor-extension-mode="False">
<Style src="project://database/Assets/SpriteAnimations/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<Style src="project://database/Assets/SpriteAnimations/Editor/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<ui:VisualElement name="container" style="flex-grow: 0; flex-direction: row; align-items: center; height: 40px; flex-shrink: 0; min-height: 40px; border-bottom-width: 0; border-bottom-color: rgb(82, 82, 82); max-width: 140px; border-left-width: 0; border-right-width: 1px;">
<ui:Label tabindex="-1" text="Label" parse-escape-sequences="true" display-tooltip-when-elided="true" name="label" style="flex-grow: 1; color: rgb(255, 255, 255); font-size: 12px; -unity-text-align: middle-left; justify-content: center; align-items: flex-start; -unity-font-style: bold; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; padding-top: 5px; padding-right: 10px; padding-bottom: 5px; padding-left: 10px;" />
<ui:Button parse-escape-sequences="true" display-tooltip-when-elided="true" name="delete-button" tooltip="Delete this cycle. Irreversible" class="danger" style="margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0; height: 30px; width: 30px; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-right-radius: 5px; border-bottom-left-radius: 5px; align-items: center; justify-content: center;">
<ui:VisualElement name="icon" style="flex-grow: 0; background-image: resource(&apos;Icons/trash-can&apos;); height: 20px; width: 20px;" />
<ui:VisualElement name="icon" style="flex-grow: 0; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Icons/trash-can.png?fileID=2800000&amp;guid=aedac6fd69c936d448d43b8e1b06988d&amp;type=3#trash-can&apos;); height: 20px; width: 20px;" />
</ui:Button>
</ui:VisualElement>
</ui:UXML>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements" xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements" noNamespaceSchemaLocation="../../../../../../UIElementsSchema/UIElements.xsd" editor-extension-mode="True">
<Style src="project://database/Packages/com.no-slopes.sprite-animations/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<Style src="project://database/Assets/SpriteAnimations/Editor/Resources/Styles/AnimationManagerStyles.uss?fileID=7433441132597879392&amp;guid=a292484cf1ed97c4e9a9a18c4bde1c46&amp;type=3#AnimationManagerStyles" />
<ui:VisualElement name="container" class="frame-container" style="flex-grow: 1; flex-direction: row; align-items: center; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px; height: 70px; max-height: 70px; justify-content: space-between;">
<ui:VisualElement name="index-container" class="sa-label" style="flex-grow: 0; flex-shrink: 0; max-width: 20px; margin-right: 5px; margin-left: 5px;">
<ui:Label tabindex="-1" text="1" parse-escape-sequences="true" display-tooltip-when-elided="true" name="index-label" style="color: rgb(255, 255, 255); -unity-font-style: bold;" />
Expand All @@ -17,15 +17,15 @@
</ui:VisualElement>
<ui:VisualElement name="arrows-container" style="flex-grow: 0; height: 50px; width: 50px; align-items: center; justify-content: center;">
<ui:Button parse-escape-sequences="true" display-tooltip-when-elided="true" name="up-button" style="height: 25px; width: 25px; align-items: center; justify-content: center; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0; background-color: rgb(233, 233, 233);">
<ui:VisualElement name="up-icon" style="flex-grow: 0; background-image: resource(&apos;Icons/Navigation Up&apos;); height: 15px; width: 15px; flex-shrink: 0; -unity-background-image-tint-color: rgb(41, 41, 41);" />
<ui:VisualElement name="up-icon" style="flex-grow: 0; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Icons/Navigation%20Up.png?fileID=2800000&amp;guid=f8a7b65e9374fc54db3b8a27749ca4d1&amp;type=3#Navigation Up&apos;); height: 15px; width: 15px; flex-shrink: 0; -unity-background-image-tint-color: rgb(41, 41, 41);" />
</ui:Button>
<ui:Button parse-escape-sequences="true" display-tooltip-when-elided="true" name="down-button" style="height: 25px; width: 25px; align-items: center; justify-content: center; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0; background-color: rgb(233, 233, 233);">
<ui:VisualElement name="down-icon" style="flex-grow: 0; background-image: resource(&apos;Icons/Navigation Down&apos;); height: 15px; width: 15px; flex-shrink: 0; -unity-background-image-tint-color: rgb(41, 41, 41); background-color: rgba(0, 0, 0, 0);" />
<ui:VisualElement name="down-icon" style="flex-grow: 0; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Icons/Navigation%20Down.png?fileID=2800000&amp;guid=3025fbb93ec304242b1ae8c051249b9a&amp;type=3#Navigation Down&apos;); height: 15px; width: 15px; flex-shrink: 0; -unity-background-image-tint-color: rgb(41, 41, 41); background-color: rgba(0, 0, 0, 0);" />
</ui:Button>
</ui:VisualElement>
<ui:VisualElement name="delete-button-container" style="flex-grow: 0; height: 50px; width: 50px; align-items: center; justify-content: center;">
<ui:Button parse-escape-sequences="true" display-tooltip-when-elided="true" name="delete-button" class="danger" style="height: 50px; width: 50px; align-items: center; justify-content: center; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0;">
<ui:VisualElement name="trash-can-icon" style="flex-grow: 0; background-image: resource(&apos;Icons/trash-can&apos;); height: 20px; width: 20px; flex-shrink: 0;" />
<ui:VisualElement name="trash-can-icon" style="flex-grow: 0; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Icons/trash-can.png?fileID=2800000&amp;guid=aedac6fd69c936d448d43b8e1b06988d&amp;type=3#trash-can&apos;); height: 20px; width: 20px; flex-shrink: 0;" />
</ui:Button>
</ui:VisualElement>
</ui:VisualElement>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements" xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements" noNamespaceSchemaLocation="../../../../UIElementsSchema/UIElements.xsd" editor-extension-mode="True">
<Style src="project://database/Assets/SpriteAnimations/Resources/Styles/SpriteAnimatorStyles.uss?fileID=7433441132597879392&amp;guid=339423ba2a8a0c34fafb481770d59829&amp;type=3#SpriteAnimatorStyles" />
<Style src="project://database/Assets/SpriteAnimations/Editor/Resources/Styles/SpriteAnimatorStyles.uss?fileID=7433441132597879392&amp;guid=339423ba2a8a0c34fafb481770d59829&amp;type=3#SpriteAnimatorStyles" />
<ui:VisualElement name="container" style="flex-grow: 1; align-items: stretch; background-color: rgba(26, 0, 0, 0);">
<ui:VisualElement name="field-row" class="row field-row" style="width: 100%; justify-content: flex-start; align-items: stretch; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0;">
<uie:ObjectField label="Script" type="UnityEditor.MonoScript, UnityEditor.CoreModule" name="script-field" binding-path="SpriteAnimator" class="w-100 sa-field" />
</ui:VisualElement>
<ui:VisualElement name="logo-container" class="row field-row" style="width: 100%; justify-content: flex-start; align-items: center; padding-top: 0; padding-right: 5px; padding-bottom: 0; padding-left: 5px; flex-grow: 0; display: none;">
<ui:VisualElement name="logo" style="flex-grow: 0; flex-shrink: 0; align-items: center; justify-content: center; height: 40px; width: 200px; background-image: resource(&apos;Images/logo-horizontal-40h&apos;);" />
<ui:VisualElement name="logo" style="flex-grow: 0; flex-shrink: 0; align-items: center; justify-content: center; height: 40px; width: 200px; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Images/logo-horizontal-40h.png?fileID=2800000&amp;guid=31ef32b89f86b804e8a9217a8d77542d&amp;type=3#logo-horizontal-40h&apos;);" />
</ui:VisualElement>
<ui:VisualElement name="buttons" class="row" style="width: 100%; justify-content: flex-start; align-items: center; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0;">
<ui:Button text="Open Animations Manager" parse-escape-sequences="true" display-tooltip-when-elided="true" name="open-manager-button" class="open-button" style="width: auto; height: 40px; margin-top: 0; margin-right: 5px; margin-bottom: 0; margin-left: 0; color: rgb(243, 243, 243); font-size: 16px; -unity-font-style: bold; -unity-text-align: middle-center; align-items: center; justify-content: center; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-right-radius: 5px; border-bottom-left-radius: 5px; flex-grow: 1;" />
<ui:Button parse-escape-sequences="true" display-tooltip-when-elided="true" name="open-docs-button" tooltip="Open documentation" class="open-docs-button" style="width: 40px; height: 40px; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; color: rgb(243, 243, 243); font-size: 16px; -unity-font-style: bold; -unity-text-align: middle-center; align-items: center; justify-content: center; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-right-radius: 5px; border-bottom-left-radius: 5px; flex-grow: 0; padding-top: 0; padding-right: 0; padding-bottom: 0; padding-left: 0;">
<ui:VisualElement name="docs-icon" style="width: 35px; height: 35px; background-image: resource(&apos;Icons/docs&apos;); align-items: center; justify-content: center;" />
<ui:VisualElement name="docs-icon" style="width: 35px; height: 35px; background-image: url(&apos;project://database/Assets/SpriteAnimations/Assets/Icons/docs.png?fileID=2800000&amp;guid=92d46373e8d588547b5264e65595f9f1&amp;type=3#docs&apos;); align-items: center; justify-content: center;" />
</ui:Button>
</ui:VisualElement>
<ui:VisualElement name="sprite-renderer-row" class="row field-row" style="width: 100%; justify-content: flex-start; align-items: stretch;">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using UnityEngine;
using UnityEditor.PackageManager.UI;
using UnityEngine.UIElements;
using static SpriteAnimations.SpriteAnimation;
using UnityEditor;
using UnityEditor.Playables;
using UnityEditor.UIElements;

namespace SpriteAnimations.Editor
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UIElements;
using SpriteAnimations;

namespace SpriteAnimations.Editor
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using SpriteAnimations;

namespace SpriteAnimations.Editor
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using UnityEngine;
using UnityEngine.UIElements;
using static SpriteAnimations.SpriteAnimation;
using SpriteAnimations;

namespace SpriteAnimations.Editor
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using UnityEngine;
using UnityEngine.UIElements;
using System.Linq;
using static SpriteAnimations.SpriteAnimationWindrose;
using SpriteAnimations;

namespace SpriteAnimations.Editor
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
using System;
using System.Collections.Generic;
using System.Linq;
using UnityEditor;
using UnityEditor.UIElements;
using UnityEngine;
Expand Down
19 changes: 19 additions & 0 deletions Assets/SpriteAnimations/Editor/SpriteAnimations.Editor.asmdef
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"name": "SpriteAnimations.Editor",
"rootNamespace": "",
"references": [
"GUID:6528b5066ff785c4980e366b93b15e2d",
"GUID:2c573e6b271651846a79655161004c5b"
],
"includePlatforms": [
"Editor"
],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
using UnityEngine;
using System;

#if UNITY_EDITOR
using UnityEditor;
using SpriteAnimations.Editor;
#endif
// #if UNITY_EDITOR
// using UnityEditor;
// using SpriteAnimations.Editor;
// #endif

namespace SpriteAnimations
{
Expand All @@ -16,25 +16,25 @@ public abstract class SpriteAnimation : ScriptableObject
{
#region Menus

#if UNITY_EDITOR
[MenuItem("Assets/Sprite Animations/Manage Animation")]
private static void ManageAnimation()
{
SpriteAnimation selectedAnimation = Selection.activeObject as SpriteAnimation;
if (!selectedAnimation)
{
Logger.LogError($"Selected object is not an {nameof(SpriteAnimation)}");
return;
}

SingleManagerWindow.OpenEditorWindow(selectedAnimation);
}
[MenuItem("Assets/Sprite Animations/Manage Animation", true)]
static bool CheckIfMainMethodIsValid()
{
return Selection.activeObject is SpriteAnimation;
}
#endif
// #if UNITY_EDITOR
// [MenuItem("Assets/Sprite Animations/Manage Animation")]
// private static void ManageAnimation()
// {
// SpriteAnimation selectedAnimation = Selection.activeObject as SpriteAnimation;
// if (!selectedAnimation)
// {
// Logger.LogError($"Selected object is not an {nameof(SpriteAnimation)}");
// return;
// }

// SingleManagerWindow.OpenEditorWindow(selectedAnimation);
// }
// [MenuItem("Assets/Sprite Animations/Manage Animation", true)]
// static bool CheckIfMainMethodIsValid()
// {
// return Selection.activeObject is SpriteAnimation;
// }
// #endif

#endregion

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@

using System;
using System.Collections.Generic;
using Codice.Client.BaseCommands.Download;
using UnityEngine;

namespace SpriteAnimations
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
{
"name": "SpriteAnimations",
"name": "SpriteAnimations.Runtime",
"rootNamespace": "",
"references": [
"GUID:2c573e6b271651846a79655161004c5b"
],
"references": [],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 7fa3353

Please sign in to comment.