[Freeciv-Dev] [patch #7226] Pass city production as pointer to most functions

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: Pass city production as pointer to most functions
 Project: Freeciv
Submitted by: cazfi
Submitted on: Fri 13 May 2016 06:32:52 AM EEST
Category: general
Priority: 5 - Normal
  Status: In Progress
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 2.6.0, 3.0.0
 Contains string changes: None

___

Details:

Do not pass city production as value (copy of a struct) but as pointer in most
cases.

I ended up writing this patch via dependency chain:
Fix AI production problems -> Debug AI production problems -> Make AI
production problem debugging easier

and I suspect that eventual AI fixes would require extra work to backport to a
branch without this change. So I'm about to backport this to S2_6 to provide a
baseline to those AI fixes to build on.



___

File Attachments:


---
Date: Fri 13 May 2016 06:32:52 AM EEST  Name: PointerUniversal.patch.bz2 
Size: 15kB   By: cazfi



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7079] civ2civ3 - Disallow Triremes to navigate rivers

2016-05-12 Thread Jacob Nevins
Follow-up Comment #8, patch #7079 (project freeciv):

> The old river-moving one is unbuildable, so it can be in the 
> game only if it's old savegame (or via editor).
I vaguely wonder about doing something to weed out old Riverboat units, like
adding a retirement effect that disbands them 10 turns after the old savegame
is loaded (...this probably isn't possible), or giving them zero moves in the
new ruleset but allowing them to be disbanded for production points, or
something like that. Just to avoid the incentive to hang on to your special
unique riverboats forever.

___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7205] Correct references to 'ai_choice' to 'adv_choice'

2016-05-12 Thread Marko Lindqvist
Update of patch #7205 (project freeciv):

  Status:  Ready For Test => Done   
 Assigned to:None => cazfi  
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24666] msys2 installer creation tries to use old langstat_freeciv.txt

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: msys2 installer creation tries to use old
langstat_freeciv.txt
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 08:56:59 PM EEST
Category: bootstrap
Severity: 3 - Normal
Priority: 5 - Normal
  Status: Ready For Test
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Release: 
 Discussion Lock: Any
Operating System: None
 Planned Release: 2.6.0, 3.0.0
 Contains string changes: None

___

Details:

It has been renamed as langstat_core.txt.
Fix attached.

Also, ruledit installer creation was getting data from core/freeciv domain
file instead of its own ruledit domain. This is fixed both in TRUNK version
and in S2_6 version (it's the only reason S2_6 version of the fix exist)



___

File Attachments:


---
Date: Thu 12 May 2016 08:56:59 PM EEST  Name: LangstatCore.patch  Size: 5kB  
By: cazfi


---
Date: Thu 12 May 2016 08:56:59 PM EEST  Name: LangstatRuledit-S2_6.patch 
Size: 1kB   By: cazfi



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24648] Deprecation error from sandbox settings

2016-05-12 Thread Marko Lindqvist
Update of bug #24648 (project freeciv):

  Status: In Progress => Ready For Test 

___

Follow-up Comment #1:

Fix

(file #27386)
___

Additional Item Attachment:

File name: LockBarbarians.patch   Size:0 KB


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24648] Deprecation error from sandbox settings

2016-05-12 Thread Marko Lindqvist
Update of bug #24648 (project freeciv):

  Status:None => In Progress
 Planned Release:2.6.0, 3.0.0 => 2.6.0  


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24655] freeciv-ruleup windows crash debugger handling not compiled in

2016-05-12 Thread Marko Lindqvist
Update of bug #24655 (project freeciv):

  Status:  Ready For Test => Fixed  
 Assigned to:None => cazfi  
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24665] unit_move_handling() callers not setting move_diplomat_city correctly

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: unit_move_handling() callers not setting
move_diplomat_city correctly
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 04:54:02 PM EEST
Category: general
Severity: 3 - Normal
Priority: 5 - Normal
  Status: None
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Release: 
 Discussion Lock: Any
Operating System: None
 Planned Release: 
 Contains string changes: None

___

Details:

1) move_diplomat_city parameter should be renamed as it's now generic (move in
instead of doing adjacent activity) marker, not specific to diplomats
2) I think some callers are not properly adjusted to its new meaning, but
still assume it to be meaningless when the unit being moved is not a diplomat

For example, attack of an AI unit might be prevented by the fact that the unit
could do some activity and the caller has not set move_diplomat_city to mean
that it wants to move in to the city to conquer it.

The AI and move_diplomat_city checks should probably take place before
calculating all the potential activity targets etc. Maybe even as an outer
block to

if (utype_may_act_at_all(unit_type_get(punit)) {
}





___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7225] Set allow_foreign_trade to 'FTL_NATIONAL_ONLY', not boolean FALSE

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: Set allow_foreign_trade to 'FTL_NATIONAL_ONLY', not
boolean FALSE
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 04:29:29 PM EEST
Category: ai
Priority: 5 - Normal
  Status: Ready For Test
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 2.6.0, 3.0.0
 Contains string changes: None

___

Details:

This is just about using correct namespace, should have no functional effect.



___

File Attachments:


---
Date: Thu 12 May 2016 04:29:29 PM EEST  Name: AllowNationalOnlyNotFalse.pacth 
Size: 578B   By: cazfi



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24664] cowt_callback() does not check homecity changing action enablers

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: cowt_callback() does not check homecity changing
action enablers
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 04:04:17 PM EEST
Category: ai
Severity: 3 - Normal
Priority: 5 - Normal
  Status: None
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Release: 
 Discussion Lock: Any
Operating System: None
 Planned Release: 
 Contains string changes: None

___

Details:

