mirror of
https://github.com/psforever/PSF-LoginServer.git
synced 2026-03-12 00:40:35 +00:00
Improvements/fixes to some javadoc / comments
This commit is contained in:
parent
cd3e6d2f63
commit
1b0b84e53e
7 changed files with 40 additions and 18 deletions
|
|
@ -11,7 +11,7 @@ import net.psforever.types.{PlanetSideEmpire, Vector3}
|
|||
class Building(private val mapId : Int, private val zone : Zone, private val buildingType : StructureType.Value) extends PlanetSideServerObject {
|
||||
/**
|
||||
* The mapId is the identifier number used in BuildingInfoUpdateMessage.
|
||||
* The modelId is the identifier number used in SetEmpireMessage.
|
||||
* The modelId is the identifier number used in SetEmpireMessage / Facility hacking / PlanetSideAttributeMessage.
|
||||
*/
|
||||
private var modelId : Option[Int] = None
|
||||
private var faction : PlanetSideEmpire.Value = PlanetSideEmpire.NEUTRAL
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@ class BuildingControl(building : Building) extends Actor with FactionAffinityBeh
|
|||
building.Amenities.foreach(_.Actor forward FactionAffinity.ConfirmFactionAffinity())
|
||||
}
|
||||
sender ! FactionAffinity.AssertFactionAffinity(building, faction)
|
||||
|
||||
case _ => ;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ class Seat(private val seatDef : SeatDefinition) {
|
|||
|
||||
/**
|
||||
* Is this seat occupied?
|
||||
* @return the GUID of the player sitting in this seat, or `None` if it is left vacant
|
||||
* @return the Player object of the player sitting in this seat, or `None` if it is left vacant
|
||||
*/
|
||||
def Occupant : Option[Player] = {
|
||||
this.occupant
|
||||
|
|
@ -25,7 +25,7 @@ class Seat(private val seatDef : SeatDefinition) {
|
|||
* The player is trying to sit down.
|
||||
* Seats are exclusive positions that can only hold one occupant at a time.
|
||||
* @param player the player who wants to sit, or `None` if the occupant is getting up
|
||||
* @return the GUID of the player sitting in this seat, or `None` if it is left vacant
|
||||
* @return the Player object of the player sitting in this seat, or `None` if it is left vacant
|
||||
*/
|
||||
def Occupant_=(player : Player) : Option[Player] = Occupant_=(Some(player))
|
||||
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ import scodec.codecs._
|
|||
* <br>
|
||||
* Players/General:<br>
|
||||
* Server to client : <br>
|
||||
* `0 - health`<br>
|
||||
* `0 - health (setting to zero on vehicles/terminals will destroy them)`<br>
|
||||
* `1 - healthMax`<br>
|
||||
* `2 - stamina`<br>
|
||||
* `3 - staminaMax`<br>
|
||||
|
|
@ -104,6 +104,11 @@ import scodec.codecs._
|
|||
* `35 - BR. Value is the BR`<br>
|
||||
* `36 - CR. Value is the CR`<br>
|
||||
* `43 - Info on avatar name : 0 = Nothing, 1 = "(LD)" message`<br>
|
||||
* `45 - NTU charge bar 0-10, 5 = 50% full. Seems to apply to both ANT and NTU Silo (possibly siphons?)`<br>
|
||||
* 47 - Sets base NTU level to CRITICAL. MUST use base modelId not base GUID
|
||||
* 48 - Send base power loss message & turns on red warning lights throughout base. MUST use base modelId not base GUID
|
||||
* 49 - Vehicle texture effects state? (>0 turns on ANT panel glow or ntu silo panel glow + orbs) (bit?)
|
||||
* `52 - Vehicle particle effects? (>0 turns on orbs going towards ANT. Doesn't affect silo) (bit?)
|
||||
* `53 - LFS. Value is 1 to flag LFS`<br>
|
||||
* `54 - Player "Aura". Values can be expressed in the first byte's lower nibble:`<br>
|
||||
* - 0 is nothing<br>
|
||||
|
|
@ -114,6 +119,7 @@ import scodec.codecs._
|
|||
* -- e.g., 13 = 8 + 4 + 1 = fire and LLU and plasma<br>
|
||||
* `55 - "Someone is attempting to Heal you". Value is 1`<br>
|
||||
* `56 - "Someone is attempting to Repair you". Value is 1`<br>
|
||||
* `67 - Enables base shields (from cavern module/lock). MUST use base modelId not GUID`<br>
|
||||
* `73 - "You are locked into the Core Beam. Charging your Module now.". Value is 1 to active`<br>
|
||||
* `77 - Cavern Facility Captures. Value is the number of captures`<br>
|
||||
* `78 - Cavern Kills. Value is the number of kills`<br>
|
||||
|
|
@ -128,10 +134,12 @@ import scodec.codecs._
|
|||
* `13 - Trunk permissions (same)`<br>
|
||||
* `21 - Asserts first time event eligibility / makes owner if no owner is assigned`<br>
|
||||
* `22 - Toggles gunner and passenger mount points (1 = hides, 0 = reveals; this also locks their permissions)`<br>
|
||||
* `68 - ???`<br>
|
||||
* `54 - Vehicle EMP? Plays sound as if vehicle had been hit by EMP`<br>
|
||||
* `68 - Vehicle shield health`<br>
|
||||
* `80 - Damage vehicle (unknown value)`<br>
|
||||
* `81 - ???`<br>
|
||||
* `113 - ???`
|
||||
* `113 - `Vehicle capacitor - e.g. Leviathan EMP charge`
|
||||
*
|
||||
* @param player_guid the player
|
||||
* @param attribute_type na
|
||||
* @param attribute_value na
|
||||
|
|
|
|||
|
|
@ -6,10 +6,25 @@ import net.psforever.types.Vector3
|
|||
import scodec.Codec
|
||||
import scodec.codecs._
|
||||
|
||||
/** WeaponFireMessage seems to be sent each time a weapon actually shoots.
|
||||
/**
|
||||
* WeaponFireMessage seems to be sent each time a weapon actually shoots.
|
||||
*
|
||||
* See [[PlayerStateMessageUpstream]] for explanation of seq_time.
|
||||
*/
|
||||
*
|
||||
* @param seq_time See [[PlayerStateMessageUpstream]] for explanation of seq_time.
|
||||
* @param weapon_guid
|
||||
* @param projectile_guid
|
||||
* @param shot_origin
|
||||
* @param unk1 Always zero from testing so far
|
||||
* @param unk2 Seems semi-random
|
||||
* @param unk3 Seems semi-random
|
||||
* @param unk4 Maximum travel distance in meters - seems to be zero for decimator rockets
|
||||
* @param unk5 Possibly always 255 from testing
|
||||
* @param unk6 0 for bullet
|
||||
* 1 for possibly delayed explosion (thumper alt fire) or thresher/leviathan flux cannon
|
||||
* 2 for vs starfire (lockon type?)
|
||||
* 3 for thrown (e.g. grenades)
|
||||
* @param unk7 Seems to be thrown weapon velocity/direction
|
||||
*/
|
||||
final case class WeaponFireMessage(seq_time : Int,
|
||||
weapon_guid : PlanetSideGUID,
|
||||
projectile_guid : PlanetSideGUID,
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ final case class VariantVehicleData(unk : Int) extends SpecificVehicleData {
|
|||
* For very complicated vehicles, the packets `FrameVehicleStateMessage` and `VehicleSubStateMessage` will also be employed.
|
||||
* The tasks that these packets perform are different based on the vehicle that responds or generates them.
|
||||
* @param basic data common to objects
|
||||
* @param unk1 na
|
||||
* @param unk1 na. Valid values seem to be 0-3. Anything higher spawns a completely broken NC vehicle with no guns that can't move
|
||||
* @param health the amount of health the vehicle has, as a percentage of a filled bar (255)
|
||||
* @param unk2 na
|
||||
* @param no_mount_points do not display entry points for the seats
|
||||
|
|
|
|||
|
|
@ -1169,8 +1169,8 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
}
|
||||
sendResponse(PlanetsideAttributeMessage(vehicle_guid, 22, 0L)) //mount points on?
|
||||
//sendResponse(PlanetsideAttributeMessage(vehicle_guid, 0, 10))//vehicle.Definition.MaxHealth))
|
||||
sendResponse(PlanetsideAttributeMessage(vehicle_guid, 68, 0L)) //???
|
||||
sendResponse(PlanetsideAttributeMessage(vehicle_guid, 113, 0L)) //???
|
||||
sendResponse(PlanetsideAttributeMessage(vehicle_guid, 68, 0L)) // Shield health
|
||||
sendResponse(PlanetsideAttributeMessage(vehicle_guid, 113, 0L)) // Capacitor (EMP)
|
||||
ReloadVehicleAccessPermissions(vehicle)
|
||||
ServerVehicleLock(vehicle)
|
||||
|
||||
|
|
@ -3417,7 +3417,7 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
/**
|
||||
* Gives a target player positive battle experience points only.
|
||||
* If the player has access to more implant slots as a result of changing battle experience points, unlock those slots.
|
||||
* @param tplayer the player
|
||||
* @param avatar the player
|
||||
* @param bep the change in experience points, positive by assertion
|
||||
* @return the player's current battle experience points
|
||||
*/
|
||||
|
|
@ -4069,7 +4069,7 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
obj match {
|
||||
case vehicle : Vehicle =>
|
||||
ReloadVehicleAccessPermissions(vehicle) //TODO we should not have to do this imho
|
||||
//
|
||||
|
||||
if(obj.Definition == GlobalDefinitions.ams) {
|
||||
obj.DeploymentState match {
|
||||
case DriveState.Deployed =>
|
||||
|
|
@ -4241,7 +4241,7 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
* <br>
|
||||
* A maximum revive waiting timer is started.
|
||||
* When this timer reaches zero, the avatar will attempt to spawn back on its faction-specific sanctuary continent.
|
||||
* @pararm tplayer the player to be killed
|
||||
* @param tplayer the player to be killed
|
||||
*/
|
||||
def KillPlayer(tplayer : Player) : Unit = {
|
||||
val player_guid = tplayer.GUID
|
||||
|
|
@ -4495,7 +4495,7 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
/**
|
||||
* For pure proximity-based units and services, disable any manual attempt at cutting off the functionality.
|
||||
* If an existing timer can be found, cancel it.
|
||||
* @param terminal the proximity-based unit
|
||||
* @param terminal_guid the proximity-based unit
|
||||
*/
|
||||
def ClearDelayedProximityUnitReset(terminal_guid : PlanetSideGUID) : Unit = {
|
||||
delayedProximityTerminalResets.get(terminal_guid) match {
|
||||
|
|
@ -4592,7 +4592,7 @@ class WorldSessionActor extends Actor with MDCContextAware {
|
|||
* Restore, at most, a specific amount of health points on a player.
|
||||
* Send messages to connected client and to events system.
|
||||
* @param tplayer the player
|
||||
* @param repairValue the amount to heal;
|
||||
* @param healValue the amount to heal;
|
||||
* 10 by default
|
||||
* @return whether the player can be repaired for any more health points
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue