2020-09-08 04:10:07 -04:00
|
|
|
|
using UnityEngine;
|
2020-07-19 21:36:57 -04:00
|
|
|
|
|
|
|
|
|
public class IronBlock : MonoBehaviour
|
|
|
|
|
{
|
|
|
|
|
public string ID = "unassigned";
|
|
|
|
|
public string creationMethod;
|
|
|
|
|
public int address;
|
|
|
|
|
private float updateTick;
|
|
|
|
|
|
2020-09-03 03:09:26 -04:00
|
|
|
|
// Called once per frame by unity engine
|
|
|
|
|
public void Update()
|
2020-07-19 21:36:57 -04:00
|
|
|
|
{
|
|
|
|
|
updateTick += 1 * Time.deltaTime;
|
|
|
|
|
if (updateTick > 0.5f + (address * 0.001f))
|
|
|
|
|
{
|
|
|
|
|
GetComponent<PhysicsHandler>().UpdatePhysics();
|
|
|
|
|
updateTick = 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|