cowt_callback() assumes that unit can change homecity when ever the city and
unit have same owner.




___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24663] Speculative homecity not fully respected

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: Speculative homecity not fully respected
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 04:01:58 PM EEST
Category: general
Severity: 3 - Normal
Priority: 5 - Normal
  Status: None
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Release: 
 Discussion Lock: Any
Operating System: None
 Planned Release: 
 Contains string changes: None

___

Details:

cowt_callback() (and maybe some other AI code) tries to speculate on changing
the caravan homecity before heading for a ACTION_TRADE_ROUTE mission. That is;
it would want to know value of traderoute between parameter->src and
parameter->dest, as given by get_discounted_reward(), and not between current
unit->homecity and parameter->dest.
get_discounted_reward() calls is_action_enabled_unit_on_city() that internally
checks the trade route legality based on units current homecity.

To support also future speculative cases, this would probably be best to
correct by renaming full implementation of is_action_enabled_unit_on_city()
under a new name and to make that function to take unit homecity as a
parameter. The usual is_action_enabled_unit_on_city() could then be just a
wrapper around it, passing unit's current homecity.




___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #24662] get_discounted_reward(): ACTION_HELP_WONDER when only ACTION_TRADE_ROUTE available

2016-05-12 Thread Marko Lindqvist
URL:
  

 Summary: get_discounted_reward(): ACTION_HELP_WONDER when
only ACTION_TRADE_ROUTE available
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thu 12 May 2016 03:52:13 PM EEST
Category: ai
Severity: 3 - Normal
Priority: 5 - Normal
  Status: None
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Release: 
 Discussion Lock: Any
Operating System: None
 Planned Release: 
 Contains string changes: None

___

Details:

get_discounted_reward() first checks that at least one of the related actions
is possible (or'ring), and then proceeds on the assumption that all of them
are.
For example when ACTION_TRADE_ROUTE is possible but ACTION_HELP_WONDER is not,
it may decide that ACTION_HELP_WONDER is more beneficial than
ACTION_TRADE_ROUTE and sets result->help_wonder.

If not checked if the logic was similarly broken before action enablers in
S2_5 (meaning that despite separate unittype flags, having one of them set
would let function to select either)

One result I've been seeing in a ruleset (variant2 would do) without
ACTION_HELP_WONDER enabler, is that when homecity starts building a wonder,
caravans turn back thinking they can get the benefit of a wonder building by
ACTION_TRADE_ROUTE, and only when they actually try to ACTION_TRADE_ROUTE it
fails due to zero distance between caravan homecity and destination.





___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7224] Use ACTPROB_IMPOSSIBLE rather than magic value 0

2016-05-12 Thread Sveinung Kvilhaugsvik
URL:
  

 Summary: Use ACTPROB_IMPOSSIBLE rather than magic value 0
 Project: Freeciv
Submitted by: sveinung
Submitted on: Thu 12 May 2016 12:06:05 PM UTC
Category: general
Priority: 5 - Normal
  Status: Ready For Test
 Privacy: Public
 Assigned to: sveinung
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 3.0.0
 Contains string changes: No

___

Details:





___

File Attachments:


---
Date: Thu 12 May 2016 12:06:06 PM UTC  Name:
0002-Use-ACTPROB_IMPOSSIBLE-rather-than-magic-value-0.patch  Size: 753B   By:
sveinung



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7223] execute_orders(): remove redundant assignment

2016-05-12 Thread Sveinung Kvilhaugsvik
URL:
  

 Summary: execute_orders(): remove redundant assignment
 Project: Freeciv
Submitted by: sveinung
Submitted on: Thu 12 May 2016 12:05:18 PM UTC
Category: general
Priority: 5 - Normal
  Status: Ready For Test
 Privacy: Public
 Assigned to: sveinung
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 3.0.0
 Contains string changes: No

___

Details:





___

File Attachments:


---
Date: Thu 12 May 2016 12:05:18 PM UTC  Name:
0001-execute_orders-remove-redundant-assignment.patch  Size: 882B   By:
sveinung



___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7215] actions: ACTPROB_NA is impossible

2016-05-12 Thread Sveinung Kvilhaugsvik
Update of patch #7215 (project freeciv):

  Status:  Ready For Test => Done   
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7214] Add function to get UI name with mnemonic

2016-05-12 Thread Sveinung Kvilhaugsvik
Update of patch #7214 (project freeciv):

  Status:  Ready For Test => Done   
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7213] Use action_get_ui_name() instead of repeating it

2016-05-12 Thread Sveinung Kvilhaugsvik
Update of patch #7213 (project freeciv):

  Status:  Ready For Test => Done   
 Open/Closed:Open => Closed 


___

Reply to this item at:

  

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #7079] civ2civ3 - Disallow Triremes to navigate rivers

2016-05-12 Thread Christian Knoke
Follow-up Comment #7, patch #7079 (project freeciv):


David Fernandez:

> The ability of triremes to move on rivers introduces some exploits that I do
not know how to prevent: 
> 1) It is possible to bypass the rule "slow invasion" by moving from ocean to
river. 
> 2) It is possible to use chains of triremes to allow one unit to move an
unlimited number of tiles (along a river) in one single turn (by repeating
load-move-unload, load...) 
> 3) Even without chaining, a unit can move in the same turn inside a trireme
and then continue his own movement along the river. 
> It feels like using twice the bonus to movement on river and it causes a lot
of micromanagement. 
> I think the bonus to movement by river is a good representation of sails
being used to move the units faster. I suggest to remove this capability of
triremes for good.


Units transported by triremes sailing on a river loose all their move points
ATM the trireme moves.

Christian


___

Reply to this item at:

  

___
  Nachricht gesendet von/durch Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev