How do I prevent my AI to fall?

Get help using Construct 2

Post » Mon Apr 25, 2016 6:56 pm

Hello!
I'm making a game where one of the AIs need to walk around without falling, but i can't figure out how to make it happen. Can someone help me? :)
Thanks!

Image
Image
B
40
S
14
G
2
Posts: 121
Reputation: 3,501

Post » Mon Apr 25, 2016 8:26 pm

One way to do it is with the overlapping at offset condition. So say the ai sprite's size is 32x32 you could do this:


[inverted] ai is overlapping ground at offset (-32,32)
--- ai set angle to 0

[inverted] ai is overlapping ground at offset (32,32)
--- ai set angle to 180
B
92
S
32
G
107
Posts: 5,274
Reputation: 69,959

Post » Tue Apr 26, 2016 12:48 am

Thank you for your answer! I'm gonna try it :)
Image
B
40
S
14
G
2
Posts: 121
Reputation: 3,501

Post » Tue Apr 26, 2016 1:21 am

I just came back to say that it worked very well! Thank you, R0J0hound! :)
Image
B
40
S
14
G
2
Posts: 121
Reputation: 3,501


Return to How do I....?

Who is online

Users browsing this forum: jorgmaquoi, SignalOne and 17 guests