How do characters know when they are behind something?
Posted: Sat Mar 05, 2005 11:35 pm
HIya,
Can anyone plz help?
I have a lot of trees in a 3/4 view top down test. Trees are all one object (which is where I think I am going wrong.)
I would like to be able to script a function to test which object should be drawn above which, i.e. my character should walk in front of trees if he is below them in y position on the game screen and behind the tress if he is above them on the screen.
I have tried using yscreen comparisons and trying to swap zdepth on the fly but I have not succeded. Please can anyone help?
Thanks
IPete2.
Can anyone plz help?
I have a lot of trees in a 3/4 view top down test. Trees are all one object (which is where I think I am going wrong.)
I would like to be able to script a function to test which object should be drawn above which, i.e. my character should walk in front of trees if he is below them in y position on the game screen and behind the tress if he is above them on the screen.
I have tried using yscreen comparisons and trying to swap zdepth on the fly but I have not succeded. Please can anyone help?
Thanks
IPete2.