Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2001:
[Freeciv-Dev] Re: generalized unit capabilities
Home

[Freeciv-Dev] Re: generalized unit capabilities

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Freeciv List <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: generalized unit capabilities
From: Jason Short <vze2zq63@xxxxxxxxxxx>
Date: Wed, 05 Dec 2001 13:47:13 -0500
Reply-to: jdorje@xxxxxxxxxxxx

Andrew Sutton wrote:


people have been talking about the desire for generalized unit capabilities for a while now. you yourself admitted that it was a shortcoming - if not immediately, then eventually. now you say that there's no benefit? this is just an additive patch. it won't affect any part of the game that chooses not to use it...

anybody else have any thoughts?

I really don't know much about this topic; given that, your system seems much cooler than Raimar's but I don't think it's needed (yet).

Here are some technical comments on the patch.


Index: common/registry.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/registry.c,v
retrieving revision 1.34
diff -u -r1.34 registry.c
--- common/registry.c   2001/08/13 15:13:35     1.34
+++ common/registry.c   2001/12/05 17:33:14
@@ -717,13 +717,13 @@
   if(!(pentry=section_file_lookup_internal(my_section_file, buf))) {
     freelog(LOG_FATAL, "sectionfile %s doesn't contain a '%s' entry",
            secfile_filename(my_section_file), buf);
-    exit(1);
+    exit(0);
   }
if(!pentry->svalue) {
     freelog(LOG_FATAL, "sectionfile %s entry '%s' doesn't contain a string",
            secfile_filename(my_section_file), buf);
-    exit(1);
+    exit(0);
   }

What is the purpose of this change?


-struct unit_type unit_types[U_LAST];
-/* the unit_types array is now setup in:
-   server/ruleset.c (for the server)
-   client/packhand.c (for the client)
+/**
+ * The unit_types array is now setup in:
+ * <ul>
+ * <li> \e server - server/ruleset.c
+ * <li> \e client - client/packhand.c
+ * </ul>
 */

I assume the HTML is so that doxygen can parse it. This is not necessary. IIRC a comment of the form

/**
 * The unit_types array is now set up in:
 *   - server - server/ruleset.c
 *   - client - client/packhand.c
 */

will have a similar effect. Read the doxygen documentation for more about this.


+/*@

Why use /** in some places and /*@ in others? Personally, I prefer /** and /**<, but this is a question for the style guide (AFTER doxygen is adopted).

jason



[Prev in Thread] Current Thread [Next in Thread]