Turn based pathfinding solution...please.

New releases and general discussions.

Post » Sat Nov 08, 2008 11:15 am

Can we please have a dedicated turn based pathfinding solution.

I'd like to make games like Battle for Wesnoth - [url:18tkcadi]http://www.wesnoth.org/[/url:18tkcadi], or Advance Wars, which just doesnt seem possible with RTS pathfinding.

The pathfinding needs to be contained to a grid or squares with modifiers etc. It's a different setup and requirments than RTS.

Thanks.
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Sat Nov 08, 2008 11:45 am

[quote="Ethan":1dtyeh2c]I'd like to make games like Battle for Wesnoth - [url:1dtyeh2c]http://www.wesnoth.org/[/url:1dtyeh2c], or Advance Wars, which just doesnt seem possible with RTS pathfinding.[/quote:1dtyeh2c]

Why not? Give your objects some variables to specify whether or not it's their turn, and only move those objects on their turn.

As far as grid movement, just set all your waypoints and destinations to grid coordinates. If you need to get, say, a 32x32 grid coordinate for the mouse, you can do it with floor((mouseX / 32) * 32), floor((mouseY / 32) * 32).
Moderator
B
5
S
2
G
6
Posts: 4,348
Reputation: 10,971

Post » Sat Nov 08, 2008 12:39 pm

Care to post a simple example please?

I think a big problem is the collision detection of it. It can't move inbeteen 2 squares, it seems to need double the size, or it tries to go around.

Theres also the turning radious values which is a problem, as well as having to have an accel and decel speeds, i think that messes up the stopping point.
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Sat Nov 08, 2008 1:09 pm

Ah, I guess your right. I haven't really used RTS all that much.
Moderator
B
5
S
2
G
6
Posts: 4,348
Reputation: 10,971

Post » Sat Nov 08, 2008 1:33 pm

I hope it gets added to construct because it will open up another genre of game that i don't think you can currently do at the moment.
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Mon Nov 10, 2008 9:34 pm

It's been requested and hopefully I'll get round to it soon. We're all pretty busy at the moment though so it might be a while.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Tue Nov 11, 2008 6:17 pm

Thanks.

It doesnt have to be a complex 'does everything turnbased strategy object', just a simple pathfinding one that allows you to get the grid squares per step. It doesnt even have to include movements.
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Sat Jan 23, 2010 4:10 pm

Know you've been busy, just thought i'd check back to find out if anything like this has been implemented yet?
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Sat Jan 23, 2010 7:10 pm

nope :s

I want to try it though, but first I have to do the 2.5d behavior.
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Sun Jan 24, 2010 11:03 am

That would be great!

Should i come back in another year? :D
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Next

Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 5 guests