PSF-LoginServer/src/main/scala/net/psforever/objects/Session.scala
Fate-JH 426ab84f0a
Spectator Role (#1200)
* reorganized files and methods for session actor in preparation for custom spectator implementation

* split existing code between data and functions, and entry points; parsing and logic management is now handled within the current game mode, which should reduce the need to ask explicits

* should fix players not performing damage after being broken for an unknown amount of time, maybe never working correctly

* functioning spectator mode logic swap; initial packets for UplinkRequest, UplinkResponse, and UplinkPositionEvent

* available chat prompts can now be different based on player mode without testing flags

* modified ChatActor to be replaced by a function-data logic pair, and modified ChatService to be able to accommodate the new chat channel; chat packet handling moved from general operations to the new chat operations

* resolved issues with spectator implants, at least enough that implants should be stable; created an exclusive permission for spectator mode; database changes to persist permissions for different modes

* command detonater is no longer allowed; spectators now hold a laze pointer

* for the purposes of testing, anyone can be a spectator

* spectator mode is important to confirm; removed deprecated chat actor; dismount quietly

* oops; allowed again

* restored commands setbr and setcr; deployables are erased from spectator map; projectiles destruction only just in case

* role only for those who are permitted
2024-05-10 22:30:20 -04:00

21 lines
525 B
Scala

package net.psforever.objects
import net.psforever.objects.avatar.Avatar
import net.psforever.objects.zones.{Zone, Zoning}
import net.psforever.packet.game.DeadState
case class Session(
id: Long = 0,
zone: Zone = Zone.Nowhere,
account: Account = null,
player: Player = null,
avatar: Avatar = null,
zoningType: Zoning.Method = Zoning.Method.None,
deadState: DeadState.Value = DeadState.Alive,
speed: Float = 1.0f,
flying: Boolean = false
)
trait SessionSource {
def session: Session
}