Some more game musings

Published December 28, 2014
Advertisement
game.jpg

Hope everyone had a good holiday period.

Been a period of musing and experiments with my game over mine. I wanted to at least try first person perspective to see how bad it was.

I'd previously used mouse messages and the reset-the-cursor-to-screen-centre approach which I now believe to be wrong. WM_INPUT provides a much better approach and means that during development, in windowed mode, I can have a camera tracking the mouse movement without having to give up the cursor or normal mouse interaction. Seems you can quite easily combine both raw mouse input and the WM_MOUSEMOVE et al so that makes development a little easier.

I got some support for WM_INPUT set up in preparation for a proper first-person camera and bodged the game to work from the perspective of the player, then discovered (as I'd half expected) that the game is unplayable and confusing from first-person-perspective as soon as you start swinging on your grapple.

Hey ho, thought it would probably be. So this game has decided for me that it wants to be a third-person-perspective game, which is cool since I quite like making and animating the player model now my model editor is half-approaching usable.

I booted up an old Steam copy of one of the Tomb Raider games to have a look at how the camera works from a developer perspective and seems that you can rotate freely around the player with mouse movement, and the character turns when you start to run. The direction the player is facing depends on the direction you moved last, and the four movement keys work relative to the look vector of the camera. The camera seems to be moved towards a fixed offset distance from the player, and vertical movement rotates you around that plane.

I'm hoping this will work okay with this game concept, because something you'll need to be doing more than usual in this game is looking up, in order to be firing the grapple into things that are above you. At the moment I'm doing a ray cast based on the actual mouse cursor to get the target for the grapple which I'm not sure is going to be a good final solution.

I had to make a big decision to give up trying to have the rope wrap around objects in the world. Its a shame, but it just isn't possible to get this quite right in full 3D it seems. Works fine in a 2D environment (physically speaking) as per my last prototype, but when you come to full 3D, you have the additional complication that the rope needs to slide along the edges of shapes, orthogonal to its direction, and slip over corners and things like that.

I almost got it working, but it just wasn't quite right and kept getting stuck and in the end I decided to just dump it. So now if the grapple intersects another object while you are swinging, it just retracts to be attached to the closest point to the player. I think once there is animation visuals here so that you see the end of the rope detach and retract back to the new connection point, it will look okay. Certainly makes the physics a hell of a lot easier and doesn't really remove any freedom from the main mechanic I hope. We'll have to see how it works out once I have the final camera control and some half-realistic level geometry in place to test it.

Frankly, the completely free grapple is the only USP of this game and if that can't be used, the game is toast since there is nothing else I have in mind to make a third person 3D platformer unique. I'm a firm believer that a good, manageable indie game needs to have one very strong idea that hasn't already been overdone in other games, or you are wasting your time. My old Squishy project was entirely based on the swinging around on your arms idea, and that was a good example. I'm hoping a 3D third person platformer with a grapple that can be fired in any direction and attach to any surface will have legs. Most games with grappling hooks have worked with predefined attach points.

If I can achieve the freedom in a way that is also easy to play, it will be okay. If not. hopefully I'll have dreamed up another idea by the time I figure that out :)

Thanks for reading and best wishes for the new year.
Previous Entry Winding things up
Next Entry Project fail
6 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement
Advertisement