So its been a while...
https://www.cemetech.net/img/ppd/8954.png
yeah...
but I am finally back
I don't think I will be doing a lot of big calc projects anymore, I'm thinking about trying some other new things and expanding my programming knowledge.
So I participated in a tech camp last week where I learned a lot about Windows C++. I worked on a project involving a Cookie Clicker style idle game and while I was working on 2D arrays, I realized that they could be used to generate a map like 2D Birdseye view dungeon games or whatever they are called.
for example, char map[9][9] = { { '#', '#', '#', '#', '#', '#', '#', '#', '#' }
{ '#', ' ', ' ', '#', ' ', '#', ' ', ' ', '#'}
{more stuff here and so on}};
I thought it would be fun to make a map thing like that and be able to control a character to move around. The funnest part would be checking to see if the player could move to a certain location or if it was blocked.
Then of course I decided it would be a wonderful idea to generate a map randomly. and I don't know how to do that.
Question time!
So an algorithm would be the way to go to generate this map right?
And if so, how should this work? I was thinking of choosing a random place on the map and creating a wall from that place to the nearest wall. But after that where do I go?
Any ideas?
Thanks in advance
https://www.cemetech.net/img/ppd/8954.png
yeah...
but I am finally back
I don't think I will be doing a lot of big calc projects anymore, I'm thinking about trying some other new things and expanding my programming knowledge.
So I participated in a tech camp last week where I learned a lot about Windows C++. I worked on a project involving a Cookie Clicker style idle game and while I was working on 2D arrays, I realized that they could be used to generate a map like 2D Birdseye view dungeon games or whatever they are called.
for example, char map[9][9] = { { '#', '#', '#', '#', '#', '#', '#', '#', '#' }
{ '#', ' ', ' ', '#', ' ', '#', ' ', ' ', '#'}
{more stuff here and so on}};
I thought it would be fun to make a map thing like that and be able to control a character to move around. The funnest part would be checking to see if the player could move to a certain location or if it was blocked.
Then of course I decided it would be a wonderful idea to generate a map randomly. and I don't know how to do that.
Question time!
So an algorithm would be the way to go to generate this map right?
And if so, how should this work? I was thinking of choosing a random place on the map and creating a wall from that place to the nearest wall. But after that where do I go?
Any ideas?
Thanks in advance