Author: sveinung
Date: Sun Sep  6 13:08:04 2015
New Revision: 29791

URL: http://svn.gna.org/viewcvs/freeciv?rev=29791&view=rev
Log:
Have unit expulsion cost a single move

That is the price of similar actions (like Capture Units).

See patch #6324

Modified:
    trunk/server/unithand.c

Modified: trunk/server/unithand.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/server/unithand.c?rev=29791&r1=29790&r2=29791&view=diff
==============================================================================
--- trunk/server/unithand.c     (original)
+++ trunk/server/unithand.c     Sun Sep  6 13:08:04 2015
@@ -406,6 +406,11 @@
 
   /* Where is the actor player? */
   fc_assert_ret_val(pplayer, FALSE);
+
+  /* The price of attempting an expulsion is a single move. Applies before
+   * the player is told if the target has a capital. */
+  actor->moves_left = MAX(0, actor->moves_left - SINGLE_MOVE);
+  send_unit_info(NULL, actor);
 
   target_tile = unit_tile(target);
 


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

Reply via email to