IS VER

From LFS Manual
Revision as of 18:02, 22 June 2009 by DarkTimes (talk | contribs)
(diff) ←Older revision | Current revision (diff) | Newer revision→ (diff)
Jump to navigationJump to search

Introduction

The IS_VER packet contains information about the LFS and InSim versions, allowing you to prevent your program interacting with legacy versions of the game. To request a IS_VER packet to be sent, either set the ReqI to non-zero in the IS_ISI packet when initialising InSim, or by sending a IS_TINY packet with a SubT of TINY_VER.

struct IS_VER // VERsion
{
	byte	Size;			// 20
	byte	Type;			// ISP_VERSION
	byte	ReqI;			// ReqI as received in the request packet
	byte	Zero;

	char	Version[8];		// LFS version, e.g. 0.3G
	char	Product[6];		// Product : DEMO or S1
	word	InSimVer;		// InSim Version : increased when InSim packets change
};

Packet Detail

Size

The size of the packet, always 20.

Type

The type of packet from the ISP_ enumeration, always ISP_VER.

ReqI

Contains the ReqI as received in the request for an IS_VER to be sent.

Version

The LFS version, E.G. 0.5Z.

Product

The LFS product, E.G. S2.

InSimVer

The current InSim version, which at the time of writing is version 4. If this value does not match the version of InSim you are expecting, your program may not work correctly.