fix implementation bug in random number generator

Our simple_rng is described in comments (in .cpp file) as coming
from a desription in man pages, man rand(3). Here is a link to
that page:

http://linux.die.net/man/3/rand

Our implementation did not match the specification, because the
rand_pool_ variable was an unsigned int and not an unsigned long.

Since the rand_pool_ should basically be constantly overflowing
under normal operation of the rng, it is obvious to me that this
would affect the long term random results. It is not at all obvious
to me whether significant bias or defect would be introduced... but
it would not be surprising either.
update changelog
Hang Out MAI: bug fix in best move selection

In rare cases (when the unit has no hexes to move to, not even the one
it is on because it is in a zone to be avoided), this would cause an
error and crash the AI.
ai_helper: make AI move error messages more descriptive
simulate_combat_fake(): don't fill empty HP chances with zeros

That’s what wesnoth.simulate_combat() does, but is different from the
other functions in battle_calcs.  Only hp_chance[0] needs to be set,
even if it is zero.
attack_combo_stats(): also cache intermediate battle outcomes

Speeds up some calculations significantly.
battle_calcs: do not use variance of attack in attack rating

This was an idea we tried so that we’d start with the most uncertain
attack first, but it did not work very well.
Keep the code for now, just comment it out.
battle_calcs.attack_rating(): overhaul attack rating system

This was long overdue.  The return value is now much closer to
something describing the actual gain/loss (roughly) in units of gold.
Insert lua_unit's contained pointer directly

Not copying the unit improves the speed of wesnoth.put_unit by two orders
of magnitude from lua's perspective.

To do this, we have to take ownership of any owned pointer from lua_unit.
We do this by not running lua_unit's destructor, but just overwriting the memory it's in.
Give lua_unit a put_map member function

This allows us to remove the destructor-avoidance hack in wesnoth.put_unit
and simplify the function's handing of various lua_unit types.
Fix bug #21491: fix drag+drop for unit movements
add set_action_bonus_count when attacking

Duthlet noticed this was missing.
more robust replay.cpp functions

we now add nonundoable commands at the current position instead of
assuming at_end(), this way nonundoable replay entrys like speak
can now also be added while we are not at end.
Usually playturn_network_adapter ensures that we are always
are at_end() and i didn't get any error with the previous solution
but the new solution is just more robust in case something goes wrong.

We cannot just do this for normal commands because it might
bring the replay in disorder.
We cannot add nonundoable commands at end if we aren't at end
because in that case the user would see the message again in
do_replay_handle in a mp game.
tidyup replay.cpp
more robust replaying of moves

we now set skipsighted to true if there is no fog or shroud.
The intention is that if a player uses fog=no in debugmode we still get
the same move destination in replays.
fix replay of delayed shroud updates (21986)

we have to enable the undo stack during replays to make these work. This
was accidently disabled during pr 121.
fix linger mode in mp (21985)
save replaydata of the undostack

not saving these might result in currupt replays when redoing a move
from a saved game.
Fix strict compilation