UNPKG

node-insim

Version:

An InSim library for NodeJS with TypeScript support

36 lines (35 loc) 893 B
import { __decorate } from "tslib"; import { byte, stringNull } from '../decorators'; import { SendablePacket } from './base'; import { PacketType } from './enums'; export const MST_MSG_MAX_LENGTH = 64; /** * MSg Type - send to LFS to type message or command */ export class IS_MST extends SendablePacket { constructor(data) { super(); this.Size = 68; this.Type = PacketType.ISP_MST; this.ReqI = 0; this.Zero = 0; /** Last byte must be zero */ this.Msg = ''; this.initialize(data); } } __decorate([ byte() ], IS_MST.prototype, "Size", void 0); __decorate([ byte() ], IS_MST.prototype, "Type", void 0); __decorate([ byte() ], IS_MST.prototype, "ReqI", void 0); __decorate([ byte() ], IS_MST.prototype, "Zero", void 0); __decorate([ stringNull(MST_MSG_MAX_LENGTH) ], IS_MST.prototype, "Msg", void 0);