Saturday, November 9, 2013
Saturday, October 19, 2013
Originally the combat system was a separate screen where you would face up to 5 creatures of the type you clicked on. They player would have a number of action points per turn that they could spend on movement, attacking, or using items. On the combat screen an icon would display movement or attacking or what not, giving the player a visual indication of what actions they were performing that turn. Once the player was finished planning and ended their turn, each action would happen in turn, and the AI of the creatures would react to each action. This gave some interesting tactical elements for the player to think about, as they were planning their turn they would have to think about how the creature would react to each action and anticipate where to strike or use an item.
While there is a good amount of potential in this system and I will probably use it in a future game, it didn't quite fit with the Rogue-like direction of 1000 Dungeons. It took the player out of the dungeon screen and was pretty complicated. So I went on a hunt as to how other Rogue-like games, and specifically Rouge itself, handled combat. This gave me some excellent inspiration for the new combat system.
In the new combat system, the player never leaves the dungeon screen. It keeps some elements of the original system in that the player has a number of actions they can do, but not nearly as many as the original system. And they are discrete actions, as opposed to a pool of points that could be spend on different actions that cost a different amount of action points. When first starting the player can only perform a single action per turn, but as they progress and level up they can earn up to 3 actions in a single turn. An action would be moving one square, making an attack with the currently equipped weapon, using an item, equipping a new weapon, etc. Unlike the original system, the actions are not pooled up then executed, but happen all within that turn. Once the player turn is over, then the monsters make their moves.
Monsters in the game are able to hear, see and smell. When the player is moving through the maze, they leave a scent marker in each tile they move through. If a monster with a sense of smell wanders onto one of those tiles, they will begin to track the player through the maze, following the scent trail. The player will be able to craft items that will mask his scent, or affect the length of time the scent marker stays within a particular tile.
The monsters in the game deal specific type or types of damage, such as blunt, slashing, corrosive, etc. They are also weak against one or more types (a weapon of that type does more damage) and strong against one or more types(a weapon of that type does less damage). All of these strengths and weaknesses, sight, sound, or smell tracking, will have to be discovered and deduced by the player.
I think the new system will make the game a better and a more fun experience for the player. It provides a more cohesive experience with less screens and less things to manage while still giving the player a lot of tactical decisions and interesting things to discover and explore.
Saturday, September 28, 2013
At the end of part I we had the shadows moving with the player, and more or less conforming to the space and shape of the walls, but as the player moved toward the end of the screen, the shadows would completely disappear.
The problem turned out to be with how I was determining the area to select from. I was using the basic code in the existing pick area method of the composite sprite, and tweaking until I got the correct values. The basic algorithm is:
1. Convert the AABB of the current scene render state to an OOBB
2. Calculate the inverse of that OOBB using the batch transform of the composite sprite object that is the shadow map.
3. Convert that inverse OOBB to an AABB.
4. Perform a query area on the composite sprite using the AABB, that does NOT target the OOBB of the individual sprites.
The last part, not targeting the OOBB of the individual sprites, was the key to getting the pick are to always return the proper objects based on the position of the player, which the map tracks as the player moves.
Here is a video that shows the shadowing in action. This video includes the dynamic light radius that is in the game also. In the video, the light radius is the minimum and would represent going into a dungeon with no torch or other light means. Equipping a torch gives you a larger view radius and you can use certain objects to change the light color. this can have an effect, positive or negative, on certain monsters.