Ticket #44769

Fix illegal movements by edit.unit_move()

Date d'ouverture: 2022-06-07 04:01 Dernière mise à jour: 2022-12-04 07:52

Rapporteur:
Propriétaire:
Type:
État:
Atteints
Composant:
Priorité:
5 - moyen
Sévérité:
5 - moyen
Résolution:
Fixed
Fichier:
2

Détails

I was pretty sure that calling (Archers):move(TileNearbyWithEnemyMigrants, 1) will make the Archers capture the Migrants, or at worst case it will be blocked, but in fact it puts the archers on the same tile with enemy units without capturing them. Likely, it can create other illegal positions. Btw, I can't understand, would 3.0 or later method ever do some actions you'd expect from emulating arrow key pressed by Lua.

Ticket History (3/8 Histories)

2022-06-07 04:01 Updated by: ihnatus
  • New Ticket "Fix illegal movements by edit.unit_move()" created
2022-06-07 04:10 Updated by: cazfi
Commentaire

Reply To ihnatus

would 3.0 or later method ever do some actions you'd expect from emulating arrow key pressed by Lua.

Given how goto-moves cannot handle them (e.g. #44496), I'm not overly optimistic.

2022-08-05 08:59 Updated by: cazfi
2022-10-07 09:29 Updated by: cazfi
2022-11-26 23:01 Updated by: cazfi
  • Propriétaire Update from (Aucun) to cazfi
  • Résolution Update from Aucun to Accepted
Commentaire

Attached patches should do it - not properly tested yet. For S3_0 will need also to check that passing NULL as embark_to isn't compatibility break (is the traditional behavior to embark to automatically selected transport?)

2022-12-04 07:52 Updated by: cazfi
  • État Update from Ouvert to Atteints
  • Résolution Update from Accepted to Fixed

Modifier

Please login to add comment to this ticket » Connexion