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

                 Summary: Fix the lua export for is_enemy function
                 Project: Battle for Wesnoth
            Submitted by: faabumc
            Submitted on: Thursday 09/23/2010 at 12:32
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

Here is a patch file to fix the is_enemy implementation in lua in file
src/scripting/lua.cpp

While the first argument (that is a side id) is used as an index to the team
table, and must thus be brought from range [1,nb_side] to [0,nb_side-1], the
second argument must be a side number: it must not be changed.

Failing to do so, the two sides of a 2 player game are not identified as
enemies.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Thursday 09/23/2010 at 12:32  Name: patch_is_enemy.txt  Size: 732B  
By: faabumc
patch on src/scripting/lua.cpp against rev 46525
<http://gna.org/patch/download.php?file_id=10412>

    _______________________________________________________

Reply to this item at:

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

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


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

Reply via email to