View

Non-platform specific questions.

View

Postby BlarghNRawr » Sat Oct 18, 2008 7:59 pm

sound noobie, but what script do i use to make the view follow an actor on the x axis only???

(the actor is called Char_Luigi)
Download Game Music
current projects:
Bold! ?% Started mechanics
Unnamed puzzle game 60% --i need a name!--
User avatar
BlarghNRawr
 
Posts: 767
Joined: Wed Jun 25, 2008 12:36 am
Location: Not using G-E anymore. Now using Source SDK.
Score: 27 Give a positive score

Re: View

Postby jimmynewguy » Sat Oct 18, 2008 8:42 pm

if Char_Luigi is in the middle of the view then on draw actor view
Code: Select all
x = Char_Luigi.x -(what ever half the view is)

and that could be an easy way or just have 2 filled region actors, viewright and viewleft
then for Char_Luigi if he collides with viewright view.x += 5; and left view.x -= 5; would be another way
#2 is more effiecient and the way i use :D
Working on a probably too ambitious project! Wild-west-adventure-RPG-shooter-thing.
User avatar
jimmynewguy
 
Posts: 1137
Joined: Sat Mar 31, 2007 6:27 pm
Score: 89 Give a positive score

Re: View

Postby BlarghNRawr » Sat Oct 18, 2008 8:54 pm

ok thanx :D
Download Game Music
current projects:
Bold! ?% Started mechanics
Unnamed puzzle game 60% --i need a name!--
User avatar
BlarghNRawr
 
Posts: 767
Joined: Wed Jun 25, 2008 12:36 am
Location: Not using G-E anymore. Now using Source SDK.
Score: 27 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron