Author: cazfi
Date: Sun Feb 15 09:27:34 2015
New Revision: 28154

URL: http://svn.gna.org/viewcvs/freeciv?rev=28154&view=rev
Log:
Lua API can now grant future tech to player instead of considering it already 
known.
The lua script is still not properly informed about this, it gets 'nil' 
returned.

See bug #23264

Modified:
    branches/S2_5/server/scripting/api_server_edit.c

Modified: branches/S2_5/server/scripting/api_server_edit.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_5/server/scripting/api_server_edit.c?rev=28154&r1=28153&r2=28154&view=diff
==============================================================================
--- branches/S2_5/server/scripting/api_server_edit.c    (original)
+++ branches/S2_5/server/scripting/api_server_edit.c    Sun Feb 15 09:27:34 2015
@@ -277,7 +277,7 @@
     }
   }
 
-  if (player_invention_state(pplayer, id) != TECH_KNOWN) {
+  if (id == A_FUTURE || player_invention_state(pplayer, id) != TECH_KNOWN) {
     do_free_cost(pplayer, id);
     found_new_tech(pplayer, id, FALSE, TRUE);
     result = advance_by_number(id);


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

Reply via email to