ID:179094
 
im making a side scroller but i dont want the camra to follow the usr when going up and down just side to side anyone know how?
You could try setting the eye var for the client whenever the player goes north or south. (You might want to make a decision on how to handle diagonals as well.)

You might want to do this in client.Move(). Then you can use get_dir() to find out the position of the mob's new location relative to the old one.

Alternatively, you might want to work in the North() and South() client procs.

Either way, you can get x, y and z coordinates from client.mob. Manipulate copies of those values for the location you want the camera eye to be at. Set the eye's new location by using locate() with the new x, y and z.
In response to ACWraith
not to be rude but i dont understand a word you say!
In response to Scoobert
Look up:

eye var (client)

You could do something like this:
client
North()
..()
eye = locate(mob.x,centered,mob.z)

You'd then have to define centered somewhere else in your code which would be wherever you want the eye to be fixed.

You would also need to do this for all the other procs like Sout, East, West, and so on.

One thing you have to watch out for is that when you set the eye like this it will no longer follow the mob at all on it's own so you to closely regulate (control) it.