mirror of
https://github.com/2revoemag/PSF-BotServer.git
synced 2026-07-15 16:34:39 +00:00
console?
This commit is contained in:
parent
892cd376bc
commit
bcb3c43211
1 changed files with 6 additions and 10 deletions
|
|
@ -974,7 +974,6 @@ class SquadService extends Actor {
|
||||||
def CloseSquad(squad: Squad): Unit = {
|
def CloseSquad(squad: Squad): Unit = {
|
||||||
val guid = squad.GUID
|
val guid = squad.GUID
|
||||||
val membership = squad.Membership.zipWithIndex
|
val membership = squad.Membership.zipWithIndex
|
||||||
val factionListings = publishedLists(squad.Faction)
|
|
||||||
val (updateMembers, updateIndices) = membership.collect {
|
val (updateMembers, updateIndices) = membership.collect {
|
||||||
case (member, index) if member.CharId > 0 =>
|
case (member, index) if member.CharId > 0 =>
|
||||||
((member, member.CharId, index, subs.UserEvents.get(member.CharId)), (member.CharId, index))
|
((member, member.CharId, index, subs.UserEvents.get(member.CharId)), (member.CharId, index))
|
||||||
|
|
@ -1011,15 +1010,12 @@ class SquadService extends Actor {
|
||||||
subs.Publish(charId, SquadResponse.Detail(PlanetSideGUID(0), completelyBlankSquadDetail))
|
subs.Publish(charId, SquadResponse.Detail(PlanetSideGUID(0), completelyBlankSquadDetail))
|
||||||
}
|
}
|
||||||
UpdateSquadListWhenListed(features.Stop, None)
|
UpdateSquadListWhenListed(features.Stop, None)
|
||||||
//I think this is right, otherwise squadFeatures will never be empty and TryResetSquadId will not reset to 1
|
squadFeatures -= guid
|
||||||
squadFeatures.remove(guid)
|
//really make sure it is removed
|
||||||
//for the rare case of a phantom squad that no longer exists but is still on the publishedLists
|
publishedLists(squad.Faction) -= guid
|
||||||
factionListings.find(_ == guid) match {
|
//testing
|
||||||
case Some(squad) =>
|
println(s"AllSquads Removed: $guid - Remaining: $squadFeatures")
|
||||||
val index = factionListings.indexOf(squad)
|
println(s"ListedSquads: $publishedLists")
|
||||||
factionListings.remove(index)
|
|
||||||
case None =>
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue