resonance 1.0.1
Loading...
Searching...
No Matches
gameinfo.h
Go to the documentation of this file.
1#pragma once
2
3#include <iostream>
4
5#include "game/gameparams.h"
7#include "os/hxstr.h"
8
9class IBStream;
10class OBStream;
11
24class GameInfo {
25public:
32 virtual ~GameInfo();
33
43 virtual void Save(OBStream &stream);
44
52 virtual void Load(IBStream &stream);
53
64 void Print(std::ostream &stream);
65
66private:
67 TransportAddress mAddress;
68 unsigned int mMediusWorldId;
69 HxStr mHost;
70 GameParams mParams;
71 int mStatus;
72};
One advertised network game: where it is hosted and the settings it plays.
Definition gameinfo.h:24
void Print(std::ostream &stream)
Write the fields to a diagnostic stream.
virtual ~GameInfo()
Slot 1.
virtual void Load(IBStream &stream)
Read back what Save() writes.
virtual void Save(OBStream &stream)
Write the address, the world identifier, the host, the settings, and the status.
Settings a game session is started with.
Definition gameparams.h:42
Heap-allocated NUL-terminated string.
Definition hxstr.h:41
Input half of the byte stream interface.
Definition ibstream.h:36
Output half of the byte stream interface.
Definition obstream.h:25
Network address a packet transport serialises: three strings and one word.
Definition transportaddress.h:20