surrsurus / edgequest

Edgequest Season Two
Mozilla Public License 2.0
8 stars 1 forks source link

FOV and AI break upon world generation #51

Closed sudo-prime closed 6 years ago

sudo-prime commented 6 years ago

Description: FOV and AI break upon generation of the world. This causes the player to be unable to see the area around them (the area would normally be illuminated by the player's FOV). In addition, NPCs such as the ant and cat will not take turns, which is visible if FOV is turned off. Strangely all issues are resolved if the player attempts to walk into a wall followed by walking away from the wall immediately after.

Reproduce: To see FOV break:

  1. Start the game.
  2. Press "w" to re-generate the world. Notice that, for all world generations other than the first, FOV breaks immediately and you are unable to see any tiles other than your player tile (unless FOV is turned off).

To see AI break:

  1. Start the game.
  2. Turn FOV off (to avoid the above mentioned issue).
  3. Press "w" to generate worlds until the player does not spawn directly next to a wall.
  4. Move around, taking care not to stand directly next to any walls. Notice that NPCs are entirely still, and do not move as their AI dictates.

To temporarily resolve the issue:

  1. Start the game.
  2. Follow either of the above directions to get the game into a bugged state.
  3. Move your player until it is directly adjacent to a wall.
  4. Take a turn moving directly into the wall.
  5. Take a turn moving away from the wall. Notice that NPCs start taking turns again, and FOV is fixed.
surrsurus commented 6 years ago

Solved as of recent commits