Layers Angle, Mouse and Hero.

Get help using Construct 2

Post » Sun Jun 14, 2015 12:15 pm

Hello.

I have a Hero and he have to rotate toward Mouse position. Simple enough. Everybody know how to do this.

Problem is. I want Layers rotate too. I tried some methods, but they didn't work well and Layers Angle was insane and unplayable.

Image

This is like FPS-style rotation. Only for TDS. I know that is possible.

This will make player feel yourself more closer to the game. A lot more atmosphere from this. The benefits are endless.

It's even may be the wind of changes to the whole genre of TDS games!
Last edited by XpMonster on Sun Jun 14, 2015 5:44 pm, edited 6 times in total.
I'm a Magician, not a Developer.
B
22
S
8
G
25
Posts: 106
Reputation: 14,294

Post » Sun Jun 14, 2015 12:32 pm

Are you sure you'd want to rotate the layout and not a layer?
Just asking because rotating the layout would in my idea ruin any possibility to have a static HUD..
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jun 14, 2015 12:38 pm

@LittleStain
Oh yeah. That is mistake in the text. Sorry for this.
I'm a Magician, not a Developer.
B
22
S
8
G
25
Posts: 106
Reputation: 14,294

Post » Sun Jun 14, 2015 1:27 pm

I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jun 14, 2015 1:46 pm

@LittleStain

Something like this, but i would like to player have always the same angle (270 +/-). It's better for movement.

Thanks for helping me!
I'm a Magician, not a Developer.
B
22
S
8
G
25
Posts: 106
Reputation: 14,294

Post » Sun Jun 14, 2015 1:48 pm

XpMonster wrote:@LittleStain

Something like this, but i would like to player have the same angle as layers. It's better for movement.

Thanks for helping me!


I'm not sure what you mean, haha..
Wouldn't that simply be putting the player on the layer you are rotating?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jun 14, 2015 2:01 pm

@LittleStain

I want player to move depending on the mouse position.

W - Player moving towards mouse
A,D - Player moving left/right from mouse
S - Player moving backwards from mouse

If i'll use your example - it's will be too hard for player. Unconfortable. So, i have to make player's angle focused on 270.

I wonder will MouseLock plugin help here somehow?
I'm a Magician, not a Developer.
B
22
S
8
G
25
Posts: 106
Reputation: 14,294

Post » Sun Jun 14, 2015 2:09 pm

XpMonster wrote:@LittleStain

I want player to move depending on the mouse position.

W - Player moving towards mouse
A,D - Player moving left/right from mouse
S - Player moving backwards from mouse

If i'll use your example - it's will be too hard for player. Unconfortable. So, i have to make player's angle focused on 270.

I wonder will MouseLock plugin help here somehow?


My example above will do exactly what you ask..
Pushing left mousebutton will now make player move towards mouse..

If you make the player stationary at 270 degrees, how will it move towards the mouse?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jun 14, 2015 2:12 pm

@LittleStain

And how this happening in first-person shooters? All the same.
I'm a Magician, not a Developer.
B
22
S
8
G
25
Posts: 106
Reputation: 14,294

Post » Sun Jun 14, 2015 2:18 pm

First person shooters work in 3D the way like my example works in 2D..
The player turns toward the mouse position and moves in that direction..

You want the player to move towards the mouse, but the player shouldn't turn towards the mouse?
What if the mouse is not right in front of the player or even in the back of the player?
Should the player move backwards?
I'm not sure how you see this..
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Next

Return to How do I....?

Who is online

Users browsing this forum: Google [Bot] and 14 guests