Spellcaster Studios

Make it happen…

Gameplay/Tech tweaks

Today I mostly worked on tweaking the targeting system of the game.

Gateway is a game that has a lot of shooting, so that has to be fun… The last thing we want is the player thinking “I was clicking on the enemy, why was the weapon missing?!”, even if it is 100% correct from a math point of view…

The problem is mainly the fact that we’re converting a 2d position (the mouse position) into a 3d one (a point in space). This is done by projecting a ray from the eye position through the mouse cursor and detecting where it collides with the ground. That gives us a 3d position. But if there’s an enemy in front, shouldn’t he be hit, like a player is “selecting” the enemy for shooting?

Of course, if we do this, the game becomes rather easy (especially in big enemies), so we need to make the player “hit” the enemy reasonably well with the cursor before we define it as the “target”… If this radius is too small, the player will have the feeling he’s not hitting because the game is failing hard, if it is too large it becomes too easy and a bit “sticky”…

So I tweaked, and tweaked, and tweaked to get what I feel is the right feeling, although this is one of those pieces of code that’s really debatable, since it depends on “feeling” and “intuition”…

Anyway, hopefully alpha and beta tests will give me more feedback on this…

screen304

Now listening to “Avantasia: The Metal Opera” by “Avantasia”

Link of the Day: YouTube’s 60 FPS mode was made for the demoscene:

Comment