Contents |
Move
One basic Action that all units share is Move. After selecting the Move command during combat, the battle map displays all tiles in range of the unit given their current AP. From there, the player can select a tile to move to or back out of the Move command and return to the root combat menu. After selecting a tile, some kind of graphic (ghosted images of the character showing what kind of movement is performed on each tile, simple lines, or shapes) is displayed above the tiles that would be move across to show the path, and a menu pops up displaying the AP cost of the move and prompting the user to confirm the action.
Walking, Crawling, Jumping, Swimming, and Climbing are automatically executed according to what terrain the unit is traversing at the time. When selecting a path, a unit should choose the path that costs the least amount of AP to reach its destination or one that incurs the least amount of damage. This behavior could potentially be tweaked by the user (say, Minimize Hazard, Quickest Route, or Mixed) as an AI function, or another option is to display the path taken by a unit to reach its destination before executing the Move action, and then trust the player not to be stupid and walk through lava.
Walking
A unit walks when it is on solid, relatively level ground. It displays the Walking animation doing this.
A unit's Move score designates the distance, under optimal conditions, that a unit can travel on foot per point of AP expended.
The AP cost to move one space is designated by a number X, based on the terrain being traversed, and the Move score of a unit. AP cost = X - Move. If Move >= X, then AP cost for that movement is 1.
Crawling
A unit crawls when it moves when it's on solid, relatively level terrain that also has has a solid or hazardous object above it less than the height of the character.
Crawling is automatic. As part of the pathfinding algorithm, if traps or hazards are known to the characters (scanned, searched, whatever) and would be set off if the unit moves while upright, then the algorithm should factor in crouching to avoid damage.
The AP cost to move one space is designated by a number X, based on the terrain being traversed, and the Move score of a unit. AP cost = X - Move/2 (rounded down to nearest integer). If Move/2 >= X, then AP cost for that movement is 1.
Jumping
A unit Jumps when going over a gap that would cost more AP to walk through that jump over, and displays the Jumping animation doing this. A unit also jumps at the start of a Climb movement, and the same animation could be used as for long jumps, only with no horizontal movement.
A unit cannot directly jump over any obstacle that has a height greater than its Jump score. The unit must go around, or begin climbing at the height of Jump. Jumps count as 1 move action, and costs 2 AP (this number will probably change). A unit can jump horizontally, and the distance allowed is to the (Jump score)x(2).
A jump will only be automatically executed on ledges or in front of hazards like holes and miasma pits.
NOTE: If a unit falls off a high area, damage (type: Impact) is normally only taken if the Falling Distance > [1.5]Jump. The actual damage calculation based on the Hardness of the terrain landed on, and if it has any other hazardous effects, like spikes or miasma. ^ Move this to the Mechanics/Damage section, or at least link to it.
Climbing
A unit climbs when traversing steep surfaces (some arbitrary angle like 70 degrees to the horizontal). While not moving, and unit displays its Grip animation, and while moving, it displays the Climbing animation.
A unit's Climb score determines the distance, under optimal conditions, that a unit can travel while climbing. The AP cost to move one space is designated by a number X, based on the terrain being traversed, and the Climb score of a unit. AP cost = X - Climb. If Climb >= X, then AP cost for that movement is 1.
A unit with an overall Climb score of <= 0 cannot climb. A unit with an overall Climb score of 0 can hang onto ledges, but cannot climb in any direction. A unit with a Climb score < 0 cannot cling to ledges, and immediately falls.
While climbing, a unit's Jump command can be used to fall or (This is optional) push off from the wall in certain directions.
If a unit is climbing at the end of their turn then they use 1 AP to remain attached to the wall.
A unit who reaches 0 AP while climbing will fall. (unless we want to be nice to the player, and let them hang on until their AP changes again)
NOTE: If a unit falls while climbing, damage (type: Impact) is normally only taken if the Falling Distance > [1.5]Jump. The actual damage calculation based on the Hardness of the terrain landed on, and if it has any other hazardous effects, like spikes or miasma. ^ Move this to the Mechanics/Damage section, or at least link to it.
Swimming
A unit swims when it is in a liquid and there isn't a solid surface directly underneath its current position. It plays the Floating animation while not moving, and the Swimming animation while executing a move action in liquid.
A unit's Swim score determines the distance, under optimal conditions, that a unit can travel in these environments, per point of AP expended.The AP cost to move one space is designated by a number X, based on the terrain being traversed, and the Swim score of a unit. AP cost = X - Swim. If Swim >= X, then AP cost for that movement is 1.
While swimming, a unit can move up, down, left, right, forward, and backward. A unit's facing options will only be left, right, forward, and back, though, unless animation and design agree otherwise. There should be a quick method to raise or lower the destination height.
If overall Swim = 0, the unit cannot move in liquid, but will simply float, and can only move 1 space per turn. If overall Swim < 0, the unit sinks to the bottom and moves normally, but with a movement penalty, and will begin to take drowning effects unless otherwise prevented.
If a unit is swimming at the end of their turn then they use 1 AP to remain afloat.
Swimming units who is swimming and reaches 0 AP enters Drowning status.
NOTE: Need to figure out how swimming/walking on the bottom, drowning, and attacking in water works, but it doesn't necessarily need to be done for the tech demo.
Midair Move
Some units, though not the player characters in most instances, can fly, float, levitate, or glide. As a form of movement, these are effectively the same (basically, it depends on the unit's animation) and are collectively known as Midair Move(ments). A unit can engage in aerial movement when it isn't in a liquid and its height is one or more above the closest surface below it.
If a unit that has flying capability is near a wall, can choose to (or automatically will, depending on AI)
- Possibly change this movement type to a simple "fly" rather than "Midair Move", for streamlining?

