Made in response to the need for a simpler to use FPS template, and as a compliment to Social’s template. Bear in mind this template is not simple, it is simpler to use.
If you ask a programmer how to make a first person shooter, they will stare at you like you just fell out of a tree. And hit your head very, very hard, in a particularly sensitive area. Or they’ll actually try to tell you, which is worse.
WASD: Move around
Space: Jump (Hold and release)
Mouse is aim.
And a recent addition… arrow keys are also aim.
Aiming is smoothed using a similar method to the track-to actuator’s “time” variable.
The scope of this template covers advanced character dynamics, including jumping, swimming, magnetic surfaces, and wallrunning/improvised techniques. The method of suspending the character is a raycast spring.
So far it features jumping and magnetic surfaces. Wallrunning is slowly being worked out little by little, and swimming is off in the future.
It doesn’t work for me. I mean, I litterally can’t move or aim… and when I click a ball of light appears at the tip of the gun and quickly disappears. Finally I get 9-11 FPS, but that’s my comp, not the file…
ob_1 is the object the target will be applied to.
ob_2 is the object the force will be applied “against”. If you don’t want one, you’ll have to give it a static object… this isn’t fixed yet.
Target: An orientation matrix.
Force: Force to apply.
Damping: Damping to apply.
Debug: If 1, this draws the ob_1 matrix, along with vectors showing the distance of each axis to the target axis.
Similar to the matrix spring, but the Target is a position in global space. (3 floats)
The bendy white line is a bezier; basically a line of points, subdivided and smoothed. If you want to use them, make a list of positions in space, then give them to bezPath(points, res). Res is resolution, the number of smoothed points. Then, you can either use drawpath() on what that function outputs, or work out an efficient method of attaching vertices to the path… if you want a path to begin with, that is.
It looks like the GameBlender people has taken BlenderArtists by storm, I mean that, looking at the huge amounts of python and it would look as if the design just puts Social’s ancient template to shame.
The magnetic stuff is something I’ve never seen in Blender games before, and it’s nice how its implemented, a bit of tweaking would turn it into an FPS M.C.Escher would’ve designed.
Keep up this excellent work, for me though I’m currently settled with Social’s old template which I ended up modifying a bit like overhauling the walking system and adding tons of stuff, but what you have is amazing so far. Maybe I will find a use to pick chunks of code from the scripts and use them in other .blends
NOTE: To others I would run it in GLSL mode, then it won’t be all pink.
(Side note: Didn’t mean more intelligent, more of the intelligent designers :] (And more intelligent))
This forum has many BGE users, but several are mainly artists, some who want to get into the BGE after doing renderings and animation. I do both art and games myself.
Escher was known for depicting the impossible, if you want a case related to your demo, floors becoming walls and then turning into ceilings, or going up a staircase only to have it twist at a landing so it goes in a different direction.