mirror of
https://github.com/2revoemag/PSF-BotServer.git
synced 2026-03-03 12:10:22 +00:00
Tweaks to !hack admin command to reduce the message storm it causes (#405)
This commit is contained in:
parent
4c249bb358
commit
70e59effec
2 changed files with 9 additions and 5 deletions
|
|
@ -4663,7 +4663,6 @@ class WorldSessionActor extends Actor
|
|||
if(!building.Name.isEmpty && args(1).equalsIgnoreCase(building.Name)) {
|
||||
log.info(s"Hack Base Name : ${args(1)} to empire : ${args(2)}")
|
||||
building.Faction = hackFaction
|
||||
building.Actor ! Building.TriggerZoneMapUpdate(continent.Number)
|
||||
continent.LocalEvents ! LocalServiceMessage(continent.Id, LocalAction.SetEmpire(building.GUID, hackFaction))
|
||||
}
|
||||
})
|
||||
|
|
@ -4681,10 +4680,13 @@ class WorldSessionActor extends Actor
|
|||
else {
|
||||
continent.Buildings.foreach({
|
||||
case (id, building) =>
|
||||
if (!building.Name.isEmpty && !bad && building.BuildingType.id != 6) {
|
||||
if (!building.Name.isEmpty && !bad
|
||||
&& building.BuildingType != StructureType.Bridge
|
||||
&& building.BuildingType != StructureType.Bunker
|
||||
&& building.BuildingType != StructureType.WarpGate
|
||||
) {
|
||||
log.info(s"Hack Bases to empire : ${args(1)}")
|
||||
building.Faction = hackFaction
|
||||
building.Actor ! Building.TriggerZoneMapUpdate(continent.Number)
|
||||
continent.LocalEvents ! LocalServiceMessage(continent.Id, LocalAction.SetEmpire(building.GUID, hackFaction))
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue