patchFreeciv - Patches: patch #1254, generalize bounce_unit()

Show feedback again

patch #1254: generalize bounce_unit()

Submitted by:  Matthias Pfafferodt <syntron>
Submitted on:  Tue Aug 18 11:32:24 2009  
Category: generalPriority: 3 - Low
Status: PostponedPrivacy: Public
Assigned to: NoneOpen/Closed: Open
Planned Release: Contains string changes: None

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

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


Sun Jul 15 13:00:03 2012, comment #4:

I'm contemplating using bounce_unit() for a new use in bug #19922.

Jacob Nevins <jtn>
Project Administrator
Wed Sep 30 20:54:38 2009, comment #3:

Then, I think it would need at least comments about this, and maybe macros defined at the same place.

I leave this ticket open for the moment, waiting for a interesting need of it...

pepeto <pepeto>
Project Member
Wed Sep 30 07:55:13 2009, comment #2:

Let's check; bouncing is used in:

  • game_load_internal(); dist = 2; corrupt savegame; use dist = 1 to consider only the surrounding tiles?
  • throw_units_from_illegal_cities(); dist = 2; check units in a city after an owner change, ...; dist could here be equal to city radius so that the units are spread within this area
  • resolve_stack_conflicts(); dist = 2; after an alliance break; use dist = 1 (no teleporting!)
  • (possible use) transfer_unit(); I want to check this function again ...

As listed above the distance could be fixed to 1 for checks (savegame; stack resolve) and to the city radius.

Is it possible to go from alliance to war? If yes, dist = 1 for stack resolve would mean that the units could attack each over directly after this.

Matthias Pfafferodt <syntron>
Project Member
Tue Sep 29 21:38:13 2009, comment #1:

A such patch looks to me to be very messy. It just use magic numbers everywhere. Such changes would be good if it was a configurable server setting for every type of 'bounce'...

Do others agree with me?

pepeto <pepeto>
Project Member
Tue Aug 18 11:32:24 2009, original submission:

generalize the distance used in bounce_unit()

the patch for bug 14078 should also be applied

Matthias Pfafferodt <syntron>
Project Member


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

Attach File(s):

Attached Files


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by jtn (Posted a comment)
  • -unavailable- added by pepeto (Updated the item)
  • -unavailable- added by syntron (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 0 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
    Wed Sep 30 20:54:38 2009pepetoPriority5 - Normal=>3 - Low
      Assigned topepeto=>None
    Sun Sep 27 11:44:52 2009pepetoAssigned toNone=>pepeto
    Tue Aug 18 11:32:24 2009syntronAttached File-=>Added 0002-generalize-bounce_unit.patch, #6480
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup