Game Development Community

Player Movement Response

by Robert Rice · in Torque Game Engine · 04/22/2004 (12:14 pm) · 2 replies

I posted this else where, but no one responded, so let's try here!
"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!"
P.S.-I guess what I am really having trouble with, after looking further into it, is that a)the MoveManager has no knowledge of the current position,rotation,etc. of the player. b)I assume the player does maintain this knowledge, but I am having trouble finding out where to access it.

#2
04/22/2004 (1:51 pm)
Aww...jeez! Color me stupid. I've glanced at that resource before, but obviously not deep enough to find what I was looking for. Thanks, Cory!