Aligned objects

Get help using Construct 2

Post » Thu Oct 27, 2011 3:10 am

Hello
Can anyone show me how to set an event that does the following:

If Object X is facing(or aligned to)Object Y then perform action Z.
It doesn't have to work with tolerance.
Or direct me to a thread where this is discussed.

Thanks

saludos :D AlexmosuTSP2011-10-27 03:14:05
B
9
S
2
G
4
Posts: 19
Reputation: 2,648

Post » Thu Oct 27, 2011 3:20 am

It depends on what you mean by aligned.

Also Object.X is its horizontal coordinate, whereas Object.Y is its vertical coordinate.
What exactly do you want to achieve ?
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Thu Oct 27, 2011 10:30 am

It's like in the demo and tutorial game Construct 2 delivers, Ghost shooter.
The player is facing the mouse, is looking at the mouse.

Or when you use the "set angle towards position" action.

What I want is an event that detects when this happens without using "set angle".

Like when you use "rotate clockwise"r "rotate towards" on an object,and another object is moving around it, I want an event that performs an action when the one rotating gets to face the moving one, just like the player in ghost shooter is facing mouse.x and mouse.y.

What I meant by Object x is a random object, an object that i choose, not object.x, sorry for the confusion.

Thanks

saludos :DAlexmosuTSP2011-10-27 10:34:16
B
9
S
2
G
4
Posts: 19
Reputation: 2,648

Post » Thu Oct 27, 2011 10:46 am

I'm still unsure of what you want to do but does this helps ?

New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Thu Oct 27, 2011 11:42 am

[QUOTE=Kyatric] I'm still unsure of what you want to do but does this helps ?

[/QUOTE]

Ou yeah it helped already !
This is what I wanted :D
Where can i get a list of all the functions end expressions that you can use in Construct 2, like distance, angle, etc ?

Thanks !
saludos :DAlexmosuTSP2011-10-27 11:43:19
B
9
S
2
G
4
Posts: 19
Reputation: 2,648

Post » Thu Oct 27, 2011 11:47 am

In the expressions window (available when setting the value for a variable for example) when you double click on system.
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Thu Oct 27, 2011 12:21 pm

Thanks !

saludos
B
9
S
2
G
4
Posts: 19
Reputation: 2,648

Post » Thu Oct 27, 2011 3:06 pm

Great examples guys!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Tue Nov 08, 2011 11:00 pm

Kyatric, could you show a screenshot or something to show which "set variable value" dialog you mean?
I keep getting 404s for every "help" button i click in construct 2...
B
5
G
2
Posts: 11
Reputation: 1,181

Post » Wed Nov 09, 2011 2:33 am

http://dl.dropbox.com/u/42356832/Sin%20t%C3%ADtulo.jpg
You click add action, then any sprite or object, and choose a parameter.
Then you get that window, with low opacity, and when you click system, you get all the variables of system.
saludos :DAlexmosuTSP2011-11-09 02:34:57
B
9
S
2
G
4
Posts: 19
Reputation: 2,648

Next

Return to How do I....?

Who is online

Users browsing this forum: fredriksthlm and 27 guests