This repository has been archived on 2026-01-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
URRobot/Assets/Asset Cleaner/Data/PrevClick.cs
jmaniuvc 282fcfe688 main
2025-05-29 09:51:58 +09:00

18 lines
468 B
C#

using UnityEngine;
namespace Asset_Cleaner {
public struct PrevClick {
const float DoubleClickTime = 0.5f;
Object _target;
float _timeClicked;
public PrevClick(Object target) {
_target = target;
_timeClicked = Time.realtimeSinceStartup;
}
public bool IsDoubleClick(Object o) {
return _target == o && Time.realtimeSinceStartup - _timeClicked < DoubleClickTime;
}
}
}