How do I Follow the Object (Bullet)with Pathfinding Behavior

Get help using Construct 2

Post » Tue Oct 18, 2016 4:53 am

hi guys, i need help to resolve this problem

so i want to make MainChar going through the Object place(bullet), but the MainChar always stop at the point i click....(im already setting find path to object x,y)

Thanks before...
B
20
S
7
Posts: 15
Reputation: 1,332

Post » Tue Oct 18, 2016 10:56 am

Going to need more info than this..
B
47
S
18
G
84
Posts: 2,273
Reputation: 49,800

Post » Wed Oct 19, 2016 2:01 am

plinkie wrote:Going to need more info than this..


so, i make a games with touch and pathfinding behavior
and the i want to MainChar go to the object when we click the Object
but if the Object has Bullet behavior, the MainChar not follow the object but only follow the first place i click the Object, so the MainChar and Object not meet...

Thanks before......and sorry about my grammar and vocabularies...
B
20
S
7
Posts: 15
Reputation: 1,332

Post » Wed Oct 19, 2016 8:32 am

I think this can be resolved by having the MainChar move to touch.x,touch.y. You can store this in global variable if you want. This should make it go to the initial destination of the Object yeah?
B
47
S
18
G
84
Posts: 2,273
Reputation: 49,800

Post » Wed Oct 19, 2016 8:38 am

If the destination is inside an object that is solid, path will go the nearest available place on the obstacle grid outside that object.
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Wed Oct 19, 2016 8:43 am

plinkie wrote:I think this can be resolved by having the MainChar move to touch.x,touch.y. You can store this in global variable if you want. This should make it go to the initial destination of the Object yeah?


i have already resolve the problem, randomly helped me, so the method is make some button(checkbox) and if checked, so every 0.5 sec Mainchar find path to object

but thanks for your help too plinkie...and once again sorry about my grammar and vocabularies
B
20
S
7
Posts: 15
Reputation: 1,332

Post » Wed Oct 19, 2016 8:44 am

I think he is trying to reach a point with pathfiding that has moved since he clicked?. (a bullet) So when the character reaches that place he wants to end up at the bullet's current position. Not where he clicked?
Follow my progress on Twitter
or in this thread Archer Devlog
B
42
S
18
G
19
Posts: 1,060
Reputation: 14,054

Post » Wed Oct 19, 2016 8:48 am

99Instances2Go wrote:If the destination is inside an object that is solid, path will go the nearest available place on the obstacle grid outside that object.


for that near condition, im already use Ashley logic, thanks for your suggestion 99Instances2Go....
B
20
S
7
Posts: 15
Reputation: 1,332

Post » Wed Oct 19, 2016 8:49 am

tunepunk wrote:I think he is trying to reach a point with pathfiding that has moved since he clicked?. (a bullet) So when the character reaches that place he wants to end up at the bullet's current position. Not where he clicked?


you are right, already solved, thanks tunepunk
B
20
S
7
Posts: 15
Reputation: 1,332


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 33 guests