keep Talk/InteractCount when replacing actors

Fixes e.g. Keldorn and Mazzy greeting you with their in-dungeon
dialogs again when you meet them for the second time later on.
add a few more unscheduled checks

Fixes scripts attacking actors which aren't there (again).
implement MultiPlayerSync

This is mainly to fix cutscenes of the form:

LeaveAreaLUA(...)
MultiPlaySync()
MoveViewPoint(...)

Since the map hasn't changed yet when MoveViewPoint is reached,
the command fails (or gets overwritten later on when the map does
change). As a result the player is often left looking at the party
which isn't even supposed to be present in the scene while sounds
imply interesting things going on in other parts of the area.

Adding a wait in place of the MultiPlayerSync command makes sure
that the area changes before trying to set the new view point.
when removing items from containers don't always take the entire stack

Fixes e.g. TakePartyItem killing the entire supply of an item.
Revert "when initiating dialog immediately suspend script execution"

This reverts commit 7007465932b777a922d408e9de7df4a6ee675c31.
determine initial dialog state only once

When recalculating things in DialogChoose, state may already have changed,
possibly making the dialog invalid.

Fixes the bandit plot in BG2 (JAHEIRA.BCS, JAHEIRAJ.DLG states 201-204),
this time without affecting other scripts negatively.
handle ApplyDamage and ApplyDamagePercent actions like the Damage effect

Fixes "Unhandled damagetype" errors when using those actions. Also simplify
damage type calculation from item headers.
LUProfsSelection: don't show a dummy entry on the last line
move more of the item cleanup code into SanitizeItem

Prevents the statues in AR3001 from dropping STONRING items that later
become undroppable.
the last hitter is bogus at least as often as it is correct
LeaveAreaLUAPanicEntry does not block