1
This commit is contained in:
@@ -9,9 +9,12 @@ namespace BITKit
|
||||
{
|
||||
private void Start()
|
||||
{
|
||||
foreach (var x in GetComponentsInChildren<SkinnedMeshRenderer>())
|
||||
foreach (var x in GetComponentsInChildren<Renderer>(true))
|
||||
{
|
||||
x.updateWhenOffscreen = true;
|
||||
if (x is SkinnedMeshRenderer skinnedMeshRenderer)
|
||||
{
|
||||
skinnedMeshRenderer.updateWhenOffscreen = true;
|
||||
}
|
||||
x.shadowCastingMode = UnityEngine.Rendering.ShadowCastingMode.Off;
|
||||
}
|
||||
}
|
||||
|
@@ -6,7 +6,7 @@ namespace BITKit
|
||||
public class AutoSetLayer : MonoBehaviour
|
||||
{
|
||||
public int layer;
|
||||
void Start()
|
||||
private void Start()
|
||||
{
|
||||
GetComponentsInChildren<Transform>(true).ForEach(x=>
|
||||
{
|
||||
|
@@ -1,40 +0,0 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using Cysharp.Threading.Tasks;
|
||||
namespace BITKit
|
||||
{
|
||||
public class EffectPlayer : MonoBehaviour
|
||||
{
|
||||
[Header(Constant.Header.Settings)]
|
||||
[SerializeField] float duration;
|
||||
[Header(Constant.Header.Components)]
|
||||
[SerializeField] ParticleSystem[] particleSystems;
|
||||
[SerializeField] Behaviour[] behaviours;
|
||||
void Start()
|
||||
{
|
||||
particleSystems.ForEach(x => x.Stop());
|
||||
behaviours.ForEach(x => x.enabled = false);
|
||||
}
|
||||
public async void Excute()
|
||||
{
|
||||
particleSystems.ForEach(x =>
|
||||
{
|
||||
x.time = 0;
|
||||
x.Play(true);
|
||||
});
|
||||
behaviours.ForEach(x =>
|
||||
{
|
||||
x.enabled = true;
|
||||
});
|
||||
await UniTask.Delay(System.TimeSpan.FromSeconds(duration));
|
||||
if (BehaviourHelper.Actived)
|
||||
{
|
||||
behaviours.ForEach(x =>
|
||||
{
|
||||
x.enabled = false;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,11 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 97e364d5d74ebe94da6abf95c6d42c5b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -31,7 +31,7 @@ namespace BITKit
|
||||
public override VisualElement CreateInspectorGUI()
|
||||
{
|
||||
CreateSubTitle("TextAsset Reader");
|
||||
FillDefaultInspector(root, serializedObject, true);
|
||||
FillDefaultInspector();
|
||||
var excute = root.Create<Button>();
|
||||
|
||||
//excute.bindingPath = nameof(ReadFromTextAsset.Excute);
|
||||
|
@@ -24,7 +24,7 @@ namespace BITKit
|
||||
{
|
||||
public override VisualElement CreateInspectorGUI()
|
||||
{
|
||||
FillDefaultInspector(root, serializedObject, true);
|
||||
FillDefaultInspector();
|
||||
|
||||
var slider = root.Create<Slider>();
|
||||
slider.SetValueWithoutNotify(agent.asset.renderScale);
|
||||
|
@@ -14,6 +14,7 @@ namespace BITKit
|
||||
[SerializeReference,SubclassSelector] private IProvider pingOutput;
|
||||
[SerializeReference,SubclassSelector] private IProvider resolutionOutput;
|
||||
[SerializeReference,SubclassSelector] private IProvider frameRateOutput;
|
||||
[SerializeReference, SubclassSelector] private INetClient clientPing;
|
||||
private readonly DeltaTimer timer = new();
|
||||
private Ping ping;
|
||||
[Header(Constant.Header.InternalVariables)]
|
||||
@@ -28,7 +29,12 @@ namespace BITKit
|
||||
|
||||
if (fpsInterval.AllowUpdate)
|
||||
fpsOutput.Set((string)timer);
|
||||
if (pingOutput is not null)
|
||||
|
||||
if (clientPing is not null)
|
||||
{
|
||||
pingOutput.Set(clientPing.Ping.ToString());
|
||||
}
|
||||
else if (pingOutput is not null)
|
||||
{
|
||||
switch (ping)
|
||||
{
|
||||
|
Reference in New Issue
Block a user