Game Development Community

Change How the Player Moves

by Robert Rice · in Torque Game Engine · 04/20/2004 (6:04 am) · 0 replies

Hi, all!
New to this engine, so I am kind of tinkering around right now; trying small projects to get familiar with the code. So, here is my question. Say, for instance, I wanted to make an old-style top down perspective shoot'em up (Commando, Ikari Warriors, etc). I already have the top-down perspective implemented using the GG resources. Now, I am playing with the player movement. I want to maintain the ability to rotate around the z(?) axis, but I want to change how the control effects it. In other words, if I push 'up' the player should face the top of the screen and go that direction. If I push 'left', he turns to the left and heads that direction. Both at once, and he heads diagonally. Anyone have suggestions on how to approach this? I've been looking in the getNextMove() in player.cc and the methods in the MoveManager class, and I'm sure this is where the changes need to go, but I am still looking at how to proceed. Thanks!