UNPKG

node-insim

Version:

An InSim library for NodeJS with TypeScript support

68 lines (67 loc) 1.71 kB
import { __decorate } from "tslib"; import { byte, unsigned, word } from '../decorators'; import { Packet } from './base'; import { PacketType } from './enums'; /** * FINished race notification (not a final result - use {@link IS_RES}) */ export class IS_FIN extends Packet { constructor() { super(...arguments); this.Size = 20; this.Type = PacketType.ISP_FIN; this.ReqI = 0; /** Player's unique id (0 = player left before result was sent) */ this.PLID = 0; /** Race time (ms) */ this.TTime = 0; /** Best lap (ms) */ this.BTime = 0; this.SpA = 0; /** Number of pit stops */ this.NumStops = 0; /** Confirmation flags: disqualified etc. */ this.Confirm = 0; this.SpB = 0; /** Laps completed */ this.LapsDone = 0; /** Player flags: help settings etc. */ this.Flags = 0; } } __decorate([ byte() ], IS_FIN.prototype, "Size", void 0); __decorate([ byte() ], IS_FIN.prototype, "Type", void 0); __decorate([ byte() ], IS_FIN.prototype, "ReqI", void 0); __decorate([ byte() ], IS_FIN.prototype, "PLID", void 0); __decorate([ unsigned() ], IS_FIN.prototype, "TTime", void 0); __decorate([ unsigned() ], IS_FIN.prototype, "BTime", void 0); __decorate([ byte() ], IS_FIN.prototype, "SpA", void 0); __decorate([ byte() ], IS_FIN.prototype, "NumStops", void 0); __decorate([ byte() ], IS_FIN.prototype, "Confirm", void 0); __decorate([ byte() ], IS_FIN.prototype, "SpB", void 0); __decorate([ word() ], IS_FIN.prototype, "LapsDone", void 0); __decorate([ word() ], IS_FIN.prototype, "Flags", void 0);