To reflect a player's degree of skill in a battle between a player character and an enemy character, and increase a strategic element. In the event that a player selects magic as an action of a player character in a battle between a player character and an enemy character, a puzzle battle is started. In the puzzle battle, a magic army (a block frame) is displayed on a display device in accordance with a kind of magic selected, the player moves or rotates a block falling from above the display device by operating an input device, stops it in a desired position, and fills the magic army. In the event that all squares of the magic army are filled with the blocks before a time elapsing from a start of the puzzle battle, displayed on an elapsed time gauge, reaches a prescribed time, the magic selected by the player is unleashed, and inflicts damage on the enemy character. An effectiveness of the magic depends on an overlapping, and a protrusion from the magic army, of the blocks.