summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Zaoui <daniel.zaoui@yahoo.com>2018-10-29 00:07:10 +0200
committerDaniel Zaoui <daniel.zaoui@yahoo.com>2018-10-29 00:07:10 +0200
commit3d02d1c50eb98265400f3ea03f3f79c557dbdc58 (patch)
tree3c18b051c5ccce1948ff8942607ef9e363eee06f
parent4fc682df842f3fa8befde9f21e07aa2a9fa57630 (diff)
Player: use the source scenario for the exu destination
When changes are made in the source actions list (stabilize-shots...), the modifications will be stored in the exu destination. This is not what we want. This patch fixes it by storing the original source scenario into the destination exu.
-rw-r--r--src/bin/player.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/bin/player.c b/src/bin/player.c
index 140a4b0..65205da 100644
--- a/src/bin/player.c
+++ b/src/bin/player.c
@@ -1232,7 +1232,13 @@ int main(int argc, char **argv)
1232 1232
1233 if (_dest && _dest_unit) 1233 if (_dest && _dest_unit)
1234 { 1234 {
1235 if (_src_unit) _dest_unit->actions = _src_unit->actions; 1235 if (_src_unit)
1236 {
1237 Exactness_Unit *tmp = NULL;
1238 if (_src_type == FTYPE_EXU) tmp = exactness_unit_file_read(_src_filename);
1239 if (_src_type == FTYPE_REC) tmp = legacy_rec_file_read(_src_filename);
1240 _dest_unit->actions = tmp->actions;
1241 }
1236 exactness_unit_file_write(_dest_unit, _dest); 1242 exactness_unit_file_write(_dest_unit, _dest);
1237 } 1243 }
1238 1244