HeroEngine Forums
Welcome, Guest. Please login or Register for HeroCloud Account.
Pages: 1 2 [3]

Author Topic: [Resolved] Shoulder Camera Examples (Code Provided)  (Read 9444 times)

Thazager

  • General Accounts
  • *
  • Posts: 1154
  • Never stop learning
    • View Profile
    • Heroes and Villains MMORPG
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #30 on: Mar 31, 13, 05:22:20 PM »

Do a search on SetCursorVisibility(false). It should be in one of the camera_input scripts. I believe changing it to true will show the cursor. It might be turned off in more than 1 location in code.
Logged

byberg

  • General Accounts
  • *
  • Posts: 63
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #31 on: Mar 31, 13, 05:51:41 PM »

nah that is not the problem.. from the beginning when i log in my char the cursor shows. BUT i cant rotate the camera with the mouse.

Logged

byberg

  • General Accounts
  • *
  • Posts: 63
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #32 on: Mar 31, 13, 06:15:35 PM »

Let me make that a bit clearer. I wanna be able to rightclick the mouse and move the mouse to rotate the camera. now it rotates on just moving the mouse but without rightclick.
Logged

Thazager

  • General Accounts
  • *
  • Posts: 1154
  • Never stop learning
    • View Profile
    • Heroes and Villains MMORPG
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #33 on: Mar 31, 13, 08:41:53 PM »

I have added that function in with 2 different ways of doing it. One way is when released the character snaps back to front (for the over the shoulder view) and the other they dont turn after releasing the button (done in the create character section).

With the create character section, I made the function in the mouse_input script, and used onMouseMove(with 4 input variables) and a getMouse type function inside that function which checks for the right button push.
Logged

Alderdale

  • World Owners
  • ****
  • Posts: 12
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #34 on: Jun 28, 13, 11:12:15 AM »

These were my notes when working through this tutorial, I believe them to be correct based on my understanding at this time but there also may be a few assumptions made on my part.  Maybe it will help someone new like me.  I made a number of modifications to this script to my own likings and still working on it.  Thanks Dragon and Zag!!

// NOTES FOR THIS SECTION READ FIRST!!!!
// Currently when loggin in you need to scroll all the way into FP view to kick off "function OnMouseWheel" which kicks off -
// Public Function "StartFP_Camera" which calls function "SetupFP_Camera()" which sets up your FP view. SetupFP_Camera also  -   
// sets the command state in this case being "SetCmdState("Camera","FirstPersonCameraEngaged",true). Or in the case of 3rd -
// person view  "SetCmdState("Camera","OverShoulderCameraEngaged",true)" Now that your camera -
// view is set up you can activate mouse free look by using the key bound to "ToggleMouseLock" in the GameKeyBindings.ini file. - 
// The if statement for "cmd==ToggleMouseLock" in "function onCmdStop" will then call the "public function FPS_ToggleMouseLock()" -
// which will then hide the cursor? and sets the "GetIgnoreCursor()" to true which now allows the "function OnMouseMove" to  -
// kick off the E_lerp camera "E_DragRotateCamera" method for free looking around.
// When using the mouse wheel to zoom out of FP view the same thing basically happens but instead the "function SetupOS_Camera" -
// is called for 3rd person view.
// OTHER NOTES: keybindings in GameKeyBindings.ini are defined in this script under the cmd = section below.


I am still working on trying to sync up the camera views when moving between the OS camera and FP camera.
« Last Edit: Jun 28, 13, 01:49:51 PM by Alderdale »
Logged

UnHapStudio

  • World Owners
  • ****
  • Posts: 6
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #35 on: Oct 28, 13, 05:53:43 PM »

OK thx for this topic ;)

I work on a MMOFPS ...

That realy good , but i have always a problem of rotation of my character , in FPS ref that ok , but in my world i think because of ACCControllerClassMethods i have my character when i move fast my mouse what go folow the camera for have a good alignement .... but i dont want that ...

Can i have break that and have an realy free look camera whitout recreate all the scripts with the FPS ref ?

Not easy to explain :p
Logged

WorldWideZ

  • World Owners
  • ****
  • Posts: 524
    • View Profile
    • World Wide Zed
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #36 on: Oct 29, 13, 01:37:14 AM »

Out of the box heroengine ACCC likes to try and figure out where your heading before playing turn animations

what your looking for is a Snapturn , updated per frame , to get your FPS arm to stay on the screen for the player character. This per frame update is also a good place to adjust a knob for aim adjusting the arm up and down.

i would say however while this will give the fps view for your player character , it will not look great for a second player character that is viewing. while i have yet to start a fix for this i would probably have a second ACCC for this that plays a turn animation more like the original.

the other option is to turn the player character model to not visible and use a separate "arms" model. 
Logged

UnHapStudio

  • World Owners
  • ****
  • Posts: 6
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #37 on: Oct 29, 13, 07:22:08 AM »

Thx for you solution ill go look
I just want put my mouse to the center of sreen and never move (no floating) , you know because with this script my mouse turn (with my speed moving) and see my char in front and when the camera see the toon front she align automatiquely the character to come back in view of back

just want fix the mouse to the center and dont have this floating, because this floating create the rotation come back  (for align ^^)

Sorry im french isnt easy to exmplain :p

If you have play to Mortal online you see my "vision"
Logged

UnHapStudio

  • World Owners
  • ****
  • Posts: 6
    • View Profile
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #38 on: Nov 03, 13, 06:47:56 AM »

UP

If you have one solution i take ^^

THX
Logged

keeperofstars

  • General Accounts
  • *
  • Posts: 998
    • View Profile
    • StarKeeper Online
Re: [Resolved] Shoulder Camera Examples (Code Provided)
« Reply #39 on: Nov 03, 13, 04:14:59 PM »

you can add a few lines to break the default character's turn option to give you a bit more of a free look, but you really do want the model to turn, just not how the default one does, her animations are really slow when it comes to turning at stand still, at move she is fine.
Just need to make a better animiation for your replacement character for "turning" while idle. No need to have this long winded foot shuffling.


Also we made a camera mount bone in our rigs, that is in front of the players face at eye level just in front of the model, that way we can leave the player model as visible (this allows the player to see their reflection in water, mirrors, shiny surfaces.
It also allows us to specifically locate the camera where we want it mounted. Helps out a bunch to make it feel more realistic.

Logged
[img]http://screencast.com/t/x7btcSSyp3h0[\img]
Pages: 1 2 [3]