mirror of
https://github.com/AsgardEternal/squad-js-map-vote.git
synced 2025-01-23 17:13:54 -06:00
Update mapvote.js
This commit is contained in:
parent
5e9aeae5da
commit
e9f6551a1f
@ -139,7 +139,8 @@ export default class MapVote extends BasePlugin {
|
||||
// setTimeout(()=>{this.msgDirect('76561198419229279',"MV\ntest\ntest")},1000)
|
||||
// this.msgBroadcast("[MapVote] Seeding mode active")
|
||||
if (this && this.options && this.server && this.options.automaticSeedingMode && ((this.server.nextLayer && this.server.nextLayer.gamemode.toLowerCase() != "seed") || this.server.currentLayer.layerid == this.server.nextLayer.layerid)) {
|
||||
const seedingMaps = Layers.layers.filter((l) => l.gamemode.toUpperCase() == "SEED" && !mapBlacklist.includes(l.map.name) && l.layerid != this.server.currentLayer.layerid && !this.options.layerLevelBlacklist.find((fl)=>l.layerid.toLowerCase().startsWith(fl.toLowerCase())))
|
||||
const mapBlacklist=[];
|
||||
const seedingMaps = Layers.layers.filter((l) => l.gamemode.toUpperCase() == "SEED" && !mapBlacklist.includes(l.map.name) && l.layerid != this.server.currentLayer.layerid && !this.options.layerLevelBlacklist.find((fl)=>l.layerid.toLowerCase().startsWith(fl.toLowerCase())))
|
||||
|
||||
const nextMap = randomElement(seedingMaps).layerid;
|
||||
if (this.server.players && this.server.players.length < 20) {
|
||||
@ -465,4 +466,4 @@ export default class MapVote extends BasePlugin {
|
||||
|
||||
return ties.map(i => this.nominations[ i ]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user