]> git.cameronkatri.com Git - bsdgames-darwin.git/blobdiff - trek/capture.c
Use An in AUTHORS section.
[bsdgames-darwin.git] / trek / capture.c
index 9c7414d2571f49b9687f07610a94ac13072b7d6b..48a70e815eff1ad2f44c9c9d8c27b76a68332893 100644 (file)
@@ -1,4 +1,4 @@
-/*     $NetBSD: capture.c,v 1.9 2009/05/24 20:39:43 dholland Exp $     */
+/*     $NetBSD: capture.c,v 1.12 2009/08/12 08:54:54 dholland Exp $    */
 
 /*
  * Copyright (c) 1980, 1993
 #if 0
 static char sccsid[] = "@(#)capture.c  8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: capture.c,v 1.9 2009/05/24 20:39:43 dholland Exp $");
+__RCSID("$NetBSD: capture.c,v 1.12 2009/08/12 08:54:54 dholland Exp $");
 #endif
 #endif /* not lint */
 
 #include <stdio.h>
 #include "trek.h"
 
+static struct kling *selectklingon(void);
+
 /*
 **  Ask a Klingon To Surrender
 **
@@ -64,8 +66,7 @@ capture(int v __unused)
        double                  x;
 
        /* check for not cloaked */
-       if (Ship.cloaked)
-       {
+       if (Ship.cloaked) {
                printf("Ship-ship communications out when cloaked\n");
                return;
        }
@@ -74,8 +75,7 @@ capture(int v __unused)
                return;
        }
        /* find out if there are any at all */
-       if (Etc.nkling <= 0)
-       {
+       if (Etc.nkling <= 0) {
                printf("Uhura: Getting no response, sir\n");
                return;
        }
@@ -96,13 +96,13 @@ capture(int v __unused)
        if (Trace)
                printf("Prob = %d (%.4f)\n", i, x);
 #endif
-       if (i > ranf(100))
-       {
+       if (i > ranf(100)) {
                /* guess what, he surrendered!!! */
                printf("Klingon at %d,%d surrenders\n", k->x, k->y);
                i = ranf(Param.klingcrew);
                if ( i > 0 )
-                       printf("%d klingons commit suicide rather than be taken captive\n", Param.klingcrew - i);
+                       printf("%d klingons commit suicide rather than be "
+                              "taken captive\n", Param.klingcrew - i);
                if (i > Ship.brigfree)
                        i = Ship.brigfree;
                Ship.brigfree -= i;
@@ -123,7 +123,7 @@ capture(int v __unused)
 **     Cruddy, just takes one at random.  Should ask the captain.
 */
 
-struct kling *
+static struct kling *
 selectklingon(void)
 {
        int             i;