non-native attack failed

You can get help here if Freeciv doesn't start on your computer, or if you keep getting fatal errors while playing etc.
Post Reply
Wahazar
Elite
Posts: 362
Joined: Mon Jul 02, 2018 1:49 pm

non-native attack failed

Post by Wahazar »

I have ruleset with unit class, which has "AttackNonNative", "AttFromNonNative" flags (freeciv 2.6).
This unit can be transported, but sometimes attack from transport board doesn't work, there is following message in console instead:

Code: Select all

1: in request_transport() [transportdlg.c::104]: assertion 'unit_list_get(potential_transports, 0) == best_transport' failed.
What can be a reason of such behavior?
Augmented2 ruleset/modpack for freeciv2.6: http://forum.freeciv.org/f/viewtopic.php?f=11&t=91047
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Re: non-native attack failed

Post by Ignatus »

Likely, the client tries to board the ememy instead of attacking it. This is strange, control.c code calls request_transport() only if the destination move tile has unlivable terrain. What client do you use?
User avatar
Alien Valkyrie
Elite
Posts: 513
Joined: Sun Feb 10, 2013 10:21 pm
Location: Stuttgart, Germany

Re: non-native attack failed

Post by Alien Valkyrie »

Ignatus wrote:This is strange, control.c code calls request_transport() only if the destination move tile has unlivable terrain.
If I understand this correctly, that's precisely the case – an attack from a non-native tile against another non-native tile.
~ AVL
Wahazar
Elite
Posts: 362
Joined: Mon Jul 02, 2018 1:49 pm

Re: non-native attack failed

Post by Wahazar »

Ignatus wrote:Likely, the client tries to board the ememy instead of attacking it. This is strange, control.c code calls request_transport() only if the destination move tile has unlivable terrain. What client do you use?
Both Qt and Gtk has this effect.
Yes, attacking unit (turret) have no livelable terrain at all (it can't move by itself, only by transport), so it attack from unlivable at unlivable.
Augmented2 ruleset/modpack for freeciv2.6: http://forum.freeciv.org/f/viewtopic.php?f=11&t=91047
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Re: non-native attack failed

Post by Ignatus »

Ah yes, now I understand. Yes, it's a bug in client logic. HRM#881350
Wahazar
Elite
Posts: 362
Joined: Mon Jul 02, 2018 1:49 pm

Re: non-native attack failed

Post by Wahazar »

Another issue (maybe related) is that it is not possible to use goto to attack unit on non-native tile.
Augmented2 ruleset/modpack for freeciv2.6: http://forum.freeciv.org/f/viewtopic.php?f=11&t=91047
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Re: non-native attack failed

Post by Ignatus »

Put a patch on HRM. In my test, it worked. I hope it does not break other stuff where request_transport is called :?
Post Reply