]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/minigames/minigame/all.qh
Teams: mark all uses
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / minigames / minigame / all.qh
index d1899e7594328e0414b79ea37bdfbe1f093a410b..dfed3dce8e93773838e0720b29b8b2009a2eb411 100644 (file)
@@ -1,7 +1,9 @@
+#pragma once
+
 #if defined(SVQC)
-#include "../sv_minigames.qh"
+#include <common/minigames/sv_minigames.qh>
 #elif defined(CSQC)
-#include "../cl_minigames.qh"
+#include <common/minigames/cl_minigames.qh>
 #endif
 
 /**
@@ -47,7 +49,7 @@ used as send flags for minigame entities:
 * MINIG_SF_UPDATE
        A miscellaneous update, can be safely used if the entity has just a few fields
 * MINIG_SF_CUSTOM
-       Starting value for custom flags, since there are bit-wise flags, 
+       Starting value for custom flags, since there are bit-wise flags,
        the following values shall be MINIG_SF_CUSTOM*2, MINIG_SF_CUSTOM*4 and MINIG_SF_CUSTOM*8.
 * MINIG_SF_MAX
        Maximum flag value that will be networked
@@ -65,31 +67,16 @@ that .owner is set to the minigame session entity and .minigame_autoclean is tru
 #include "ttt.qc"
 #include "c4.qc"
 #include "pong.qc"
-#include "qto.qc"
 #include "ps.qc"
 #include "pp.qc"
-
-/**
- * Registration:
- *     MINIGAME(id,"Name")
- *             id    (QuakeC symbol) Game identifier, used to find the functions explained above
- *             "Name"(String)        Human readable name for the game, shown in the UI
- */
-#define REGISTERED_MINIGAMES \
-       MINIGAME(nmm, "Nine Men's Morris") \
-       MINIGAME(ttt, "Tic Tac Toe") \
-       MINIGAME(pong,"Pong") \
-       MINIGAME(c4,  "Connect Four") \
-       MINIGAME(qto, "Quinto") \
-       MINIGAME(ps,  "Peg Solitaire") \
-       MINIGAME(pp,  "Push-Pull") \
-       /*empty line*/
+#include "snake.qc"
+#include "bd.qc"
 
 /**
  * Set up automatic entity read/write functionality
  * To ensure that everything is handled automatically, spawn on the server using msle_spawn
  * Syntax:
- *     MSLE(classname,Field...) \ 
+ *     MSLE(classname,Field...) \
  *             classname: Identifier used to recognize the type of the entity
  *                        (must be set as .classname on the sent entities)
  *             Field... : List of FIELD calls
@@ -112,8 +99,8 @@ that .owner is set to the minigame session entity and .minigame_autoclean is tru
  *     MSLE stands for Minigame Simple Linked Entity
  */
 #define MINIGAME_SIMPLELINKED_ENTITIES \
-       MSLE(minigame_board_piece,FIELD(MINIG_SF_CREATE,Byte,team) FIELD(MINIG_SF_UPDATE, Short, minigame_flags) FIELD(MINIG_SF_UPDATE, Vector2D,origin)) \
-       MSLE(pong_paddle,FIELD(MINIG_SF_CREATE,Byte,team) FIELD(MINIG_SF_CREATE,Float,pong_length) FIELD(MINIG_SF_UPDATE,Vector2D,origin)) \
-       MSLE(pong_ball,FIELD(MINIG_SF_CREATE,Float,pong_length) FIELD(PONG_SF_BALLTEAM,Byte,team) FIELD(MINIG_SF_UPDATE, Vector2D, velocity) FIELD(MINIG_SF_UPDATE, Vector2D, origin)) \
-       MSLE(pong_ai, FIELD(MINIG_SF_CREATE,Byte,team) FIELD(PONG_SF_PLAYERSCORE, Long, pong_score)) \
-       /*empty line*/ 
+       MSLE(minigame_board_piece,FIELD(MINIG_SF_CREATE,Byte,__team) FIELD(MINIG_SF_UPDATE, Short, minigame_flags) FIELD(MINIG_SF_UPDATE, Vector2D,origin)) \
+       MSLE(pong_paddle,FIELD(MINIG_SF_CREATE,Byte,__team) FIELD(MINIG_SF_CREATE,Float,pong_length) FIELD(MINIG_SF_UPDATE,Vector2D,origin)) \
+       MSLE(pong_ball,FIELD(MINIG_SF_CREATE,Float,pong_length) FIELD(PONG_SF_BALLTEAM,Byte,__team) FIELD(MINIG_SF_UPDATE, Vector2D, velocity) FIELD(MINIG_SF_UPDATE, Vector2D, origin)) \
+       MSLE(pong_ai, FIELD(MINIG_SF_CREATE,Byte,__team) FIELD(PONG_SF_PLAYERSCORE, Long, pong_score)) \
+       /*empty line*/