]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/bot/default/scripting.qh
Merge branch 'master' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / bot / default / scripting.qh
index 1f2d4da312829196aa04f3aaf707d05e0ed7ae68..cb5bf625f6cb0c37a71f445e33683f4cbfa70239 100644 (file)
@@ -1,5 +1,4 @@
-#ifndef BOT_SCRIPTING_H
-#define BOT_SCRIPTING_H
+#pragma once
 
 #define BOT_EXEC_STATUS_IDLE 0
 #define BOT_EXEC_STATUS_PAUSED 1
@@ -9,7 +8,6 @@
 #define CMD_STATUS_FINISHED 1
 #define CMD_STATUS_ERROR 2
 
-void bot_clearqueue(entity bot);
 
 // NOTE: New commands should be added here. Do not forget to update BOT_CMD_COUNTER
 const int BOT_CMD_NULL                         = 0;
@@ -36,16 +34,16 @@ const int BOT_CMD_BARRIER           = 20;
 const int BOT_CMD_CONSOLE              = 21;
 const int BOT_CMD_SOUND                = 22;
 const int BOT_CMD_DEBUG_ASSERT_CANFIRE = 23;
-const int BOT_CMD_WHILE                = 24;   // TODO: Not implemented yet
-const int BOT_CMD_WEND                         = 25;   // TODO: Not implemented yet
-const int BOT_CMD_CHASE                = 26;   // TODO: Not implemented yet
+//const int BOT_CMD_WHILE              = 24;   // TODO: Not implemented yet
+//const int BOT_CMD_WEND                       = 25;   // TODO: Not implemented yet
+//const int BOT_CMD_CHASE              = 26;   // TODO: Not implemented yet
 
 const int BOT_CMD_COUNTER              = 24;   // Update this value if you add/remove a command
 
 // NOTE: Following commands should be implemented on the bot ai
 //              If a new command should be handled by the target ai(s) please declare it here
-.float(vector) cmd_moveto;
-.float() cmd_resetgoal;
+.float(entity, vector) cmd_moveto;
+.float(entity) cmd_resetgoal;
 
 //
 const int BOT_CMD_PARAMETER_NONE = 0;
@@ -61,7 +59,6 @@ string bot_cmd_string[BOT_CMD_COUNTER];
 entity bot_cmd;        // global current command
 .entity bot_cmd_current; // current command of this bot
 
-.float is_bot_cmd;                     // Tells if the entity is a bot command
 .float bot_cmd_index;                  // Position of the command in the queue
 .int bot_cmd_type;                     // If of command (see the BOT_CMD_* defines)
 .float bot_cmd_parm_float;             // Field to store a float parameter
@@ -78,7 +75,6 @@ void bot_resetqueues();
 void bot_queuecommand(entity bot, string cmdstring);
 void bot_cmdhelp(string scmd);
 void bot_list_commands();
-float bot_execute_commands();
+float bot_execute_commands(entity this);
 entity find_bot_by_name(string name);
 entity find_bot_by_number(float number);
-#endif