0.3.0: Added Int/String to Animator parameter and tag popup

This commit is contained in:
Anders Ejlersen 2021-10-16 01:50:06 +02:00
parent 36a8310a01
commit 4ddb552bad
14 changed files with 298 additions and 1 deletions

View file

@ -0,0 +1,15 @@
using System;
namespace Module.Inspector
{
[AttributeUsage(AttributeTargets.Field, AllowMultiple = false, Inherited = true)]
public sealed class IntToAnimatorParameter : DrawerPropertyAttribute
{
public readonly string animatorFieldName;
public IntToAnimatorParameter(string animatorFieldName)
{
this.animatorFieldName = animatorFieldName;
}
}
}

View file

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 390dd165549248e8aaf20ee8a056d94f
timeCreated: 1634338764

View file

@ -0,0 +1,15 @@
using System;
namespace Module.Inspector
{
[AttributeUsage(AttributeTargets.Field, AllowMultiple = false, Inherited = true)]
public sealed class StringToAnimatorParameter : DrawerPropertyAttribute
{
public readonly string animatorFieldName;
public StringToAnimatorParameter(string animatorFieldName)
{
this.animatorFieldName = animatorFieldName;
}
}
}

View file

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 4927d6b177be0ba43bf91a28a0259d41
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

14
Runtime/Drawers/Tag.cs Normal file
View file

@ -0,0 +1,14 @@
using System;
using UnityEngine.Scripting;
namespace Module.Inspector
{
[AttributeUsage(AttributeTargets.Field, AllowMultiple = false, Inherited = true)]
public sealed class Tag : DrawerPropertyAttribute
{
[Preserve]
public Tag()
{
}
}
}

View file

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: a1f818608011429d93967fa5701cac48
timeCreated: 1634339466