resonance 1.0.1
Loading...
Searching...
No Matches
sectioncapturedmsg.h
Go to the documentation of this file.
1#pragma once
2
3#include <iostream>
4
5#include "msg/message.h"
6
7class Player;
8
25private:
26 int mFirstBar; // +0x04
27
28public:
37
50 SectionCapturedMsg(int nFirstBar, int nEndBar, int nTrack, Player *pPlayer, int nAutoCatch)
51 : mFirstBar(nFirstBar), mEndBar(nEndBar), mTrack(nTrack), mPlayer(pPlayer),
52 mAutoCatch(nAutoCatch) {
53 }
54
64 static Message *New();
65
73 virtual Message *Clone();
74
82 virtual int Type();
83
91 virtual const char *GetName() const;
92
101 virtual void PrintExtra(std::ostream &stream) const;
102
104 int mTrack;
107};
108
Base of every event the game passes between a MsgSource and a MsgSink.
Definition message.h:41
One participant in a session, local or remote.
Definition player.h:39
SectionCapturedMsg()
Construct a message with the payload unset.
Definition sectioncapturedmsg.h:35
int mEndBar
Definition sectioncapturedmsg.h:103
Player * mPlayer
Definition sectioncapturedmsg.h:105
virtual const char * GetName() const
Report this message's class name.
int mTrack
Definition sectioncapturedmsg.h:104
static Message * New()
Produce a default-constructed message on the heap.
SectionCapturedMsg(int nFirstBar, int nEndBar, int nTrack, Player *pPlayer, int nAutoCatch)
Report a captured section.
Definition sectioncapturedmsg.h:50
int mAutoCatch
Definition sectioncapturedmsg.h:106
virtual Message * Clone()
Produce a heap copy of this message.
virtual int Type()
Report this message's registered identity.
virtual void PrintExtra(std::ostream &stream) const
Write b , the bar range joined by --, tr# , the track, a space, and the player's colour name to a di...
int g_nSectionCapturedMsgType
Identity that SectionCapturedMsg::Type() reports.