No. The code for a playstation 2 controller?
ex.(For a FPS)
X=fire
Joystick 1=move
Joystick 2=camera view.
This is what I have so far.
How can I make Joystick 2 be the camera?
How do I put it so Joystick 1 is spefified as the Joystick that movings you around?
rem moving
if Joystick left()=1 then xrotate camera 0,0 : move camera 0,0.2 : xrotate camera 0,cx#
if Joystick right()=1 then xrotate camera 0,0 : move camera 0,-0.2 : xrotate camera 0,cx#
if Joystick down()=1 then yrotate camera 0,cy#-90 : move camera 0.2 : yrotate camera 0,cy#
if JoyStick up()=1 then yrotate camera 0,cy#+90 : move camera 0.2 : yrotate camera 0,cy#
if wrapvalue(camera angle x(0))>40 and wrapvalue(camera angle x(0))<180 then xrotate camera 0,40
if wrapvalue(camera angle x(0))>180 and wrapvalue(camera angle x(0))<335 then xrotate camera 0,335
rem shooting
_control_gunandbullet:
rem Control gun firing
if Joystick fire X(square)=1 and bullet=-50
bullet=100
play sound GunSnd
position object BulletObj,camera position x(0),camera position y(0),camera position z(0)
rotate object BulletObj,camera angle x(0),camera angle y(0),0
set bsp object collision 2,BulletObj,0.1,1
if particles exist(1)=1 then delete particles 1
make particles 1, FireImg, 50, 0.5
set particle emissions 1,10
set particle speed 1,0.01
move object BulletObj,0.2
endif
rem Control life of bullet
if bullet>0
rem If bullet collides with BSP world
if bsp collision hit(2)=1 or bulletimpact=1
rem End bullet on wall
position sound ImpactSnd,object position x(BulletObj), object position y(BulletObj), object position z(BulletObj)
play sound ImpactSnd
bulletimpact=0
bullet=0
else
rem Move bullet
dec bullet
move object BulletObj,0.5
set particle emissions 1,1+(bullet/10)
endif
rem Update particle using bullet object position
rotate particles 1,90-object angle x(BulletObj),object angle y(BulletObj)+180,0
position particles 1,object position x(BulletObj),object position y(BulletObj),object position z(BulletObj)
rem Bullet dies
if bullet=0
set particle emissions 1,0
set bsp collision off 2
endif
else
rem Gun recharge phase
if bullet>-50 then dec bullet
endif
return
rem moving camera
Wisdom begins in Wonder-Socrates