Gridland/Gameplay

Interface
Tiles of different icons are placed within an 8×8 grid. The dude must then select two adjacent tiles to swap their positions, causing at least one of the formations to create at least three identical tiles in a row. Invalid moves that do not create matches cause the tiles to return to their original position. When a match occurs, the tiles are removed, causing tiles directly above the removed tiles to fall down. Any tiles that fall into a 3-in-a-row formation are also removed.

When a user selects a swap to make, that counts as a "turn." Each turn and each match will have different effects on the RPG action happening above the grid, depending on the day/night cycle. At the end of each turn, the sun/moon will advance across the sky. When the sun/moon reaches the far right side of the grid, the day/night cycle will switch.

The game is saved when a full cycle ends. If the game is closed or the dude dies before the end of the cycle, all resources, items, and experience for that cycle is lost. For example, if the game is closed during Day 3 or the dude dies during Night 3, progress will resume back at the beginning of Day 3.

During play, the game can be paused by clicking the button in the upper right corner of the screen.

The opening screen allows the player to interact with three possible game slots. They can continue the existing data (starting a new game if empty), empty the data (trash can symbol), export existing data, or import data into an empty slot. Click the hamburger menu button (☰) in the bottom right screen to bring up the options menu. This allows for difficulty toggle, sound and music control, and links to the Doublespeak website, social media sharing, and donation sites.

Daytime
During the daytime, tiles represent resources. Removed tiles go to filling up building blocks in the storehouse. It takes 30 matched tiles to fill up one block. The stick figure will automatically take filled blocks from the storehouse and evenly distribute them between building meters.

After each time the user completes a swap, including invalid moves, the sun will advance a turn. In addition, stick figure's health meter will decrease with each turn unless replenished by food tile matches.

The 5 resources collected during the daytime are:
 * Grain: replenishes dude's health,
 * Clay, Cloth, Stone, and Wood, which contribute to building blocks
 * Mana: After looting 4? shards during nighttime, matching 4 or more tiles in a single line will cause a mana shard tile to spawn. Matching 5 tiles in an L-shape will not spawn a mana shard.

At the bottom of the grid is a circle, which is the Gem. When mana is matched during the daytime, this refills the Gem, and allows the dude to cast magic spells:
 * Freeze: Action at the top of the grid stops, but matches in the grid can still be made. Duration 15000
 * Haste: Action at the top of the grid speeds up. Duration 30000
 * Reset the grid tiles
 * Advance the Day/Night phase

Buildings
There are 5 primary buildings in the game. Each building can be upgraded through the course of the game.

The first building the dude builds at the beginning of the game is the Shack, where your resources are collected. It also provides the Grain resource.
 * Shack

The bricklayer provides the Clay resource.
 * Bricklayer

The weaver provides the Cloth resource.
 * Weaver

The blacksmith provides the Stone resource.
 * Blacksmith

The sawmill provides the Wood resource.
 * Sawmill

Night time
During the nighttime, removed tiles will affect combat. Enemy tile matches will cause enemy spawns. One enemy will spawn for each match. The stick figure will automatically move to engage enemies in combat. Once engaged the stick figure and enemies will inflict damage upon each other. Sword or shield matches will refill the sword or shield meters. The sword increases damage inflicted on enemies, while the shield absorbs damage inflicted by enemies. Each use of the sword or shield will deplete its meter. The moon will only advance when an enemy is defeated.

Each resource switches during the night. As the resources are upgraded, so too are their night effects.

After an enemy is defeated, the dude gains experience points. When the xp meter to the right of the grid fills up, the play levels up (instantly killing all enemies on the screen at the time, but gaining no xp from the wipe). As well, the dude adds a heart to their heart meter. (Don't know increased defense/punch damage effects from leveling yet) MaxHealth = 20 + 10 * lvl

Enemies

 * Grain:
 * Zombie - 4 hp - 1 dmg - 2 xp
 * Haunted Armour - 7 hp - 1 dmg - 10 xp
 * Earth Elemental - 24 hp - 1 dmg - 20 xp
 * Demon - 45 hp - 3 dmg - 35 xp
 * Clay:
 * Rat - 2 hp - 1 dmg - 4 xp
 * Spider - 4 hp - 1 dmg - 16 xp
 * Water Elemental - 18 hp - 2 dmg - 34 xp
 * Imp - 36 hp - 2 dmg - 52 xp
 * Cloth:
 * Skeleton - 1 hp - 3 dmg - 3 xp
 * Lizardman - 3 hp - 4 dmg - 13 xp
 * Fire Elemental - 4 hp - 12 dmg - 27 xp
 * Warlock - 18 hp - 5 dmg - 43 xp
 * Stone:
 * Sword - maxSword = 3, 5, 7, swordDamage = 1 + (highestMod - 1) - Math.floor((highestMod - 1) / 3); 1, 2, 3, 3, 4, 5, 5, 6, 7... ( + punch damage )
 * Wood:
 * Shield - maxShield = building level * 3

The lich has additional effects. It causes some tiles to glow red, becoming explosive. Matching an explosive tile will deal 30 damage to the dude.

Loot
There is a %15 chance for a monster to drop loot when defeated, if the monster was spawned from a 3-tile match. %15 is added for every tile above 3 in the match. (Unknown if this includes L-shaped matches)
 * Health potion: heal half health (75% drop rate)
 * Bomb: 20 damage (10%)
 * Equipment: replenished sword and shield meters (25%)
 * Shard: Once enough shards are looted, mana tiles are added during the day (5% drop rate, doubles after 20 days, doubles again after 40 days)

Dragon
In the final Dragon fight, matching non-Sword/Shield tiles will result in Dragon attacks. If no dragon attack tiles are matched, the dragon will inflict melee damage like a regular enemy.
 * Grain to Wing. The dragon will push the dude back away, preventing dude's attacks and doing damage.
 * Clay to Ice. The dragon will freeze the dude, which prevents dude's attacks, but also prevents dragon damage, as well. Duration 8000
 * Cloth to Fire. The dragon inflicts damage.