How do I jump ennemy to player ???

Get help using Construct 2

Post » Thu Apr 24, 2014 9:00 am

Message: matrixreal can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
hi all,
iam trying to do something in construct 2 but not find how to do it
i just need that when player touch some object on layer , the ennemey jump to him
thanks for help
like picture in attached ...Image
http://www.hostingpics.net/viewer.php?id=181675example.png
B
45
S
16
G
8
Posts: 792
Reputation: 8,306

Post » Thu Apr 24, 2014 12:41 pm

You can make it so when the player interacts with the object, set the enemy's position to Player.X and Player.Y

You might want to make it something like Player.X+10 or something like that so the enemy doesn't land directly on top of the player (unless that's what you want to do). Hope this helps :)
B
5
G
1
Posts: 22
Reputation: 467

Post » Fri Apr 25, 2014 1:03 am

you can use the behavior "platform" and simulate keys (run/jump). you have the physics values (jump strength etc). so you can calculate the right force to hit the object. calcluated distance between positions of enemy and object. ...
I'm sure that you can find some examples at the internet. calculate jump arc etc.
B
13
S
4
G
1
Posts: 107
Reputation: 1,337

Post » Mon Apr 28, 2014 2:09 am

thanks for reply i will work on it
(i do bullet on behaviors on ennemy with set to inital position to desable, and when player is on collision with some thing witch is invisible) ... then i do set platform y to value and at the same time set bullet speed to value ) :D ... and get what i want ...
but i think that what you suggest is better and more powerful and efficace....
B
45
S
16
G
8
Posts: 792
Reputation: 8,306


Return to How do I....?

Who is online

Users browsing this forum: Baidu [Spider], brunopalermo, David181 and 8 guests