public class Verificator extends Object
Modifier and Type | Field and Description |
---|---|
static int |
VERIFICATION_VERSION |
Constructor and Description |
---|
Verificator(NegativityPlayer np,
String asker)
Create a new verificator for all cheats
Cheat are filtered after, specially for those which don't have verif feature
|
Verificator(NegativityPlayer np,
String asker,
Map<CheatKeys,VerifData> cheats,
List<String> messages,
int version,
Version playerVersion)
Create a new verificator
|
Verificator(NegativityPlayer np,
String asker,
Set<Cheat> list,
boolean forceGiven)
Create a new verificator for given cheats
|
Modifier and Type | Method and Description |
---|---|
void |
generateMessage()
Generate un-translated message of all cheat which was in detection
The summary is available thanks to
getMessages() |
String |
getAsker()
Get asker name
|
Map<CheatKeys,VerifData> |
getCheats()
Get all cheats with their verif data
|
List<String> |
getMessages()
Get all generated message
|
NegativityPlayer |
getNegativityPlayer()
Get the NegativityPlayer of the verified player
|
UUID |
getPlayerId()
Get the UUID of the verified player
|
Version |
getPlayerVersion()
Get player version
|
Optional<VerifData> |
getVerifData(Cheat c)
Get the verif data of a cheat
(Can be null)
|
int |
getVersion()
Get version of the verif
|
void |
save()
Save the message
If
getMessages() is empty, a new summary will be made before saving |
public static final int VERIFICATION_VERSION
public Verificator(NegativityPlayer np, String asker)
np
- the negativity player of the verified playerasker
- the name of the player which ask for verifpublic Verificator(NegativityPlayer np, String asker, Set<Cheat> list, boolean forceGiven)
np
- the negativity player of the verified playerasker
- the name of the player which ask for veriflist
- all cheat which have to be verified, filtered if they have verification availableforceGiven
- true if filter cheat according to they have verifpublic Verificator(NegativityPlayer np, String asker, Map<CheatKeys,VerifData> cheats, List<String> messages, int version, Version playerVersion)
np
- the negativity player of the verified playerasker
- the name of the player which ask for verifcheats
- all detected cheat with a new VerifData
(or empty if it's a saved one)messages
- all previous generated message is it's saved (or empty)version
- the version of verificationplayerVersion
- the player versionpublic NegativityPlayer getNegativityPlayer()
public UUID getPlayerId()
public String getAsker()
public Map<CheatKeys,VerifData> getCheats()
public Optional<VerifData> getVerifData(Cheat c)
c
- the cheat which we are looking for verif datapublic int getVersion()
public Version getPlayerVersion()
public void generateMessage()
getMessages()
public void save()
getMessages()
is empty, a new summary will be made before saving