Forum Index
SUBSIM Forum Search

The Web's #1 BBS for all submarine and naval simulations!
[ SUBSIM Review ] [ SUBSIM STORE ]
Current Forum | Archives 2002-2003 |

Strange Behaviour of AI (Pathfinding)

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.     Forum Index -> DW Mission Designers' Forum
View previous topic :: View next topic  
Author Message
winkelried



Joined: 30 May 2005
Posts: 7

PostPosted: Sun Aug 07, 2005 10:16 am    Post subject: Strange Behaviour of AI (Pathfinding) Reply with quote

Working on a scenario where I want a few ships (two PTGs and one SS) to stay in a harbor and then to leave the harbor when a trigger fires.

The two PTGs are in a formation and both the formation and the SS have a waypoint tactic assigned with the speed on the origin being 0.

When I now give the order to SetSpeed to leave the harbour and to get beyond the first waypoint the AI behaves strangely. The PTG suddendly start to turn around each other and the sub runs astray even its initial course. Everything seems to be happening completely randomly.

Any ideas how this could work ?


Last edited by winkelried on Sun Aug 07, 2005 11:37 am; edited 1 time in total
Back to top
View user's profile Send private message
inetd



Joined: 30 Jul 2005
Posts: 14
Location: Germany

PostPosted: Sun Aug 07, 2005 10:58 am    Post subject: Reply with quote

Do they leave the harbour without problems when you set the speed to something > 0 from the beginning? Maybe it's just a pathfinding problem.
Back to top
View user's profile Send private message
winkelried



Joined: 30 May 2005
Posts: 7

PostPosted: Sun Aug 07, 2005 11:25 am    Post subject: Reply with quote

inetd wrote:
Do they leave the harbour without problems when you set the speed to something > 0 from the beginning? Maybe it's just a pathfinding problem.


Thanks. Tried it - same behaviour. Any idea where I get some wisdom on pathfinding Confused
Back to top
View user's profile Send private message
winkelried



Joined: 30 May 2005
Posts: 7

PostPosted: Sun Aug 07, 2005 11:35 am    Post subject: Reply with quote

Got a fix:
The PTs had to get around a cape. Originally I let them pass a small cape at approx 400 yards (depth 180 feet) when I put them now at 700 yards (depth 280 feet) they work ok.
Back to top
View user's profile Send private message
Fish



Joined: 21 Sep 2001
Posts: 2412
Location: Netherlands

PostPosted: Sun Aug 07, 2005 1:35 pm    Post subject: Reply with quote

Pathfinding is only to forcome ships ran on land.
I made maps like that without problems, so I have no idea why it not works in your case.
If you want I can look into your map?
Back to top
View user's profile Send private message Visit poster's website
OKO



Joined: 10 Jan 2002
Posts: 468
Location: Solar system, mainly on earth

PostPosted: Sun Aug 07, 2005 4:06 pm    Post subject: Reply with quote

question : did you used a script with pathfinding instruction for this plateform ?
Back to top
View user's profile Send private message Visit poster's website
JoGary(sco)



Joined: 05 May 2005
Posts: 102
Location: Loch lomand, Scotland

PostPosted: Mon Aug 08, 2005 7:55 pm    Post subject: Reply with quote

I have had problems like this, some times when leaving a harbour if the first waypoint is to close it misses it and circles to try get to it. Try moving first waypoint further out and making the tolerance to 1nm or more if needed. I had the same problem when i was working on one of your scenarios Fish. Remeber the one that i moved the FFG out of the harbour because it kept hitting it when it started to move. Well i could get it out of the harbour with using some waypoint very close to starting position but when it came out it would circle back as it was missing the waypoints. When i took it out of harbour and moved the waypoints farther out it was ok.
btw, dont try setting out a curve of waypoints close together to make it turn once it comes out. Just use one at point u want it to change course then another farther out at least 3nm on the cource u want it to take. If they close together then u get same circling problem even with toleranc set to like 10nm Smile
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Fish



Joined: 21 Sep 2001
Posts: 2412
Location: Netherlands

PostPosted: Tue Aug 09, 2005 5:43 am    Post subject: Reply with quote

JoGary(sco) wrote:
I have had problems like this, some times when leaving a harbour if the first waypoint is to close it misses it and circles to try get to it. Try moving first waypoint further out and making the tolerance to 1nm or more if needed. I had the same problem when i was working on one of your scenarios Fish. Remeber the one that i moved the FFG out of the harbour because it kept hitting it when it started to move. Well i could get it out of the harbour with using some waypoint very close to starting position but when it came out it would circle back as it was missing the waypoints. When i took it out of harbour and moved the waypoints farther out it was ok.
btw, dont try setting out a curve of waypoints close together to make it turn once it comes out. Just use one at point u want it to change course then another farther out at least 3nm on the cource u want it to take. If they close together then u get same circling problem even with toleranc set to like 10nm Smile


You are right waypoints to close gives problems.
Back to top
View user's profile Send private message Visit poster's website
OKO



Joined: 10 Jan 2002
Posts: 468
Location: Solar system, mainly on earth

PostPosted: Tue Aug 09, 2005 12:34 pm    Post subject: Reply with quote

using pathfinding instruction must solve this problem

put a WP on each side of land, using pathfinding instruction, and you will see the ship is able to avoid ground contact by himself.

at start, use a script =>

name : initgame
event trigger
automatic
run script : pathfind

script =>
name : pathfind
pathfinding / for / your plateform / is on

now you can kill all WP to get out of the harbor, just put one at the end of the harbor and let the script do the thing.
should work for you as it works here.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.     Forum Index -> DW Mission Designers' Forum All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group