Jump to content

  • Log In with Google      Sign In   
  • Create Account

Making the player follow a "tracer"


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 Cdrandin   Members   -  Reputation: 443

Like
0Likes
Like

Posted 06 January 2013 - 02:49 PM

So, how I want my game to work is entirely using 2D physics. I want my game to work is that the environment is all 3D and so the player can do the normal left/right and up/down, but the catch is I want him to move along the Z axis as well, but without having input control over it, but rather it is indirectly down, by following this tracer when it chooses to move along the Z axis.

So let me try and paint a picture. Say, you have a narrow hallway that only goes left and right, so the restriction in movement only works for Horizontal and Vertical movement, BUT when we reach the end of the hall way there is another hallway leading out, so instead of having the player press up to move forward, we just press 'D' or '->' to make him turn into that hallway, which is done because he is following this "tracer". So in sense the movement Left and Right is working in relation to this tracer.

So think about this image http://img.nobodybuy.com/2010/01/07/sales34776/0x0_p606558/bead-game-bead-maze-toy.jpg and would only be controlled with a left and a right toggle on the keyboard, which in the image uses all 3 dimensions. So pressing '->' will move one of the beads to the right and continue to follow the path until it reaches the end. I have a slight idea on how to make it work, but was wondering if some one could help flesh out this idea. Also, I would need to rotate the player to look more realistic and the camera is attached to the player.

Edited by Cdrandin, 06 January 2013 - 02:50 PM.


Sponsor:

#2 Cdrandin   Members   -  Reputation: 443

Like
0Likes
Like

Posted 06 January 2013 - 09:31 PM

Anyone? Was hoping someone know some method in Unity which could act as a tracer. Meaning I am restricted to this path only and the toggled input act according to this tracer.

#3 Cdrandin   Members   -  Reputation: 443

Like
0Likes
Like

Posted 06 January 2013 - 10:42 PM

Just out of curiosity, I probably found a simple alternative. How would creating object collider, tag as "path" and have my player align with these collider in being constricted on this path way and I could use the Look at function to handle my character directions. I also could store these collider in an area and keep them in order so I could do something like [n] would be facing right and [n-1] would be facing behind, which is left.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS