added animation package and made small changes

This commit is contained in:
Lorenzo
2022-12-06 17:46:58 +01:00
parent 564ec183d7
commit 3f3323449f
3440 changed files with 12815908 additions and 344 deletions

View File

@@ -0,0 +1,166 @@
// =================================
// Namespaces.
// =================================
using UnityEngine;
using UnityEngine.UI;
//using System.Collections;
// =================================
// Define namespace.
// =================================
namespace MirzaBeig
{
namespace ParticleSystems
{
namespace Demos
{
// =================================
// Classes.
// =================================
//[ExecuteInEditMode]
[System.Serializable]
public class DemoManager_XPTitles : MonoBehaviour
{
// =================================
// Nested classes and structures.
// =================================
// ...
// =================================
// Variables.
// =================================
// ...
LoopingParticleSystemsManager list;
public Text particleCountText;
public Text currentParticleSystemText;
Rotator cameraRotator;
// =================================
// Functions.
// =================================
// ...
void Awake()
{
(list = GetComponent<LoopingParticleSystemsManager>()).Init();
}
// ...
void Start()
{
cameraRotator = Camera.main.GetComponentInParent<Rotator>();
updateCurrentParticleSystemNameText();
}
// ...
public void ToggleRotation()
{
cameraRotator.enabled = (!cameraRotator.enabled);
}
public void ResetRotation()
{
cameraRotator.transform.eulerAngles = Vector3.zero;
}
// ...
void Update()
{
// Scroll through systems.
if (Input.GetAxis("Mouse ScrollWheel") < 0)
{
Next();
}
else if (Input.GetAxis("Mouse ScrollWheel") > 0)
{
previous();
}
//// Activate/deactive camera rotation.
//if (Input.GetKeyDown(KeyCode.Space))
//{
// ToggleRotation();
//}
//// Reset camera rotator transform rotation.
//if (Input.GetKeyDown(KeyCode.R))
//{
// ResetRotation();
//}
}
// ...
void LateUpdate()
{
if (particleCountText)
{
// Update particle count display.
particleCountText.text = "PARTICLE COUNT: ";
particleCountText.text += list.GetParticleCount().ToString();
}
}
// ...
public void Next()
{
list.Next();
updateCurrentParticleSystemNameText();
}
public void previous()
{
list.Previous();
updateCurrentParticleSystemNameText();
}
// ...
void updateCurrentParticleSystemNameText()
{
if (currentParticleSystemText)
{
currentParticleSystemText.text = list.GetCurrentPrefabName(true);
}
}
// =================================
// End functions.
// =================================
}
// =================================
// End namespace.
// =================================
}
}
}
// =================================
// --END-- //
// =================================

View File

@@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 9090909671ae66940aff35f3416fb26e
timeCreated: 1458196122
licenseType: Store
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: