OneShotOneKill/Assets/Script/Table/Tables/table_projectile.cs

37 lines
2.0 KiB
C#
Raw Normal View History

2026-01-12 06:30:09 +00:00
using CodeStage.AntiCheat.ObscuredTypes;
using Newtonsoft.Json;
using System.Collections.Generic;
public class ProjectileTableData : TableDataBase
{
public string s_ProjectilePrefabs, s_HitEffect, s_ProjectileSpeed, s_ProjectileLife;
ObscuredInt _ProjectileID; public int n_ProjectileID { get { return _ProjectileID; } set { _ProjectileID = value; _ProjectileID.RandomizeCryptoKey(); } }
ObscuredFloat _AttackBounceLimit; public float f_AttackBounceLimit { get { return _AttackBounceLimit; } set { _AttackBounceLimit = value; _AttackBounceLimit.RandomizeCryptoKey(); } }
ObscuredFloat _ProjectileDistance; public float f_ProjectileDistance { get { return _ProjectileDistance; } set { _ProjectileDistance = value; _ProjectileDistance.RandomizeCryptoKey(); } }
ObscuredFloat _KnockbackDistance; public float f_KnockbackDistance { get { return _KnockbackDistance; } set { _KnockbackDistance = value; _KnockbackDistance.RandomizeCryptoKey(); } }
ObscuredFloat _StunTime; public float f_StunTime { get { return _StunTime; } set { _StunTime = value; _StunTime.RandomizeCryptoKey(); } }
ObscuredFloat _ExplosionRange; public float f_ExplosionRange { get { return _ExplosionRange; } set { _ExplosionRange = value; _ExplosionRange.RandomizeCryptoKey(); } }
ObscuredFloat _ExplosionDamage; public float f_ExplosionDamage { get { return _ExplosionDamage; } set { _ExplosionDamage = value; _ExplosionDamage.RandomizeCryptoKey(); } }
}
public class table_projectile : table_base
{
public static table_projectile Ins;
List<ProjectileTableData> tableDatas;
protected override void Awake()
{
Ins = this;
base.Awake();
}
protected override void Start()
{
tableDatas = JsonConvert.DeserializeObject<List<ProjectileTableData>>(json_last);
base.Start();
}
public List<ProjectileTableData> Get_DataList() { return tableDatas; }
public ProjectileTableData Get_Data(int id) { return tableDatas.Find(f => f.n_ProjectileID == id); }
}