Author: sveinung
Date: Mon May 11 04:31:13 2015
New Revision: 29045

URL: http://svn.gna.org/viewcvs/freeciv?rev=29045&view=rev
Log:
Get rid of action_enabler_append_hard()

The function action_enabler_append_hard() was used to append requirements to
the requirement vector of action enablers. Remove it.

Requested by Emmet Hikory <persia> and Marko Lindqvist <cazfi>

See patch #4997

Modified:
    branches/S2_6/common/actions.c
    branches/S2_6/common/actions.h
    branches/S2_6/server/ruleset.c

Modified: branches/S2_6/common/actions.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/common/actions.c?rev=29045&r1=29044&r2=29045&view=diff
==============================================================================
--- branches/S2_6/common/actions.c      (original)
+++ branches/S2_6/common/actions.c      Mon May 11 04:31:13 2015
@@ -351,18 +351,6 @@
 }
 
 /**************************************************************************
-  Some actions have hard requirements that can be expressed as normal
-  requirement vectors. Append those to the action enabler so the action
-  struct won't need those fields.
-
-  Reconsider this choice if many enablers for each action should become
-  common.
-**************************************************************************/
-void action_enabler_append_hard(struct action_enabler *enabler)
-{
-}
-
-/**************************************************************************
   Get all enablers for an action.
 **************************************************************************/
 struct action_enabler_list *

Modified: branches/S2_6/common/actions.h
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/common/actions.h?rev=29045&r1=29044&r2=29045&view=diff
==============================================================================
--- branches/S2_6/common/actions.h      (original)
+++ branches/S2_6/common/actions.h      Mon May 11 04:31:13 2015
@@ -193,7 +193,6 @@
 
 struct action_enabler *action_enabler_new(void);
 void action_enabler_add(struct action_enabler *enabler);
-void action_enabler_append_hard(struct action_enabler *enabler);
 
 bool is_action_enabled_unit_on_city(const enum gen_action wanted_action,
                                     const struct unit *actor_unit,

Modified: branches/S2_6/server/ruleset.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/server/ruleset.c?rev=29045&r1=29044&r2=29045&view=diff
==============================================================================
--- branches/S2_6/server/ruleset.c      (original)
+++ branches/S2_6/server/ruleset.c      Mon May 11 04:31:13 2015
@@ -5258,12 +5258,6 @@
           }
 
           requirement_vector_copy(&enabler->target_reqs, target_reqs);
-
-          /* Append the actions hard requirements when the rules are loaded
-           * to play the game. */
-          if (act) {
-            action_enabler_append_hard(enabler);
-          }
 
           action_enabler_add(enabler);
         } section_list_iterate_end;


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

Reply via email to