Cockatrice 2026-06-01-Development-3.1.0-beta.3
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
arrow_data.h
Go to the documentation of this file.
1#ifndef COCKATRICE_ARROW_DATA_H
2#define COCKATRICE_ARROW_DATA_H
3
4#include <QColor>
5#include <QString>
6#include <libcockatrice/protocol/pb/serverinfo_arrow.pb.h>
8
10{
11 int id;
13 QString startZone;
16 QString targetZone; // empty = targeting a player
17 int targetCardId = -1; // -1 = targeting a player
18 QColor color;
19
20 static ArrowData fromProto(const ServerInfo_Arrow &arrow);
21
22 bool isPlayerTargeted() const
23 {
24 return targetZone.isEmpty();
25 }
26};
27
28#endif // COCKATRICE_ARROW_DATA_H
Definition arrow_data.h:10
bool isPlayerTargeted() const
Definition arrow_data.h:22
QString targetZone
Definition arrow_data.h:16
int targetCardId
Definition arrow_data.h:17
static ArrowData fromProto(const ServerInfo_Arrow &arrow)
Definition arrow_data.cpp:3
int startCardId
Definition arrow_data.h:14
QString startZone
Definition arrow_data.h:13
QColor color
Definition arrow_data.h:18
int id
Definition arrow_data.h:11
int startPlayerId
Definition arrow_data.h:12
int targetPlayerId
Definition arrow_data.h:15