|
|
|
|
using System;
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
|
|
namespace FX
|
|
|
|
|
{
|
|
|
|
|
// Token: 0x02000747 RID: 1863
|
|
|
|
|
public class FX_PositionAdd : MonoBehaviour
|
|
|
|
|
{
|
|
|
|
|
// Token: 0x06002FF7 RID: 12279 RVA: 0x00100DE4 File Offset: 0x00100DE4
|
|
|
|
|
private void Start()
|
|
|
|
|
{
|
|
|
|
|
this.localPosition_ = this.transform_.localPosition;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Token: 0x06002FF8 RID: 12280 RVA: 0x00100DF8 File Offset: 0x00100DF8
|
|
|
|
|
private void OnEnable()
|
|
|
|
|
{
|
|
|
|
|
this.transform_ = base.transform;
|
|
|
|
|
this.transform_.localPosition = this.localPosition_;
|
|
|
|
|
this.posStartRandom_Rate = new Vector3(UnityEngine.Random.Range(-1f, 1f), UnityEngine.Random.Range(-1f, 1f), UnityEngine.Random.Range(-1f, 1f));
|
|
|
|
|
this.transform_.Translate(this.posStart[0] + this.posStartRandom[0] * this.posStartRandom_Rate[0], this.posStart[1] + this.posStartRandom[1] * this.posStartRandom_Rate[1], this.posStart[2] + this.posStartRandom[2] * this.posStartRandom_Rate[2]);
|
|
|
|
|
this.posAddRandom_Rate = new Vector3(UnityEngine.Random.Range(-1f, 1f), UnityEngine.Random.Range(-1f, 1f), UnityEngine.Random.Range(-1f, 1f));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Token: 0x06002FF9 RID: 12281 RVA: 0x00100F10 File Offset: 0x00100F10
|
|
|
|
|
private void Update()
|
|
|
|
|
{
|
|
|
|
|
this.transform_.Translate(this.posAdd[0] + this.posAddRandom[0] * this.posAddRandom_Rate[0] * 60f * Time.deltaTime, this.posAdd[1] + this.posAddRandom[1] * this.posAddRandom_Rate[1] * 60f * Time.deltaTime, this.posAdd[2] + this.posAddRandom[2] * this.posAddRandom_Rate[2] * 60f * Time.deltaTime);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558A RID: 21898
|
|
|
|
|
[SerializeField]
|
|
|
|
|
private Vector3 posStart = new Vector3(0f, 0f, 0f);
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558B RID: 21899
|
|
|
|
|
[SerializeField]
|
|
|
|
|
private Vector3 posStartRandom = new Vector3(0f, 0f, 0f);
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558C RID: 21900
|
|
|
|
|
[SerializeField]
|
|
|
|
|
private Vector3 posAdd = new Vector3(0f, 0f, 0f);
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558D RID: 21901
|
|
|
|
|
[SerializeField]
|
|
|
|
|
private Vector3 posAddRandom = new Vector3(0f, 0f, 0f);
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558E RID: 21902
|
|
|
|
|
private Vector3 posStartRandom_Rate = default(Vector3);
|
|
|
|
|
|
|
|
|
|
// Token: 0x0400558F RID: 21903
|
|
|
|
|
private Vector3 posAddRandom_Rate = default(Vector3);
|
|
|
|
|
|
|
|
|
|
// Token: 0x04005590 RID: 21904
|
|
|
|
|
private Transform transform_;
|
|
|
|
|
|
|
|
|
|
// Token: 0x04005591 RID: 21905
|
|
|
|
|
private Vector3 localPosition_;
|
|
|
|
|
}
|
|
|
|
|
}
|