patchBattle for Wesnoth - Patches: patch #2241, bug #16820: [kill] with...

 
 
Show feedback again

patch #2241: bug #16820: [kill] with fire_event=yes doesn't trigger end of scenario

Submitted by:  Samael <jinjubei>
Submitted on:  Mon Dec 6 17:01:00 2010  
Votes:  10  
 
Priority: 5 - NormalStatus: Wont Do
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon Oct 17 17:49:51 2011, comment #5:

Closing as won't do due to mentioned problems and submitter is MIA.

Anonymissimus <anonymissimus>
Project Member
Wed Apr 13 17:26:30 2011, comment #4:

jinjubei, did you have a look at the issues pointed by silene ?

if you are not willing to work some more on this i'll close the patch as won't do...

Jérémy Rosen <boucman>
Project Member
Sun Dec 12 12:07:06 2010, comment #3:

check_victory can't be called from anywhere. (The engine is not exception-safe.) It can only be called from some very specific places where we are sure there is no pending actions. WML is definitely not such a place.

Currently, check_victory is called at the end of every attack and every turn side. To fix the original bug, check_victory should also be called after every unit move (since the issue is caused by killing a unit in a moveto event).

One also has to make sure that the same behavior happens whether the unit is moved by the user, the AI, the network, or the replay. Putting the call in the src/actions.cpp:move_unit function might be a good place, but one should check all its caller to verify that they are safe to be interrupted by an exception.

Guillaume Melquiond <silene>
Sun Dec 12 05:12:14 2010, comment #2:

This patch does indeed work. (Tested with the Two_Brothers campaign)

Dr. Robert Marmorstein <atomopawn>
Sun Dec 12 01:21:06 2010, comment #1:

I tested this patch by modifying the first scenario of the Two_Brothers campaign to kill Arne on turn 6 and use fire_event=yes. It does the trick!

Dr. Robert Marmorstein <atomopawn>
Mon Dec 6 17:01:00 2010, original submission:

An attempt to fix this bug.

Samael <jinjubei>

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by anonymissimus (Posted a comment)
  • -unavailable- added by boucman (Posted a comment)
  • -unavailable- added by silene (Posted a comment)
  • -unavailable- added by atomopawn (Posted a comment)
  • -unavailable- added by atomopawn (Voted in favor of this item)
  • -unavailable- added by jinjubei (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 10 encouragements so far.

    Only logged-in users can vote.

     

    Error: not logged in

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon Oct 17 17:49:51 2011anonymissimusStatusIn Progress=>Wont Do
      Open/ClosedOpen=>Closed
    Wed Apr 13 17:26:30 2011boucmanStatusNone=>In Progress
    Sat Dec 11 21:37:38 2010atomopawnCarbon-Copy-=>Added atomopawn
    Mon Dec 6 17:01:00 2010jinjubeiAttached File-=>Added mypatch.patch, #11482
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup