unit.txt file DESTINATION_RESOURCE issue

Post bug reports and ask for help with other issues here.
Post Reply
User avatar
Lothos
Posts: 1126
Joined: Tue May 23, 2006 8:22 pm

unit.txt file DESTINATION_RESOURCE issue

Post by Lothos »

In the header of the file it has the following comments about the command

; #DESTINATION_RESOURCE= Resource destination position for units listed by #UNIT_ID

; Units will arrive either within or adjacent to the #DESTINATION_RESOURCE or as close as possible in
; another friendly resource.

The part about it going to the nearest possible friendly resource appears not to be working. I seen this happen in both Russia and in Finland with tests. If the resource is taken before the unit command can execute then it never fires until the resource is taken back.
User avatar
Hubert Cater
Posts: 5886
Joined: Mon Jul 22, 2013 11:42 am
Contact:

Re: unit.txt file DESTINATION_RESOURCE issue

Post by Hubert Cater »

From what I remember the #DESTINATION_RESOURCE still needs to be a valid friendly resource, e.g. if it fills up then it goes to the next nearest friendly resource etc., but if you've lost it, then I believe that is the correct behaviour and the units will not arrive there as it has been lost.

But I also believe you can have multiple #DESTINATION_RESOURCE positions for that very possibility
User avatar
Lothos
Posts: 1126
Joined: Tue May 23, 2006 8:22 pm

Re: unit.txt file DESTINATION_RESOURCE issue

Post by Lothos »

Hubert Cater wrote: Mon Jan 15, 2024 2:45 pm From what I remember the #DESTINATION_RESOURCE still needs to be a valid friendly resource, e.g. if it fills up then it goes to the next nearest friendly resource etc., but if you've lost it, then I believe that is the correct behaviour and the units will not arrive there as it has been lost.

But I also believe you can have multiple #DESTINATION_RESOURCE positions for that very possibility
Can you enter multiple DESTINATION_RESOURCE ?

The file does not say you can and none of the ones I have seen in other areas use more than one.
User avatar
Hubert Cater
Posts: 5886
Joined: Mon Jul 22, 2013 11:42 am
Contact:

Re: unit.txt file DESTINATION_RESOURCE issue

Post by Hubert Cater »

Yes you can and it is in the Template notes for UNIT events:

; Units will arrive either within or adjacent to the #DESTINATION_RESOURCE or as close as possible in
; another friendly resource. More than one #DESTINATION_RESOURCE can be listed per event.
User avatar
Lothos
Posts: 1126
Joined: Tue May 23, 2006 8:22 pm

Re: unit.txt file DESTINATION_RESOURCE issue

Post by Lothos »

Hubert Cater wrote: Mon Jan 15, 2024 3:56 pm Yes you can and it is in the Template notes for UNIT events:

; Units will arrive either within or adjacent to the #DESTINATION_RESOURCE or as close as possible in
; another friendly resource. More than one #DESTINATION_RESOURCE can be listed per event.
Just tested this with multiple DESTINATION_RESOURCE and it worked like a charm

OMG this is so awesome!

Makes me wonder what other secrets you been holding out on us :D
rmelvin
Posts: 144
Joined: Wed Apr 06, 2022 1:41 am
Location: Tucson, Arizona

Re: unit.txt file DESTINATION_RESOURCE issue

Post by rmelvin »

:o :D
rmelvin
Posts: 144
Joined: Wed Apr 06, 2022 1:41 am
Location: Tucson, Arizona

Re: unit.txt file DESTINATION_RESOURCE issue

Post by rmelvin »

But no multiples line in AI Purchase, for it is not stated like in Unit template?

Do you update the Template with upgrade to the scripts?
User avatar
Hubert Cater
Posts: 5886
Joined: Mon Jul 22, 2013 11:42 am
Contact:

Re: unit.txt file DESTINATION_RESOURCE issue

Post by Hubert Cater »

Correct, it is just the one #DESTINATION_POSITION for AI purchase scripts
Post Reply

Return to “Tech Support”