]> git.sesse.net Git - ccbs/blobdiff - bigscreen/group.h
Add beginning code for fetching groups.
[ccbs] / bigscreen / group.h
diff --git a/bigscreen/group.h b/bigscreen/group.h
new file mode 100644 (file)
index 0000000..6961a90
--- /dev/null
@@ -0,0 +1,30 @@
+#ifndef _GROUP_H
+#define _GROUP_H 1
+
+#include <vector>
+#include "widestring.h"
+
+/* This more or less mimics the structures from show-tournament.pl */
+struct Song {
+       unsigned id;
+       widestring title, artist;
+};
+struct Score {
+       Song song;
+       bool chosen;
+       unsigned score;
+}:
+struct Player {
+       unsigned id;
+       widestring nick;
+       unsigned score, rank;
+       
+       std::vector<Score> scores;
+};
+
+struct Group {
+       unsigned tournament, round, parallel;
+       std::vector<Player> players;
+};
+
+#endif /* !defined(_GROUPSCREEN_H) */