17 lines
370 B
C#
17 lines
370 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using System.Linq;
|
|
|
|
public class RAWTachometer : Tachometer {
|
|
|
|
public float delta = 1f;
|
|
|
|
public override float GetSpeed() {
|
|
int c = impulses.Count(i => i > Time.time - delta);
|
|
Debug.Log("I ru speed Count: " + impulses.Count() + " c " + c);
|
|
return c;
|
|
}
|
|
|
|
}
|