The Infinity Blade Forums Have Moved

We've launched brand new Infinity Blade forums with improved features and revamped layout. We've also included a complete archive of the previous posts. Come check out the new Infinity Blade forums.
See more
See less

Mouse Controlled Vehicles

  • Filter
  • Time
  • Show
Clear All
new posts

  • Mouse Controlled Vehicles

    Is there any way to control a vehicle by using the mouse
    eg: push the mouse forward the vehicle goes down, like a plane?

  • #2
    You mean like the redeemer...


    • #3
      oh yea i fogot about that ,
      ill have a look at the way epic does the guided shell.

      heres some pics of what im working on:

      its the dropship from unreal II


      • #4
        no luck yet,
        can any one show me an example on how to control the pitch and yaw by moving the mouse?


        • #5
          Originally posted by tGazza
          no luck yet,
          can any one show me an example on how to control the pitch and yaw by moving the mouse?
          In PlayerController.uc a few lines down:

          var input float
              aBaseX, aBaseY, aBaseZ, >>> aMouseX, aMouseY, <<<
              aForward, aTurn, aStrafe, aUp, aLookUp;
          In User.ini:

          MouseX=Count bXAxis | Axis aMouseX Speed=2.0
          MouseY=Count bYAxis | Axis aMouseY Speed=2.0

          So, aMouseX and aMouseY control the mouse-movement for the player and the PlayerInput variable of PlayerController.uc handles and processes all the input, look in PlayerInput.uc....and the PlayerInput function does most of the work I'm not so sure about replication tho but that should get you started!


          • #6
            Thanks [6pk]Shambler but i found a better way

            simulated function ClientKDriverEnter(PlayerController pc)
                    local vector X,Y,Z;
            	local Rotator ViewRotation;
            	//log("Enter: "$pc.Pawn);
            	pc.myHUD.bCrosshairShow = false;
            	pc.myHUD.bShowWeaponInfo = false;
            	//pc.myHUD.bShowPersonalInfo = false;
            	pc.myHUD.bShowPoints = false;
            	pc.bBehindView = true;
            >>	pc.bFixedCamera = true;   <<here
            	pc.bFreeCamera = False;
            	ViewRotation = Rotation;
            i have another Question:

            how can i make a KeyBind class talk to my vehicle eg:
            player presses a key the vehicle moves forward?


            • #7
              You mean like the bulldog... :P


              • #8
                I've got my craft to yaw and pitch only by changing the values in the script and i want a way to control them without deleting my class then changing the values then recomplying the whole script again, some sort of key control, i don't know how to do that can anyone help?

                sorry about my bad english


                • #9
                  Key binding to loop move objects

                  I like to bind keys to an object that moves in a loop in the map. I like to control its speed through up and down arrow keys. What would be the best way to make it?


                  • #10
                    If you're making a karma based vehicle, look at the bulldog code, if you're not, well there's not much difference between your vehicle and a normal player pawn, so look at the player movement code. The code is spread across both the pawn and controller classes in either case.


                    • #11
                      tutorial for controller/pawn

                      I am kind of novish game programmer!
                      Is there any tutorial for making controller and pawn?