Author: sveinung
Date: Wed Aug 19 14:24:23 2015
New Revision: 29583

URL: http://svn.gna.org/viewcvs/freeciv?rev=29583&view=rev
Log:
Found City can cause an incident

The check that Found City has a victim wasn't removed when giving everyone,
not just the victim of an action, a casus belli in patch #6213. Fix it.

See bug #23795

Modified:
    trunk/server/unithand.c

Modified: trunk/server/unithand.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/server/unithand.c?rev=29583&r1=29582&r2=29583&view=diff
==============================================================================
--- trunk/server/unithand.c     (original)
+++ trunk/server/unithand.c     Wed Aug 19 14:24:23 2015
@@ -2036,6 +2036,7 @@
   }
 
   ptile = unit_tile(punit);
+  towner = tile_owner(ptile);
 
   if (!is_allowed_city_name(pplayer, name, message, sizeof(message))) {
     notify_player(pplayer, ptile, E_BAD_COMMAND, ftc_server,
@@ -2056,10 +2057,12 @@
   }
   wipe_unit(punit, ULR_USED, NULL);
 
-  if ((towner = tile_owner(ptile))) {
-    action_consequence_success(ACTION_FOUND_CITY, pplayer, towner,
-                               ptile, tile_link(ptile));
-  }
+  /* May cause an incident even if the target tile is unclaimed. A ruleset
+   * could give everyone a casus belli against the city founder. A rule
+   * like that would make sense in a story where deep ecology is on the
+   * table. (See also Voluntary Human Extinction Movement) */
+  action_consequence_success(ACTION_FOUND_CITY, pplayer, towner,
+                             ptile, tile_link(ptile));
 
   return TRUE;
 }
@@ -2377,7 +2380,10 @@
   wipe_unit(punit, ULR_DETONATED, NULL);
   do_nuclear_explosion(pplayer, def_tile);
 
-  /* May cause an incident */
+  /* May cause an incident even if the target tile is unclaimed. A ruleset
+   * could give everyone a casus belli against the tile nuker. A rule
+   * like that would make sense in a story where detonating any nuke at all
+   * could be forbidden. */
   action_consequence_success(ACTION_NUKE, pplayer,
                              tile_owner(def_tile),
                              def_tile,


_______________________________________________
Freeciv-commits mailing list
Freeciv-commits@gna.org
https://mail.gna.org/listinfo/freeciv-commits

Reply via email to