[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2016-01-16 Thread Sveinung Kvilhaugsvik
Update of patch #6104 (project freeciv): Status: Ready For Test => Done Open/Closed:Open => Closed ___ Reply to this item at:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2016-01-14 Thread Sveinung Kvilhaugsvik
Update of patch #6104 (project freeciv): Status: In Progress => Ready For Test ___ Follow-up Comment #66: I spent a lot of time trying to make it work so I could test it. (A typo in setting the name

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-11-28 Thread Sławomir Lach
Follow-up Comment #65, patch #6104 (project freeciv): Ok. My path is just working. I have checked that rivers get 50% defense bonus, while mountains just 2%. Code is def_bonus = (100 + tile_bonus) * (100 + base_bonus) / 100 - 100; Am I right river has bigger defense bonus than hills?

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-20 Thread Sławomir Lach
Follow-up Comment #62, patch #6104 (project freeciv): Each commit expect one was fixup. I send newest patch. Is it not too hard helping me with preparing a patch ;-D ? (file #25372) ___ Additional Item Attachment: File name:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-20 Thread Sławomir Lach
Follow-up Comment #64, patch #6104 (project freeciv): Repaired. I will have deeper look into my patch at end of this week. (file #25374) ___ Additional Item Attachment: File name:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-20 Thread Sveinung Kvilhaugsvik
Follow-up Comment #63, patch #6104 (project freeciv): Quick look: +#define SPECENUM_VALUE77 L_DEFEND_OK #define SPECENUM_VALUE75NAME N_("?unitflag:DefendOk") You forgot to update the name. ___ Reply to this item at:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-19 Thread Sławomir Lach
Follow-up Comment #59, patch #6104 (project freeciv): I send a newest version of patch. There's one matter: In experimental ruleset, units will select river on plains instead of hills/mountains. I don't know, why. (file #25351) ___

Re: [Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-19 Thread Marko Lindqvist
Quick note via email before I get to my development machine; the behavior you're seeing is probably exactly right - units not escaping where they cannot go. One thing to test would be to see if road on hills/mountains would change this behavior for wheeled units. - ML All typos in this email

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-19 Thread Sveinung Kvilhaugsvik
Follow-up Comment #60, patch #6104 (project freeciv): How to merge different commits: On the command line git rebase -i master This will open up a text editor. Each commit will be on a line starting with the command pick. To merge a commit into the commit above change the "pick" command to the

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-19 Thread Sveinung Kvilhaugsvik
Follow-up Comment #61, patch #6104 (project freeciv): > For details about rebasing see http://git-scm.com/book/en/v2/Git-Branching-Rebasing Wrong link. http://git-scm.com/book/en/v2/Git-Tools-Rewriting-History The reason things ended up in different commits is that you forgot to specify --amend

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-18 Thread Sławomir Lach
Follow-up Comment #58, patch #6104 (project freeciv): I solve break problem by setting escpaed variable to true and test if it's true at start of loop. If it's true, then continue. I thought what's best way to select destination tile. I think that first criteria should be maximum defense power

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #50, patch #6104 (project freeciv): Thanks! ___ Reply to this item at: ___ Message sent via/by Gna! http://gna.org/

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #52, patch #6104 (project freeciv): I see my patch not working correctly. Problem is in base_get_direction_for_step. This function calls same_pos, so it's the problem. I must investigate error in my code. ___ Reply to

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Marko Lindqvist
Follow-up Comment #53, patch #6104 (project freeciv): - Why are you putting new UTYF -values to such early indices? You owuld need less changes if you made them last ones before USER values. There's also a bit of bad news for you in that patch #6424 also making changes there most likely goes in

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #51, patch #6104 (project freeciv): Ok. Git is very helpful. I didn't know there's no need to push changes and possibility to generate patch. Thanks. Hope it's last patch before close. (file #25333) ___ Additional Item

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #54, patch #6104 (project freeciv): Ok. So I will wait until path #6425 was applied and them send my. ___ Reply to this item at: ___ Message

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #55, patch #6104 (project freeciv): I've used git-apply /path/to/patch/6424 in root directory of my freeciv tree and there's errors about missing files. ___ Reply to this item at:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Marko Lindqvist
Follow-up Comment #57, patch #6104 (project freeciv): Sorry if it's no longer a problem on your latest patch version, but related to: > - 'break' does not always work with the _iterate macros (as > they may hide multiple levels of loops) so you can't really > count on getting to next round in the

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-17 Thread Sławomir Lach
Follow-up Comment #56, patch #6104 (project freeciv): Ok. Now it should work. (file #25336, file #25337, file #25338, file #25339) ___ Additional Item Attachment: File name: 0001-Introducing-unit-flag-allowing-unit-to-escape-from-t.patch

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-16 Thread Sławomir Lach
Follow-up Comment #46, patch #6104 (project freeciv): I've prepared newest patch, so I attached it. (file #25319) ___ Additional Item Attachment: File name: freeciv-escaping-newest1 Size:20 KB

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-16 Thread Sławomir Lach
Follow-up Comment #47, patch #6104 (project freeciv): I have prepared patch with helptext. AI should be introduced in other patch/patch series. I don't know I was able to prepare thus patch for AI, but I will try. (file #25320) ___

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-16 Thread Sveinung Kvilhaugsvik
Follow-up Comment #48, patch #6104 (project freeciv): _AI should be introduced in other patch/patch series._ Agreed. ___ Reply to this item at: ___ Message sent

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-16 Thread Sveinung Kvilhaugsvik
Follow-up Comment #49, patch #6104 (project freeciv): > I have prepared patch with helptext. It doesn't apply. It is missing stuff. I suggest that you start using a tool to handle patch preparation. I wrote a guide for you here. Setup: Get a git clone of Freeciv. The easiest way of doing so

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-15 Thread Sveinung Kvilhaugsvik
Follow-up Comment #45, patch #6104 (project freeciv): +; "CanEscape" = If killstack is enabled and defender was lost, +; this flag gives 50% chance to escape and don't been +; killed. Unit will escape only if it have more moved point +; than move

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #43, patch #6104 (project freeciv): My patch is related to patch #6428. ___ Reply to this item at: ___ Message sent via/by Gna!

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #42, patch #6104 (project freeciv): This is the newest patch. I think, that it is done. I think AI should been implemented by someone else in another patch or patch series. My suggestion is to not put unit with can_escape flag on empty tile, when there's tile with stronger

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #44, patch #6104 (project freeciv): Sorry for my previous patch. There's no applied changes in events.spec, so I attached new one. (file #25300) ___ Additional Item Attachment: File name: freeciv-escaping-newest1

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #36, patch #6104 (project freeciv): Hi. I have trouble with adding new event within newest trunk. I added following line to common/events.h: #define SPECENUM_VALUE125 E_UNIT_ESCAPED And following line to common/events.c: GEN_EV(E_UNIT_ESCAPED, E_S_UNIT, N_("Unit escaped")),

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #38, patch #6104 (project freeciv): Thanks for replying. I add compilation error bellow: events.c:216:10: error: ‘E_UNIT_ESCAPED’ undeclared here (not in a function) GEN_EV(E_UNIT_ESCAPED, E_S_UNIT, N_("Unit escaped")), ^ events.c:68:77: note: in definition of

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sveinung Kvilhaugsvik
Follow-up Comment #39, patch #6104 (project freeciv): > I added following line Could I get a few more lines of context above and below the lines you added to event.[c|h]? > I wonder where E_COUNT are declared. It is declared in events.h by the following line: #define SPECENUM_COUNT E_COUNT

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sveinung Kvilhaugsvik
Follow-up Comment #37, patch #6104 (project freeciv): _There's compilation error attached below:_ Where? ___ Reply to this item at: ___ Message sent via/by Gna!

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sławomir Lach
Follow-up Comment #40, patch #6104 (project freeciv): Ok. I have look to specenum code and discovered that maximum number is too low(one lower than required), so I have changed specenun. I will send patch after testing everything, so probably tomorrow.

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-14 Thread Sveinung Kvilhaugsvik
Follow-up Comment #41, patch #6104 (project freeciv): Your change to generate_specenum.py should probably be a separate patch. ___ Reply to this item at: ___

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-13 Thread Sławomir Lach
Follow-up Comment #34, patch #6104 (project freeciv): I have watching over my patch was included into trunk of freeciv, but there's not. Why? I have new ideas to implement, but I won't start it before done/close previous. ___ Reply to

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-10-13 Thread Sveinung Kvilhaugsvik
Follow-up Comment #35, patch #6104 (project freeciv): > I have watching over my patch was included into trunk of freeciv, but there's not. Why? Because you haven't addressed all the issues yet. Is there a misunderstanding here? I offered to finish your patch by fixing the issues my self in

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-08-26 Thread Sveinung Kvilhaugsvik
Follow-up Comment #33, patch #6104 (project freeciv): Updated. (file #24997) ___ Additional Item Attachment: File name: 0001-Rebase.patch Size:16 KB ___ Reply to this

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-08-24 Thread Sławomir Lach
Follow-up Comment #30, patch #6104 (project freeciv): sorry for asking you about this. Could you, please, repair it by yourselves? Files on which I made changes was changes, so preparing new patch could be horribly. and this is a little change. I had two directories with FC sources: trunk of

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-08-23 Thread Sławomir Lach
Follow-up Comment #28, patch #6104 (project freeciv): Is my path tested? Thanks. ___ Reply to this item at: http://gna.org/patch/?6104 ___ Message sent via/by Gna! http://gna.org/

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-26 Thread Sławomir Lach
Follow-up Comment #24, patch #6104 (project freeciv): I missing -u switch while preparing patch. With features are missing? Sorry for ask about this, but I don't see any missing features regarding to previous patches. (file #24660) ___

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-26 Thread Sveinung Kvilhaugsvik
Follow-up Comment #27, patch #6104 (project freeciv): Updated. (file #24667) ___ Additional Item Attachment: File name: 0001-Kill-stack-escape.patch Size:16 KB ___ Reply to this

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-26 Thread Sławomir Lach
Follow-up Comment #26, patch #6104 (project freeciv): Ok. I had added difference for ruleset files. (file #24664) ___ Additional Item Attachment: File name: patch_escaping_for_units-new2 Size:22 KB

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-26 Thread Sveinung Kvilhaugsvik
Follow-up Comment #25, patch #6104 (project freeciv): _With features are missing? Sorry for ask about this, but I don't see any missing features regarding to previous patches._ You had added documentation to units.ruleset. If you don't mind inserting them again your self I can go ahead and

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-25 Thread Sławomir Lach
Follow-up Comment #22, patch #6104 (project freeciv): I've prepared new version of path. Sorry I'm not prepared it earlier. (file #24657) ___ Additional Item Attachment: File name: path-escaping-unit-new1Size:11 KB

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-24 Thread Sveinung Kvilhaugsvik
Follow-up Comment #21, patch #6104 (project freeciv): After patch #6139 lands will be a perfect time for an update. It removes a unit type flag. Patch #5610 removed another. Your patch adds two unit type flags. (This allows the unity type user flag and unit type role flags to be updated by copy

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-17 Thread Sveinung Kvilhaugsvik
Follow-up Comment #20, patch #6104 (project freeciv): Have you had any progress on addressing the remaining points? (Example: don't expand the GEN_EV macro by hand) I ask because your patch is outdated. New events have been added. When patch #5610 land an old user unit type flag will be removed.

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-08 Thread Sławomir Lach
Follow-up Comment #19, patch #6104 (project freeciv): Ok. I have prepared a new path. (file #24623) ___ Additional Item Attachment: File name: patch_escaping_for_units6 Size:14 KB

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-06 Thread Sveinung Kvilhaugsvik
Update of patch #6104 (project freeciv): Planned Release: = 3.0.0 ___ Follow-up Comment #18: Looks like you didn't include everything in the new version. Targeting this patch to 3.0

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-05 Thread Sławomir Lach
Follow-up Comment #17, patch #6104 (project freeciv): I modify patch file. I also attached new version. (file #24613) ___ Additional Item Attachment: File name: patch_escaping_for_units5 Size:14 KB

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-01 Thread Sveinung Kvilhaugsvik
Follow-up Comment #15, patch #6104 (project freeciv): Thank you for the new revision. I hope the slow progression isn't too frustrating. _+notify_player(player_by_number(i), unit_tile(punit), E_UNIT_ESCAPED, + ftc_server,Some of your unit/units are escaped from_ are

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-07-01 Thread Sveinung Kvilhaugsvik
Follow-up Comment #16, patch #6104 (project freeciv): One more English issue: CanKillEscapping - CanKillEscaping ___ Reply to this item at: http://gna.org/patch/?6104 ___ Message sent

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-26 Thread Sławomir Lach
Follow-up Comment #14, patch #6104 (project freeciv): Sorry for previous post. Unfortunately I have attached server/unittools.c difference in first version opf patch, not in last version of patch. I send new version of patch. (file #24602)

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-26 Thread Sławomir Lach
Follow-up Comment #13, patch #6104 (project freeciv): I have changed values of enumeration, which You ask to change. I attached new version of patch. (file #24601) ___ Additional Item Attachment: File name: patch_escaping_for_units5

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-15 Thread Sveinung Kvilhaugsvik
Follow-up Comment #12, patch #6104 (project freeciv): The unit_role_id enumeration numbers should be increased. unit_role_id is supposed to include unit_type_flag_id. This is done by having the first unit_role_id follow the last unit_role_id.

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-13 Thread Sławomir Lach
Follow-up Comment #11, patch #6104 (project freeciv): I have added documentation into units.ruleset file, where needed. I attached new patch. (file #24572) ___ Additional Item Attachment: File name: patch_escaping_for_units4 Size:10

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-12 Thread Sveinung Kvilhaugsvik
Follow-up Comment #10, patch #6104 (project freeciv): _My IDE is KDevelop4. I will also search for option to removes white spaces before newline character._ Based on my experience with kwrite/kate and Qt Creator I would be extremely surprised if it isn't there. _What about AI? Is AI taking in

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-11 Thread Sławomir Lach
Follow-up Comment #8, patch #6104 (project freeciv): I have prepared new patch/ Only one problem is I was didn't documented new flag, but I will document this flag tomorrow(I must ask somebody the documentation string is correct because my poor English). 1. ok variable was renamed to escape 2.

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-11 Thread Sławomir Lach
Follow-up Comment #9, patch #6104 (project freeciv): What about AI? Is AI taking in mind killstack option or not? ___ Reply to this item at: http://gna.org/patch/?6104 ___ Message sent

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-10 Thread Sveinung Kvilhaugsvik
Follow-up Comment #7, patch #6104 (project freeciv): Someone must do a careful review. Here is what I was able to find. + bool ok; Readability: Could you come up with a more descriptive variable name? (I know it is hard to do when the brain is in programming mode) Suggestion: escaped +

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-05 Thread Sławomir Lach
Follow-up Comment #4, patch #6104 (project freeciv): Had a quick look. I spotted some coding style issues. (See doc/CodingStyle) Don't use tabs. Why start the then and else blocks with an empty line? 1. My editor probably adds tabulators, thanks for information 2. It's because my adult

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-05 Thread Sławomir Lach
Follow-up Comment #5, patch #6104 (project freeciv): Hi again. I have repaired(I hope) all problems. New patch version also allows to escape into tile, where living only units of the same nation. The one problem is message about unit successfull escape isn't send to unit owner. I have looked at

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-05 Thread Sveinung Kvilhaugsvik
Update of patch #6104 (project freeciv): Status:None = In Progress Assigned to:None = sveinung ___ Follow-up Comment #6: _Have I define new

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-03 Thread Sveinung Kvilhaugsvik
Follow-up Comment #1, patch #6104 (project freeciv): Had a quick look. I spotted some coding style issues. (See doc/CodingStyle) * Don't use tabs. * Why start the then and else blocks with an empty line? ___ Reply to this item at:

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-03 Thread Sveinung Kvilhaugsvik
Follow-up Comment #2, patch #6104 (project freeciv): * } else { should be on the same line. ___ Reply to this item at: http://gna.org/patch/?6104 ___ Message sent via/by Gna!

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-06-03 Thread Sveinung Kvilhaugsvik
Follow-up Comment #3, patch #6104 (project freeciv): Had a deeper look. The patch only changes unit deletion. Previous code assumes that the unit will be wiped. Example: A player is be told that his unit died when it (because of the patch) still may escape.

[Freeciv-Dev] [patch #6104] [Killstack] Patch allows unit to escape instead of been killed

2015-05-30 Thread Sławomir Lach
URL: http://gna.org/patch/?6104 Summary: [Killstack] Patch allows unit to escape instead of been killed Project: Freeciv Submitted by: lachu Submitted on: Sat 30 May 2015 10:19:28 AM UTC Category: general