[Freeciv-Dev] Re: (PR#14196) kill message is wrong
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://bugs.freeciv.org/Ticket/Display.html?id=14196 >
Jason Short wrote:
> <URL: http://bugs.freeciv.org/Ticket/Display.html?id=14196 >
>
> "Your <x> succeeded against <x> (and 3 other units)."
>
> This message is wrong: it is off by one. It shows one unit more than
> actually exists.
And a patch.
Index: server/unittools.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/unittools.c,v
retrieving revision 1.387
diff -p -u -r1.387 unittools.c
--- server/unittools.c 15 Sep 2005 17:41:28 -0000 1.387
+++ server/unittools.c 5 Oct 2005 20:26:42 -0000
@@ -1697,10 +1697,10 @@ void kill_unit(struct unit *pkiller, str
"(and %d other unit)%s and became more experienced!",
"Your attacking %s succeeded against %s's %s "
"(and %d other units)%s and became more experienced!",
- unitcount),
+ unitcount - 1),
unit_name(pkiller->type),
unit_owner(punit)->name, unit_name(punit->type),
- unitcount,
+ unitcount - 1,
get_location_str_at(unit_owner(pkiller),
punit->tile));
} else {
@@ -1708,10 +1708,10 @@ void kill_unit(struct unit *pkiller, str
PL_("Your attacking %s succeeded against %s's %s "
"(and %d other unit)%s!",
"Your attacking %s succeeded against %s's %s "
- "(and %d other units)%s!", unitcount),
+ "(and %d other units)%s!", unitcount - 1),
unit_name(pkiller->type),
unit_owner(punit)->name, unit_name(punit->type),
- unitcount,
+ unitcount - 1,
get_location_str_at(unit_owner(pkiller),
punit->tile));
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] Re: (PR#14196) kill message is wrong,
Jason Short <=
|
|