How to tell which way a player is facing!

I figured out how to tell which way a player is facing.


Put this in a Coordinate Tracker and make the 2 properties you see: Previous X Position and Facing Right? (You can name them whatever you want) in advance.
Also, I would really appreciate it if you give credit to me, Micro, in a credits page in your game. I hope this helps you! :+1:

9 Likes

Pretty sure the ideas tag is for topics asking for ideas, so I removed it.
Also, dang, this is short. It feels kinda wrong to ask people to credit you for a game mechanic since everyone can use this.

4 Likes

this only applies to platformer, you can face all cardinal directions on top-down

I agree with Grapefruitt
people don’t have to credit you for using your mechanic.
For example there’s a bunch of games that use slope jumps but no one credits the creator of slope jumps. Guides on the forums are for everyone to use , their is no need for crediting. This is kinda short , maybe as an addition to this guide you could make this work for top-down too.

Well possibly for half credit we could say “Thanks to Micro_Gimkit1 for showing me how!” or smth like that

personally this is a pretty cool guide

1 Like

Added platformer

Agreed

3 Likes

That makes way more sense than what grapefruit said, thanks!

You shouldn’t ask for credit because forums is to help people.

2 Likes

Kinda confusing to look at. Can you explain what the different parts of the code do?

In the coordinate tracker, it first looks at if the x-coordinate changes at all. If the x-coordinate did change, then it will look at the last time it recorded the player’s x-coordinate. If it is greater than where the player is currently, it will change the property, “Facing Right?” based on the condition. Then, it will record the players x-coordinate for the next time the player moves.

1 Like

Hello.
Uh…
This is a neat guide, but the problem is, there’s no real explanation. I’d like if you edited it, and maybe put an explanation.
You do you, though.
I’m not forcing anything.

Dang, this guide existed the entire time I was working on my Eyes guide?
:expressionless_face:
Anyways, great guide! But maybe try something like my El Goblino Summaries, and have a short paragraph or so explaining the guide from a player perspective instead of a game maker perspective, if you know what I mean?