[project1dev] Re: civilians and townsfolk

  • From: Alan Wolfe <alan.wolfe@xxxxxxxxx>
  • To: project1dev@xxxxxxxxxxxxx
  • Date: Sat, 31 Jul 2010 14:53:09 -0700

"It could be helpful to have pathto return true when the model reaches
the destination"

well you should only call pathto when the place you want them to go to
changes.  IE you say "hey go to 50,100" and then it goes there, you
only have to tell it once.  If you tell it each frame thats bad cause
it will keep re-computing it's path to get there.

but hey, how bout when you call path to, you give the name of a script
function to call when it's finished?

On Sat, Jul 31, 2010 at 2:43 PM, Kent Petersen <kentkmp@xxxxxxxxx> wrote:
> I am trying to come up with a way for the builder to know when he gets to
> the house he is supposed to build.
>
> Currently
> 1) builder picks a valid tile and house number
> 2) builder uses namesh pathto to get to the location
> 3) ???Detect how builder arrives at the destination???
> 4) build house at location
> 5) go to 1
>
> So I don't know how to let the builder know when it reached the destination.
> I think thinking rectangle query but it seems to be for models only not a
> point. I also tried using get building location but I couldnt find a way to
> get the end spot detected. Any ideas?
>
> If not I had a thought. It could be helpful to have pathto return true when
> the model reaches the destination. That way I could use the navmeshing
> pathing command to return a true value when the builder arrived at his
> destination ready to build a house.
>
>
> On Tue, Jul 27, 2010 at 3:16 PM, Alan Wolfe <alan.wolfe@xxxxxxxxx> wrote:
>>
>> yeah either way sounds good to me too
>>
>> On Tue, Jul 27, 2010 at 3:02 PM, Kent Petersen <kentkmp@xxxxxxxxx> wrote:
>> > I was thinking about builders myself. I agree that they should head out
>> > from
>> > the starting spawn and return there when they are done. I will begin
>> > implementing some form of this shortly =)
>> >
>> > Maybe we could have the villagers run out of their house when it blows
>> > up.
>> > Trolls could then eat them if they are close by. Seems minor but could
>> > make
>> > a good touch. I am perfectly fine with out that as well.
>> >
>> > On Tue, Jul 27, 2010 at 1:46 PM, Alan Wolfe <alan.wolfe@xxxxxxxxx>
>> > wrote:
>> >>
>> >> Heya Kent (:
>> >>
>> >> So i know we are probably going to want builders that go from the main
>> >> temple (tile index 0 or 1, i forget which is the first tile hehe) to
>> >> their destination building then they build there.
>> >>
>> >> That seems like it ought to be pretty straightforward and that we just
>> >> have them path from tile index 0 to the location of the house they
>> >> want to go to.
>> >>
>> >> Right now they will path straight through buildings but i'm working on
>> >> fixing that so you could ignore that problem for now (:
>> >>
>> >> Besides the builder, was there other population that you think we
>> >> need?  Like do you want random people walking around the town and
>> >> stuff?  What did you have in mind?
>> >>
>> >> On Mon, Jul 26, 2010 at 9:54 PM, Kent Petersen <kentkmp@xxxxxxxxx>
>> >> wrote:
>> >> > I have been thinking about implementing population next. Any thoughts
>> >> > on
>> >> > how
>> >> > I should go about doing this?
>> >> >
>> >> > On Sun, May 23, 2010 at 11:04 AM, Alan Wolfe <alan.wolfe@xxxxxxxxx>
>> >> > wrote:
>> >> >>
>> >> >> No not yet, i will later (i wanna get some town building stuff done
>> >> >> first)
>> >> >> or you can if you want to (:
>> >> >>
>> >> >> On Sun, May 23, 2010 at 11:02 AM, Kent Petersen <kentkmp@xxxxxxxxx>
>> >> >> wrote:
>> >> >>>
>> >> >>> Excellent plan. It covers my previous concerns.
>> >> >>>
>> >> >>> I agree that you should not have to wait on builders if they die.
>> >> >>> The
>> >> >>> builder should respawn immediately.
>> >> >>>
>> >> >>> Did you add this to the wiki?
>> >> >>>
>> >> >>> On Sun, May 23, 2010 at 10:51 AM, Alan Wolfe <alan.wolfe@xxxxxxxxx>
>> >> >>> wrote:
>> >> >>>>
>> >> >>>> How about this for building construction, working in some stuff we
>> >> >>>> talked about previously...
>> >> >>>>
>> >> >>>> Based on your population, you have so many active builders.  I
>> >> >>>> think
>> >> >>>> you
>> >> >>>> should gain builders faster at the beginning of growing your
>> >> >>>> population and
>> >> >>>> gain them slower towards the end.
>> >> >>>>
>> >> >>>> Anyhow, each builder would be perpetually working.  When he was
>> >> >>>> finished
>> >> >>>> with one building, hed go to where ever the next building was
>> >> >>>> needed
>> >> >>>> and
>> >> >>>> start there.  I think you are right though that we are going to
>> >> >>>> need
>> >> >>>> to keep
>> >> >>>> track of current population not just by how many houses you have,
>> >> >>>> but
>> >> >>>> also
>> >> >>>> how many people are in those houses.  I dont think we have to keep
>> >> >>>> track for
>> >> >>>> each house, but we can know that we have houses enough for 100
>> >> >>>> people
>> >> >>>> and
>> >> >>>> that we only have 90 people currently.  90 is the current real
>> >> >>>> population.
>> >> >>>> When someone dies, it just subtracts 1 from the 90.  When bats
>> >> >>>> attack
>> >> >>>> a
>> >> >>>> house, they pull out a person so long as population > 0 and if
>> >> >>>> that
>> >> >>>> person
>> >> >>>> dies it subtracts 1 from the 90.   That is odd because if you had
>> >> >>>> 1
>> >> >>>> person
>> >> >>>> left and 20 buildings, no matter which building the bat attacked
>> >> >>>> it
>> >> >>>> would
>> >> >>>> take your 1 guy.  We can chalk it up to the bat knowing that your
>> >> >>>> guy
>> >> >>>> was in
>> >> >>>> there, otherwise he wouldnt have attacked that house hehe.
>> >> >>>>
>> >> >>>> Anyways back to building... Each tile supports 27 people total
>> >> >>>> with
>> >> >>>> level 1 building technology.
>> >> >>>>
>> >> >>>> Our current map has about 20 tiles on it and represents 1/4th of
>> >> >>>> the
>> >> >>>> map, but probably represents 1/3 of the total buildable area of
>> >> >>>> the
>> >> >>>> full
>> >> >>>> area of level 1.
>> >> >>>>
>> >> >>>> So let's say we have 60 tiles with 27 people per tile, that comes
>> >> >>>> to
>> >> >>>> 1620 people in this first level.  Our builder table might be
>> >> >>>> something
>> >> >>>> like...
>> >> >>>>
>> >> >>>> 0 Tiles (0 population) = 1 builder
>> >> >>>> 2 Tiles (54 population) = 2 builders
>> >> >>>> 6 tiles (162 population) = 3 builders
>> >> >>>> etc
>> >> >>>>
>> >> >>>> we'd have to play with the numbers to make sure there wasn't time
>> >> >>>> when
>> >> >>>> you were waiting just way too long for the low # of builders you
>> >> >>>> have
>> >> >>>> to
>> >> >>>> build new houses and grow population.
>> >> >>>>
>> >> >>>> other stuff im thinking..
>> >> >>>>
>> >> >>>> #1 - if a builder dies, you lose a person from your population,
>> >> >>>> but
>> >> >>>> you
>> >> >>>> instantly get another builder.  We dont have to keep track of "oh
>> >> >>>> they have
>> >> >>>> the potential for 5 builders but 2 of them are dead".  It may be
>> >> >>>> more
>> >> >>>> realistic to do it that way, but it complicates things and i dont
>> >> >>>> think it
>> >> >>>> would really add anything worth while to the game play.
>> >> >>>>
>> >> >>>> #2 - when a new house is built, you instantly gain the population
>> >> >>>> that
>> >> >>>> lives inside that house.  So if you built a house that holds 12
>> >> >>>> people, you
>> >> >>>> instantly get 12 to your population.
>> >> >>>>
>> >> >>>> But yeah, i think you are right, i think we are going to have to
>> >> >>>> keep
>> >> >>>> track of current population, not just calculate it based on how
>> >> >>>> many
>> >> >>>> houses
>> >> >>>> you have.
>> >> >>>>
>> >> >>>> On Sun, May 23, 2010 at 10:06 AM, Kent Petersen
>> >> >>>> <kentkmp@xxxxxxxxx>
>> >> >>>> wrote:
>> >> >>>>>
>> >> >>>>> I was thinking each house could have a possible occupancy. Let's
>> >> >>>>> say
>> >> >>>>> 3.
>> >> >>>>> Then as the population goes up the house population would go 1/3,
>> >> >>>>> then 2/3,
>> >> >>>>> then 3/3, then new house so 1 & 1/3, 1 & 2/3, etc
>> >> >>>>>
>> >> >>>>> How were you thinking about having bats take people?
>> >> >>>>>
>> >> >>>>> We could have civilians only do stuff as a scripted event. I
>> >> >>>>> think
>> >> >>>>> we
>> >> >>>>> need to talk more about what causes building construction. How is
>> >> >>>>> it
>> >> >>>>> going
>> >> >>>>> to work from a player playing point of view?
>> >> >>>>>
>> >> >>>>> On Sat, May 22, 2010 at 3:57 PM, Alan Wolfe
>> >> >>>>> <alan.wolfe@xxxxxxxxx>
>> >> >>>>> wrote:
>> >> >>>>>>
>> >> >>>>>> good question.
>> >> >>>>>>
>> >> >>>>>> in the original game they didnt actually wander around out on
>> >> >>>>>> the
>> >> >>>>>> map
>> >> >>>>>> unless it was a scripted event
>> >> >>>>>>
>> >> >>>>>> One thing i wonder about is if we have the # of houses be what
>> >> >>>>>> decides
>> >> >>>>>> what your population is, what happens when a wandering citizen
>> >> >>>>>> gets
>> >> >>>>>> killed?
>> >> >>>>>> Would you not lose any population?  Or would we have to keep
>> >> >>>>>> track
>> >> >>>>>> of
>> >> >>>>>> population in a more complicated way?
>> >> >>>>>>
>> >> >>>>>> Im not real sure what we should do, what do you think?
>> >> >>>>>>
>> >> >>>>>> On Sat, May 22, 2010 at 3:48 PM, Kent Petersen
>> >> >>>>>> <kentkmp@xxxxxxxxx>
>> >> >>>>>> wrote:
>> >> >>>>>>>
>> >> >>>>>>> We are going to have them wander around the map right?
>> >> >>>>>>>
>> >> >>>>>>> What should civilians be able to do? Just wander around? How do
>> >> >>>>>>> they
>> >> >>>>>>> spawn?
>> >> >>>>>>>
>> >> >>>>>>> What would civilians do when they are not building houses. How
>> >> >>>>>>> do
>> >> >>>>>>> you
>> >> >>>>>>> want the civilian house interaction to work?
>> >> >>>>>>>
>> >> >>>>>>> I was thinking the main building could produce them. You could
>> >> >>>>>>> have a
>> >> >>>>>>> certain amount of civilians out depending on the amount of
>> >> >>>>>>> buildings you
>> >> >>>>>>> have. Civilians could automatically flock to the area being
>> >> >>>>>>> constructed.
>> >> >>>>>>>
>> >> >>>>>>>  What were you thinking?
>> >> >>>>>>>
>> >> >>>>>>>
>> >> >>>>>>
>> >> >>>>>
>> >> >>>>
>> >> >>>
>> >> >>
>> >> >
>> >> >
>> >>
>> >> Project 1 Dev mailing list
>> >> to unsubscribe, please send an email request to demofox@xxxxxxxxxxx
>> >> Project 1 website: http://project1.demofox.org
>> >> Project 1 SVN repository: http://pyotek.com/project1
>> >
>> >
>>
>> Project 1 Dev mailing list
>> to unsubscribe, please send an email request to demofox@xxxxxxxxxxx
>> Project 1 website: http://project1.demofox.org
>> Project 1 SVN repository: http://pyotek.com/project1
>
>

=============================Project 1 Dev mailing list
to unsubscribe, please send an email request to demofox@xxxxxxxxxxx
Project 1 website: http://project1.demofox.org
Project 1 SVN repository: http://pyotek.com/project1

Other related posts: