Chiblue Posted February 7, 2010 Share Posted February 7, 2010 I am working on a project using gamelib, I understand that gamelib does not support hand or gun meshes... which would be useful... Anyway does anyone have any links to any cod ethat uses a either hands with a gun mesh or GDK prior to having some issues with this physics engine, I am trying to do the same thing in LE. Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
Niosop Posted February 7, 2010 Share Posted February 7, 2010 Well there's not built in code, but it's simple enough to parent the hand and weapon models to your controller and offset them enough so it looks right. Quote Windows 7 x64 - Q6700 @ 2.66GHz - 4GB RAM - 8800 GTX ZBrush - Blender Link to comment Share on other sites More sharing options...
Canardia Posted February 7, 2010 Share Posted February 7, 2010 Actually hands work a bit different than player models (which gamelib already supports). Hands rotate with the camera, so when the camera looks down, the hands also look down. So you can just parent the hands to the main camera, and move them a bit forward. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Chiblue Posted February 7, 2010 Author Share Posted February 7, 2010 Thanks, any examples of the code? Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
Canardia Posted February 7, 2010 Share Posted February 7, 2010 Somehow like (before the main loop): EntityParent(gun,game.scene.cam); MoveEntity(gun,Vec3(0,0,2)); Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Chiblue Posted February 7, 2010 Author Share Posted February 7, 2010 That's it... wow you make is sound so complex... Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
Chiblue Posted February 8, 2010 Author Share Posted February 8, 2010 So how do I use hands in the gamelib functions? Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
Canardia Posted February 8, 2010 Share Posted February 8, 2010 You can use normal engine commands to animate the hands. Look for example how it's done in fpscontroller.lua. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted February 8, 2010 Share Posted February 8, 2010 So how do I use hands in the gamelib functions? The FPSC packs normally have a HUD.x version of the weapon which is the weapon and hands as one assembly/animation unit, you could try converting to .gmf, I did that for the MP5 in this clip. I should imagine it would possible to use the whole assembly like this in Gamelib? Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Chiblue Posted February 8, 2010 Author Share Posted February 8, 2010 The FPSC HUD.x is what I used un GDK and once you have the object positioned and linked to your controller the rest is relatively simple to implement, the animation is a little tricky due to the transition from single show to automatic, plus some of the animations are a little limited... Just as a followup, why connect to the camera, would it not be better to connect to the controller and then just control the pitch directly... then have the camera point in the same direction? Anyway thanks I will try to get this working.. Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
Canardia Posted February 8, 2010 Share Posted February 8, 2010 Just as a followup, why connect to the camera, would it not be better to connect to the controller and then just control the pitch directly... then have the camera point in the same direction?Yes, that is a better way, but also more complicated. The simple approach I suggested with parenting the arms to the camera, works in its context, since games which don't have a player model but only arms (like Far Cry 2), don't also have a 3rd person mode. If the game has a 3rd person mode, then this approach would fail, and it would be better to parent the arms to the player model, even if there is no player model. At least the arms would then stay in 3rd person mode, and not follow the 3rd person camera. If the game has a player model (like Crysis), then the arms would fail in any case (unless your player model has no arms), and you would need an even more difficult approach by turning the arm bones of the player model. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Mumbles Posted February 8, 2010 Share Posted February 8, 2010 If the game has a 3rd person mode, then this approach would fail, and it would be better to parent the arms to the player model, even if there is no player model. At least the arms would then stay in 3rd person mode, and not follow the 3rd person camera. I thought that for a first person game, All ..other.. players are rendered with full bodies and weapons as normal, but the "local" player would have their body and weapon models hidden, instead replaced with a high detail 1st person weapon, with hands included and only modelled on one side. The big problem with not having hands as part of the weapon would typically be a reload animation. If your game wants to have some sort of realism, and you reload an AK, part of the process is to pull back a slide on the right hand side of the weapon. To do that would involve un-parenting the weapon from the right hand, so that the right hand is free to move, without moving the weapon. (of course, you could just roll the weapon left a bit, and use your left hand, but no one seems to do that...) No game I know of ever has a 3rd person player model take their right hand of the weapon, at any time... I only ever seen right-hand movement in 1st person, where neither hand is parented to anything. Quote LE Version: 2.50 (Eventually) Link to comment Share on other sites More sharing options...
Chiblue Posted February 8, 2010 Author Share Posted February 8, 2010 Actually the FPSC Hud.x models have animation sequences for: Show or draw weapon **** weapon single shot fire auto or semi auto fire reload putaway weapon Player moving motion Also they have limbs(bones) configured and named to support cartridge ejection and gun flask... The work pretty well for 1st person, I have been thinking how to swap from 1st to 3rd person, and the only way I can think of is to have a full body mesh hidden in 1st person and in 3rd person hid the hud and show the full body.. this way you don't need so many animations in 3rd person, although most meshes I have used from FPSC have all these built in... Actually the one thing that I struggled with in GDK was simulating between tactical carry and and ready carry modes for the weapon in 1st person. Although I did get this working by simply dropping the y offset of the model to suite the carry position. Quote If it's not Tactical realism then you are just playing.. Link to comment Share on other sites More sharing options...
corochex1 Posted February 6, 2020 Share Posted February 6, 2020 I am making an fps game in unity, and have the basic game down ad now I want to start actually modeling guns. The only problem is I only have experience with very basic modeling and animation. Quote Link to comment Share on other sites More sharing options...
corochex1 Posted February 6, 2020 Share Posted February 6, 2020 On 2/8/2010 at 9:53 AM, Marleys Ghost said: The FPSC packs normally have a HUD.x version of the weapon which is the weapon and hands as one assembly/animation unit, you could try converting to .gmf, I did that for the MP5 gun in this clip. I should imagine it would possible to use the whole assembly like this in Gamelib? When modeling a gun, do you model player hands and arms with it, or are arms done separately and connected in unity? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.