Caves, Mines and Hearth-fires

Thoughts on the further development of Haven & Hearth? Feel free to opine!
User avatar
kaka
Posts: 673
Joined: Fri Apr 03, 2009 8:31 am
Location: Château de Gâteau

Re: Caves, Mines and Hearth-fires

Post by kaka »

The problem, as I know it, is that tracking leads you to the position of the object you track,
not towards cave entrances, should the object be inside one.
When you reach that point in the "overworld" and find that the object is not there, first then
do you know it's in a cave.

And then you need to find an entrance.
User avatar
loftar
Posts: 9096
Joined: Fri Apr 03, 2009 7:05 am
Location: Your character database

Re: Caves, Mines and Hearth-fires

Post by loftar »

Jackard wrote:would your pathfinding help solve this? would it be possible to have some sort of indicator appear (footprints?) if you can actually reach the hearth from the current cluster?
Not really. The pathfinder is made primarily for short distances (like helping an animal find its way past a palisade or through a farm) -- trying to find a path from a hearth to a cave entrance would be prohibitively expensive. It might be true, however, that a new pathfinder could be constructed for that purpose, but that would take some time.
"Object-oriented design is the roman numerals of computing." -- Rob Pike
User avatar
sabinati
Posts: 15527
Joined: Mon Jul 13, 2009 4:25 am
Location: View active topics

Re: Caves, Mines and Hearth-fires

Post by sabinati »

couldn't you just make it so if a hearthfire is in a cave, tracking leads to the cave entrance, then when you get inside the cave, normal tracking resumes?
User avatar
Potjeh
Posts: 11825
Joined: Fri May 29, 2009 4:03 pm

Re: Caves, Mines and Hearth-fires

Post by Potjeh »

That's not the problem Jackard is referring to. He's saying that tracking could lead you to a cave that is not even connected to the one where the tracked object is. I suppose this could be circumvented by assigning cave ID to cave tiles and entrances. Then you just check the cave ID where the tracked object is, and only look through the list of the entrances with the same ID to find the closest entrance. Once you're in the right cave, tracking is hard, but still quite doable.
Image Bottleneck
User avatar
sabinati
Posts: 15527
Joined: Mon Jul 13, 2009 4:25 am
Location: View active topics

Re: Caves, Mines and Hearth-fires

Post by sabinati »

oh right, i guess that would be necessary, that's kind of what i was thinking though, that tracking should lead to and entrance of the cave that the hearthfire is actually in, not just a random cave entrance.
User avatar
loftar
Posts: 9096
Joined: Fri Apr 03, 2009 7:05 am
Location: Your character database

Re: Caves, Mines and Hearth-fires

Post by loftar »

Potjeh wrote:Then you just check the cave ID where the tracked object is, and only look through the list of the entrances with the same ID to find the closest entrance.
The main problem is, indeed, with mapping locations to cave entrances. Saving some kind of "cave ID" or anything per tile would be far too memory-expensive to be doable.
"Object-oriented design is the roman numerals of computing." -- Rob Pike
User avatar
theTrav
Posts: 3464
Joined: Fri May 29, 2009 11:25 pm

Re: Caves, Mines and Hearth-fires

Post by theTrav »

sabinati wrote:oh right, i guess that would be necessary, that's kind of what i was thinking though, that tracking should lead to and entrance of the cave that the hearthfire is actually in, not just a random cave entrance.
cave's don't seem to be quite the same as mines and cabins... They are labrinthian networks, some with multiple openings
User avatar
Potjeh
Posts: 11825
Joined: Fri May 29, 2009 4:03 pm

Re: Caves, Mines and Hearth-fires

Post by Potjeh »

loftar wrote:
Potjeh wrote:Then you just check the cave ID where the tracked object is, and only look through the list of the entrances with the same ID to find the closest entrance.
The main problem is, indeed, with mapping locations to cave entrances. Saving some kind of "cave ID" or anything per tile would be far too memory-expensive to be doable.
Hmm, could you assign the cave ID to the actual object? Cave ID gets assigned to a character, based on the last used entrance, and any objects this character places in a cave get assigned the same ID. Would still be fairly memory expensive, but hey, better memory than CPU cycles.
Image Bottleneck
User avatar
loftar
Posts: 9096
Joined: Fri Apr 03, 2009 7:05 am
Location: Your character database

Re: Caves, Mines and Hearth-fires

Post by loftar »

Potjeh wrote:
loftar wrote:
Potjeh wrote:Then you just check the cave ID where the tracked object is, and only look through the list of the entrances with the same ID to find the closest entrance.
The main problem is, indeed, with mapping locations to cave entrances. Saving some kind of "cave ID" or anything per tile would be far too memory-expensive to be doable.
Hmm, could you assign the cave ID to the actual object? Cave ID gets assigned to a character, based on the last used entrance, and any objects this character places in a cave get assigned the same ID. Would still be fairly memory expensive, but hey, better memory than CPU cycles.
Hmm... I was considering that exact solution, but I concluded that it wouldn't work for some reason. I just don't remember the reason...
"Object-oriented design is the roman numerals of computing." -- Rob Pike
User avatar
jorb
Posts: 18715
Joined: Fri Apr 03, 2009 7:07 am
Location: Here, there and everywhere.

Re: Caves, Mines and Hearth-fires

Post by jorb »

If you teleport into the cave to get to your hearthfire, you haven't passed the entrance.
"The psychological trials of dwellers in the last times will be equal to the physical trials of the martyrs. In order to face these trials we must be living in a different world."

-- Hieromonk Seraphim Rose

Return to “Critique & Ideas”