CiaoSDKAntiCheat
Anti-Cheat consists of three detectors, all configurable in Ciao Games → Settings.
The detectors flag suspicious activity so you can decide how to respond. For example, a time difference could indicate clock manipulation, but it could also be caused by a poor connection or temporary loss of internet.
Evaluate the signal before reporting a user as a cheater.
Detectors
| Detector | Description |
|---|---|
InternetCheck | Checks internet availability. |
InstallSourceCheck | Checks install sources on Android devices. Not 100% accurate - treat as a signal, not proof. |
TimeCheck | Checks device time against internet time. |
Detector Settings
Each detector is configured independently in the CiaoSDK Settings asset.
| Setting | Description |
|---|---|
<DetectorName>RunCheckOn | Controls when the detector runs. Values: Never, OnInitialize, OnLevelComplete (runs when CiaoSDK.SendLevelCompleted is called), OnRecurringInterval (runs every <DetectorName>IntervalSeconds). |
<DetectorName>IntervalSeconds | Used when RunCheckOn = OnRecurringInterval. Defines the check interval in seconds. |
TimeCheckThresholdSeconds | Used by TimeCheck. If the difference between internet time and device time exceeds this threshold, OnSuspiciousActivityDetected fires. |
LegitimateInstallers | Used by InstallSourceCheck (Android). A list of accepted install sources. |
timeServerUrl | Server URL used to check time. www.example.com is used as a globally-accessible default. Change it to your own endpoint if needed. |
Methods
| Method | Description |
|---|---|
ValidateTime(Action<bool> callback) | Checks device time against server time. Callback receives true if the check passed. |
GetInternetTime(Action<DateTime> callback) | Returns the current server time via callback. |
Events
| Event | Description |
|---|---|
OnNoInternet | Fires when the device loses connectivity. |
OnInternetRestored | Fires when connectivity returns. |
OnSuspiciousActivityDetected | Fires when suspicious activity is detected. Subscribe before calling CiaoSDK.Initialize. |
CiaoSDKAntiCheat.OnSuspiciousActivityDetected += args =>
CiaoSDK.SendCheaterDetected(args);
CiaoSDK.Initialize(consent);Updated 1 day ago
Did this page help you?
