Anti-Cheat Toolkit  2023.2.6
Multi-purpose anti-cheat solution for Unity Engine
ICodeHashGenerator Interface Reference

Inherited by CodeHashGenerator.

Public Member Functions

ICodeHashGenerator Generate (int maxThreads=1)
 
Task< HashGeneratorResultGenerateAsync (int maxThreads=1)
 

Properties

HashGeneratorResult LastResult [get]
 
bool IsBusy [get]
 

Detailed Description

CodeHashGenerator interface to make it easier to use it through the Instance.

Member Function Documentation

◆ Generate()

ICodeHashGenerator Generate ( int  maxThreads = 1)

Call to start current runtime code hash generation. Automatically adds instance to the scene if necessary.

Parameters
maxThreadsThreads to use while hashing files. Use Environment.ProcessorCount to use all cores.

Implemented in CodeHashGenerator.

◆ GenerateAsync()

Task<HashGeneratorResult> GenerateAsync ( int  maxThreads = 1)

Awaitable version of Generate(). Allows awaiting for the generation result.

Parameters
maxThreadsThreads to use while hashing files. Use Environment.ProcessorCount to use all cores.

Implemented in CodeHashGenerator.

Property Documentation

◆ LastResult

HashGeneratorResult LastResult
get

Stores previously calculated result. Can be null if Generate() wasn't called yet or if it was called but calculation is still in process.

See also
IsBusy

◆ IsBusy

bool IsBusy
get

Indicates if hash generation is currently in process.