URL:
  <http://gna.org/patch/?3185>

                 Summary: power_projection improvement
                 Project: Battle for Wesnoth
            Submitted by: ejls
            Submitted on: mer. 14 mars 2012 17:32:38 GMT
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

Hi,

I implemented the EasyCoding
<http://wiki.wesnoth.org/EasyCoding#power_projection_improvement> task
"power_projection improvement". It now takes into account the ToD at the turn
of attack and at the position of the attacking units.

The modification to the power_projection function is really small. But this
function is present three times (three exact copies), I wasn't sure what to do
about this, I modified the one in ai::readonly_context_impl, and I removed the
one in ai::testing_ai_default::aspect_attacks since it was already inherited
from ai::readonly_context_proxy. The static version in
ai::testing_ai_default::aspect_attacks (power_projection2) now takes into
account the position of the attacking unit but can't know if the unit will
attack on the next turn (beeing static, it misses the informations from
side_context).

It looks like ai::testing_ai_default::aspect_attacks needs more refactoring,
maybe another coding task to add in the wiki? :)

If you need to contact me, I'm lurking on IRC.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: mer. 14 mars 2012 17:32:38 GMT  Name: power_projection improvement.patch
 Size: 6 ko   By: ejls
power_projection improvement and deletion of
ai::testing_ai_default::aspect_attacks::power_projection
<http://gna.org/patch/download.php?file_id=15366>

    _______________________________________________________

Reply to this item at:

  <http://gna.org/patch/?3185>

_______________________________________________
  Message posté via/par Gna!
  http://gna.org/


_______________________________________________
Wesnoth-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-bugs

Reply via email to