Categories
Game Design Game Development Geek / Technical Linux Game Development

June #1GAM: I Think I’ll Do Line-Of-Sight

Four days into June, and I hadn’t thought about what to make for the One Game a Month challenge for June.

I searched online for interesting mechanics to play with, but nothing really jumped out at me. If you want to see some ridiculous concepts, try out the Game Idea Generator. B-)

At some point, I thought about the idea of being shipwrecked and needing to survive. Maybe you’re on an deserted island in the ocean. Maybe you’re on a deserted planet in the far reaches of space.

I liked it. The player has to deal with hunger, weather, injuries, disease, wildlife, environmental hazards, all while trying to survive. Maybe help is coming if you wait long enough? Maybe you need to explore the island and build something to find your own way to freedom? Maybe there are others in the same predicament?

I don’t know. But exploring sounded like it had to be a big part of this game. You’re stranded, and you don’t know where you are, so you better get a handle on your surroundings.

And since I decided to do a tile-based grid, it seems like a good opportunity to do line-of-sight fog of war.

I like the idea that the player can see his/her immediate surroundings but needs to explore to see more. I like the idea of multiple levels of fog. One tile away is visible. Two tiles away is a little foggy. Three tiles away is more foggy. Four tiles is opaque.

Below is a mock-up demonstrating experiments with some fog made in the GIMP to see how it might look with different levels.

June #1GAM Mock-up

I’m not sure I’m happy with it, as I want it to be more difficult to see what’s behind the fog. Maybe I can experiment with different ways to render or create fog. We’ll see.

I also have to think about explored areas vs areas the player is immediately able to see. I’m reminded of Fate of the Dragon‘s fog of war, which returned to opaque if you weren’t in an area after a period of time. I think I’ll follow the normal RTS convention of graying out explored areas you can’t currently see.

Perhaps I’ll use Zelda-like controls. I was thinking about using the mouse and doing click-to-move/interact for simplicity, but I wonder if there might be some advantages to using the keyboard in terms of how expressive the player can choose to be. Maybe there are good reasons to crawl, sit, rest, walk, run (which takes a lot of precious energy), swim, jump, climb, open inventory, use items.

But then again, I can probably do all of the above with the mouse as well as the keyboard. Spacebar can be used to toggle sitting/standing, CTRL+click could be used to crawl, while Shift+click could be used to run.

Either way, I’ll probably find that I won’t add all of this due to only having the rest of June to finish this game. B-)

2 replies on “June #1GAM: I Think I’ll Do Line-Of-Sight”

I wonder if it wouldn’t be easiest to generate 4 tiles for each tile, each with less information on them (or 3, and default to a black tile for the fourth). Then in the tile-drawing algorithm check the distance to the player, and draw the appropriate tile. It’d have the advantage that you could selectively decide how much info to show the player (maybe rocks and altars have the same 3rd tile, but more distinct 2nd tiles).

Just a thought that occurs to my currently sleep-deprived brain.

You might be right. Instead of trying to make generic fog that applies to all tiles, having custom-fog for each tile means I can obscure things more carefully. Thanks for the tip!

Comments are closed.