prefer camelCase with JS

This commit is contained in:
SeanWalsh95 2022-07-12 15:28:47 -04:00 committed by GitHub
parent 83de2491ac
commit 2a2a09caa9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,17 +11,17 @@ export default class AutoTKWarn extends BasePlugin {
static get optionsSpecification() {
return {
attacker_message: {
attackerMessage: {
required: false,
description: 'The message to warn attacking players with.',
default: 'Please apologise for ALL TKs in ALL chat!'
},
warn_victim: {
warnVictim: {
required: false,
description: 'Should we nottify the the victim, telling them that they were teamkilled via a warning message',
default: false
},
victim_message: {
victimMessage: {
required: false,
description: 'The message that will be sent to the victim',
default: 'You were killed by your own team.'
@ -45,10 +45,10 @@ export default class AutoTKWarn extends BasePlugin {
async onTeamkill(info) {
if (info.attacker) {
this.server.rcon.warn(info.attacker.steamID, this.options.attacker_message);
this.server.rcon.warn(info.attacker.steamID, this.options.attackerMessage);
}
if (this.options.warn_victim && info.victim) {
this.server.rcon.warn(info.victim.steamID, this.options.victim_message);
if (this.options.warnVictim && info.victim) {
this.server.rcon.warn(info.victim.steamID, this.options.victimMessage);
}
}
}