|
From: Cpt. B. <cpt...@te...> - 2004-01-16 04:40:54
|
Glad you think I'm up to it. :P Embarrassingly enough, I AM a
programmer...it's just that my C++ sucks (I learned C about 6 years ago, and
never used it since). I actually picked up a C++ book a few months ago,
figuring since I was out of work, it would be a good time to learn. Then I
got a job two days later (hadn't even cracked the cover), and I haven't had
the time since. :)
Well, here's a few samples. The first is the overall layout for the
bases element. I'm not sure if I like the <transfers/> element though...it
might be better to just have a status flag (available|out|in transit) for
most items...easier to calculate limits on living space, storage, etc.,
because items (& personnel, whatever) will be listed in with stuff that's
already there.
The next are a few samples of facilities. Basically, all facilities will
have the first three elements,(location, complete, builddays) but only
certain ones will have the last three(capacity, usedcapacity, contents).
I'm not sure whether individual "Stores" facilities should own items in
them, or if the item should know which stores it's in. The latter is
computationally easier (the whole list is one place, under the <stores/>
tag, rather than scattered through the facilities list), but it seems
counterintuitive. What do you guys think?
-The Captain
<bases>
<base name="Base 1">
<!--no idea how locations on the geoscape are recorded, so this is
placeholder.
Think of x and y as latitude and longitude. -->
<location x="0" y="0" />
<!-- Contains basic details regarding facilities at this base
location, status (under construction, etc), capacity, and so
on -->
<facilities/>
<!-- Contains basic details of all personnel associated with this
base -->
<personnel/>
<!-- Contains basic details of all crafts associated with this
base -->
<crafts/>
<!-- Contains basic details of all stored items associated with
this base -->
<stores/>
<!-- Contains basic details of all incoming transfers associated
with this base -->
<transfers/>
</base>
</bases>
<!-- Small Radar Facility -->
<facility name="SmallRadar1" type="SmallRadar"> <!-- name is a uid. Type
describes which type of facility -->
<location x="1" y="2" /> <!-- location in the baseview grid, bottom left
is 0,0. easy to add "z" value for freeform in v1+ -->
<complete>true</complete> <!-- is the facility completely built. May be
redundant to builddays -->
<builddays>0</builddays> <!--how many days left to build facility -->
</facility>
<!-- Storage Facility -->
<facility name="Stores1" type="Stores">
<location x="2" y="2"/>
<complete>true</complete>
<builddays>0</builddays>
<maxcapacity>50</maxcapacity> <!--maxmium amount of "X" the facility
contains. "X" depends on type attribute -->
<usedcapacity>36</usedcapacity> <!-- amount of "X" currently in this
facility -->
<contents/> <!-- "X" described -->
</facility>
<!-- Research Lab Facility -->
<facility name="Laboratory1" type="Laboratory">
<location x="3" y="2" />
<complete>true</complete>
<builddays>0</builddays>
<capacity>50</capacity>
<usedcapacity>10</usedcapacity>
<contents> <!-- contents of this lab. Lab can only contains <scientist>
elements. Workshops contains <engineer> elements in the same format -->
<scientist quantity="5">Laser Weapons</scientists>
<scientist quantity="5">Medikit</scientists>
</contents>
</facility>
<!-- Hanger Facility -->
<facility name="Hanger2" type="Hanger">
<location x="4" y="0" />
<complete>true</complete>
<builddays>0</builddays>
<capacity>1</capacity>
<usedcapacity>1</usedcapacity> <!-- for hangers, this is only zero if a
craft is not assigned to the hanger -->
<contents> <!-- for hangers, contents is only a reference back to the
craft. the craft itself keeps track of which hanger it belongs to -->
<craft name="Intercepter2"/>
</contents>
</facility>
-----Original Message-----
From: xen...@li...
[mailto:xen...@li...]On Behalf Of
mamutas
Sent: Thursday, January 15, 2004 11:04 AM
To: xen...@li...
Subject: Re: [Xenocide-programming] Other XML Layouts?
I agree with you. Sooner or later such work must be done. And it does not
matter whether it is done by programmer or not. The one must know the
original game very well, that is for sure. And I think that Cpt. is
qualified for that job. :)
I just wanted to stress the priorities. Unfortunately, I was not able to
come up with an urgent task myself. So, unless there is one, than working on
entities XML is as good as any other tasks.
Regards.
mamutas
P.S. I try to delete quoted emails from my replay, as non-deleted looks
very ugly from SF viewer.
|