Homesource Forums

Homeworld Source Editing Talk
It is currently Thu May 25, 2017 3:07 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Fri Nov 03, 2006 1:50 pm 
Offline

Joined: Tue Oct 10, 2006 2:04 pm
Posts: 73
Location: North germany
Hi.
Since I try to rewrite HW in c# I kinda wondered what the old format for configuring ships was. Actually I didn't bother to search for any sourcecode. I just did a little examination what a config file would need in order to have all the properties the ships have in HW.
Well what I came up with was the following xml file.

Code:
<Homeworld version="0.1">
<class id="Ship">
   <class id="ArmedShip">
      <class id="Fighter"/>
      <class id="Frigate"/>
      <class id="Mothership"/>
   </class>
   <class id="NonCombat"/>
</class>
<class id="Gun">
   <class id="RailGun"/>
   <class id="SmallProjectileCannon"/>
</class>
<!-- Ship template
<ship
   id=""
   class=""
   buildCost=""
   buildTime=""
   acceleration=""
   maxVelocity=""
   hitPoints=""
   repairRate=""
   fuel=""
   mass=""
/>

<!-- Gun template
<gun
   id=""
   class=""
   damage=""
   range=""
/>
-->
<ship
   id="Mothership"
   class="Mothership"
   buildCost="8000"
   buildTime="300"
   acceleration="10"
   maxVelocity="50"
   hitPoints="160000"
   repairRate="120"   
   mass="5000000"
>
   <guns count="5">
      <gun class="SmallProjectileCannon" damage="40" range="4500"/>
   <guns>
</ship>
<ship
   id="CryoTank"
   class="NonCombat"
   buildCost="0"
   buildTime="0"
   acceleration="50"
   maxVelocity="600"
   hitPoints="18000"
   repairRate="15"
   mass="4000"
/>
<ship
   id="Scout"
   class="Fighter"
   buildCost="35"
   buildTime="12"
   acceleration="1000"
   maxVelocity="1000"
   hitPoints="110"
   fuel="14000"
   repairRate="0"
   mass="40"
>
   <guns count="2">
      <gun class="SmallProjectileCannon" damage="5" range="4000">
   </guns>
</ship>
<ship
   id="Interceptor"
   class="Fighter"
   buildCost="55"
   buildTime="18"
   acceleration="975"
   maxVelocity="875"
   hitPoints="160"
   fuel="14000"
   repairRate="0"
   mass="60"
>
   <guns count="2">
      <gun class="SmallProjectileCannon" damage="10" range="4500">
   </guns>
</ship>
<ship
   id="AttackBomber"
   class="Fighter"
   buildCost="85"
   buildTime="20"
   acceleration="975"
   maxVelocity="750"
   hitPoints="110"
   repairRate="0"
   fuel="14000"
   mass="90"
>
   <guns count="2">
      <gun id="Plasma Bomb Launcher" damage="65" range="5800"/>
   </guns>
</ship>

<ship
   id="Defender"
   class="Fighter"
   buildCost="65"
   buildTime="9"
   acceleration="385"
   maxVelocity="385"
   hitPoints="325"
   fuel="14000"
   repairRate="0"
   mass="60"
>
   <guns count="2">
      <gun class="SmallProjectileCannon" damage="4" range="6500"/>
   </guns>
</ship>
<ship
   id="Cloaked Fighter"
   class="Fighter"
   buildCost="85"
   buildTime="45"
   acceleration="975"
   maxVelocity="775"
   hitPoints="150"
   repairRate="0"
   fuel="10000"
   mass="40"
>
   <guns count="2">
      <gun class="SmallProjectileCannon" damage="11" range="5800"/>
   </guns>
</ship>
<ship id="Drone Frigate" class="Frigate" buildCost="800" buildTime="75" acceleration="75" maxVelocity="325" hitPoints="16000" repairRate="15" firepower="4900" mass="13000">
   <ships count="25">
      <ship id="Drone">
         <gun id="DroneGun" class="Rail Gun" damage="12" range="6500"/>
      </ship>
   </ships>
<ship>
</Homeworld>


Any opinions on this?[/code]

_________________
.: The hardest punishment are the innocent eyes of a child searching for truth :.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 03, 2006 5:58 pm 
Offline
coder
User avatar

Joined: Wed Oct 04, 2006 8:13 pm
Posts: 94
Location: UTC -0500
it's fine except for the comment syntax (/**/ and // would be nice)

hows the portage of the other parts coming? (engine, bigfile code, etc)

_________________
http://againsttcpa.com/what-is-tcpa.html
http://google.com/search?q=c+programming+faq
http://research.att.com/~bs
acronyms.ch, neworder.box.sk


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 03, 2006 7:20 pm 
Offline

Joined: Tue Oct 10, 2006 2:04 pm
Posts: 73
Location: North germany
nova wrote:
it's fine except for the comment syntax (/**/ and // would be nice)

Well that's the bitch about xml ;)

nova wrote:
hows the portage of the other parts coming? (engine, bigfile code, etc)

Coming? It's not coming! At least not that soon ;) Currently I have basicly all the code for the ship handling moved - the thing is I'm currently applying object oriented mimics to the ships (mostly done) and many other things which need still to be sorted out.
And also I have some issues with my Ubuntu box here so current I'm not too productive. BUT the next thing I'll try to get accomplished the next months is try to get the engine converted. I think the engine COULD work in a year displaying the first things. It all depends on whether I'll work solely alone on this (a friend of mine showed some interest...), how much time the wii will cost me ;) and so on...

_________________
.: The hardest punishment are the innocent eyes of a child searching for truth :.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group