project_files/frontlib/model/team.h
changeset 7482 d70a5b0d1190
parent 7470 0db1780ca938
child 7497 7e1d72fc03c7
--- a/project_files/frontlib/model/team.h	Sun Aug 12 22:21:09 2012 +0200
+++ b/project_files/frontlib/model/team.h	Sun Aug 12 22:37:57 2012 +0200
@@ -24,7 +24,7 @@
  * extra information about teams. For example, the weaponset is important
  * to the engine, but not for ini reading/writing, and with the team statistics it is the
  * other way around. To keep things simple, the data structure can hold all information
- * used in any context. On the downside, tat means we can't use static typing to ensure
+ * used in any context. On the downside, that means we can't use static typing to ensure
  * that team information is "complete" for a particular purpose.
  */
 #ifndef TEAM_H_
@@ -39,6 +39,9 @@
 
 #define TEAM_DEFAULT_HEALTH 100
 
+/**
+ * Struct representing a single keybinding.
+ */
 typedef struct {
 	char *action;
 	char *binding;
@@ -46,7 +49,7 @@
 
 typedef struct {
 	char *name;
-	char *hat;
+	char *hat;			// e.g. hair_yellow; References a .png file in Data/Graphics/Hats
 
 	// Statistics. They are irrelevant for the engine or server,
 	// but provided for ini reading/writing by the frontend.
@@ -55,7 +58,7 @@
 	int deaths;
 	int suicides;
 
-	int difficulty;
+	int difficulty;		// 0 = human, 1 = most difficult bot ... 5 = least difficult bot (somewhat counterintuitive)
 
 	// Transient setting used in game setup
 	int initialHealth;
@@ -65,10 +68,10 @@
 typedef struct {
 	flib_hog hogs[HEDGEHOGS_PER_TEAM];
 	char *name;
-	char *grave;
-	char *fort;
-	char *voicepack;
-	char *flag;
+	char *grave;		// e.g. "Bone"; References a .png file in Data/Graphics/Graves
+	char *fort;			// e.g. "Castle"; References a series of files in Data/Forts
+	char *voicepack;	// e.g. "Classic"; References a directory in Data/Sounds/voices
+	char *flag;			// e.g. "hedgewars"; References a .png file in Data/Graphics/Flags
 
 	flib_binding *bindings;
 	int bindingCount;
@@ -81,9 +84,9 @@
 
 	// Transient settings used in game setup
 	int colorIndex;		// Index into a color table
-	int hogsInGame;
-	bool remoteDriven;
-	char *ownerName;
+	int hogsInGame;		// The number of hogs that will actually play
+	bool remoteDriven;	// true for non-local teams in a network game
+	char *ownerName;	// Username of the owner of a team in a network game
 } flib_team;
 
 /**