Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 22, 2014, 2:49:16 PM (11 years ago)
Author:
smerkli
Message:

Merged modularships branch

Location:
code/branches/presentationFS14
Files:
29 edited
11 copied

Legend:

Unmodified
Added
Removed
  • code/branches/presentationFS14

  • code/branches/presentationFS14/data/levels/templates/HeavyCruiser.oxt

    r9943 r10073  
    22
    33<Template name=HeavyCruiser>
    4   <SpaceShip
     4  <ModularSpaceShip
     5   name = HeavyCruiser
     6   
    57   hudtemplate            = spaceshiphud
    68   camerapositiontemplate = heavycruisercameras
     
    911   explosionchunks        = 6
    1012
    11    health            = 100
    12    maxhealth         = 200
    13    initialhealth     = 100
     13   health            = 2000
     14   maxhealth         = 4000
     15   initialhealth     = 2000
    1416
    1517   shieldhealth        = 100
     
    4143  >
    4244    <engines>
    43       <MultiStateEngine position="85,0,0" template=HeavyCruiser_body_engine1 />
    44       <MultiStateEngine position="-85,0,0" template=HeavyCruiser_body_engine1 />
     45      <MultiStateEngine position="0,0,0" template=HeavyCruiser_body_engine1 />
    4546
    4647      <MultiStateEngine position="-140,0,308" template=HeavyCruiser_sidearmL_engine1 />
    4748      <MultiStateEngine position="140,0,308" template=HeavyCruiser_sidearmR_engine1 />
    4849    </engines>
     50   
     51    <parts>
     52        <ShipPart name="frontL" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="-76,30,-330">
     53            <destructionevents>
     54                <PartDestructionEvent targetType="ship" targetParam="shieldhealth" operation="*" value="0.5"/>
     55            </destructionevents>
     56        </ShipPart>
     57        <ShipPart name="frontR" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="76,30,-330">
     58            <destructionevents>
     59                <PartDestructionEvent targetType="ship" targetParam="shieldhealth" operation="*" value="0.5"/>
     60            </destructionevents>
     61        </ShipPart>
     62        <ShipPart name="partL" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="-100,33,-200">
     63            <destructionevents>
     64                <PartDestructionEvent targetType="ship" targetParam="boostpowerrate" operation="-" value="0.5" message="One of your ship's generators was destroyed!"/>
     65                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="speedfront" operation="-" value="50"/>
     66                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="accelerationfront" operation="-" value="3"/>
     67                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="boostfactor" operation="set" value="1"/>
     68            </destructionevents>
     69        </ShipPart>
     70        <ShipPart name="partR" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="100,33,-200">
     71            <destructionevents>
     72                <PartDestructionEvent targetType="ship" targetParam="boostpowerrate" operation="-" value="0.5" message="One of your ship's generators was destroyed!"/>
     73                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="speedfront" operation="-" value="50"/>
     74                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="accelerationfront" operation="-" value="3"/>
     75                <PartDestructionEvent targetType="engine" targetName="bodyengine" targetParam="boostfactor" operation="set" value="1"/>
     76            </destructionevents>
     77        </ShipPart>
     78        <ShipPart name="sidearmL" initialhealth="20" maxhealth="20" damageabsorption="0.2" explosionposition="-140,30,100">
     79            <destructionevents>
     80                <PartDestructionEvent targetType="engine" targetName="sidearmLengine" operation="destroy" message="The left auxiliary engine was destroyed!"/>
     81                <PartDestructionEvent targetType="part" targetName="sidearmLfront" operation="destroy"/>
     82                <PartDestructionEvent targetType="ship" targetParam="rotationthrust" operation="-" value="0.04" />
     83            </destructionevents>
     84        </ShipPart>
     85        <ShipPart name="sidearmLfront" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="-140,20,-50">
     86            <destructionevents>
     87                <PartDestructionEvent targetType="engine" targetName="sidearmLengine" targetParam="boostfactor" operation="set" value="1" message="The left auxiliary engine lost it's booster!"/>
     88            </destructionevents>
     89        </ShipPart>
     90        <ShipPart name="sidearmR" initialhealth="20" maxhealth="20" damageabsorption="0.2" explosionposition="140,30,100">
     91            <destructionevents>
     92                <PartDestructionEvent targetType="engine" targetName="sidearmRengine" operation="destroy" message="The right auxiliary engine was destroyed!"/>
     93                <PartDestructionEvent targetType="part" targetName="sidearmRfront" operation="destroy"/>
     94                <PartDestructionEvent targetType="ship" targetParam="rotationthrust" operation="-" value="0.04" />           
     95            </destructionevents>
     96        </ShipPart>
     97        <ShipPart name="sidearmRfront" initialhealth="10" maxhealth="10" damageabsorption="0.5" explosionposition="140,20,-50">
     98            <destructionevents>
     99                <PartDestructionEvent targetType="engine" targetName="sidearmRengine" targetParam="boostfactor" operation="set" value="1" message="The right auxiliary engine lost it's booster!"/>
     100            </destructionevents>
     101        </ShipPart>
     102    </parts>
     103   
    49104    <attached>
    50 
    51105        <Model mesh="HeavyCruiser_body.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    52         <Model mesh="HeavyCruiser_frontL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    53         <Model mesh="HeavyCruiser_frontR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    54         <Model mesh="HeavyCruiser_partL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    55         <Model mesh="HeavyCruiser_partR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    56         <Model mesh="HeavyCruiser_sidearmL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    57         <Model mesh="HeavyCruiser_sidearmLfront.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    58         <Model mesh="HeavyCruiser_sidearmR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
    59         <Model mesh="HeavyCruiser_sidearmRfront.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>       
    60 
    61             <!-- bay1 lights -->
    62         <BlinkingBillboard position="75,30,-416" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.05 frequency=0.3 phase=240 quadratic=1 />
    63         <BlinkingBillboard position="-75,30,-416" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.05 frequency=0.3 phase=240 quadratic=1 />
    64         <BlinkingBillboard position="74,30,-402" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.1 frequency=0.3 phase=120 quadratic=1 />
    65         <BlinkingBillboard position="-74,30,-402" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.1 frequency=0.3 phase=120 quadratic=1 />
    66         <BlinkingBillboard position="73,30,-388" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.15 frequency=0.3 phase=0 quadratic=1 />
    67         <BlinkingBillboard position="-73,30,-388" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.15 frequency=0.3 phase=0 quadratic=1 />
     106       
     107        <StaticEntity name="frontL" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     108            <attached>
     109                <Model mesh="HeavyCruiser_frontL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     110                <BlinkingBillboard position="-75,30,-416" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.05 frequency=0.3 phase=240 quadratic=1 />
     111                <BlinkingBillboard position="-74,30,-402" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.1 frequency=0.3 phase=120 quadratic=1 />
     112                <BlinkingBillboard position="-73,30,-388" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.15 frequency=0.3 phase=0 quadratic=1 />
     113            </attached>
     114            <collisionShapes>
     115                <BoxCollisionShape position="-80,33,-320" halfExtents="7,11,54" info="frontL"/>
     116                <BoxCollisionShape position="-79,31,-399" halfExtents="3,6,26" info="frontL"/>
     117            </collisionShapes>
     118        </StaticEntity>
     119       
     120        <StaticEntity name="frontR" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     121            <attached>
     122                <Model mesh="HeavyCruiser_frontR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     123                <BlinkingBillboard position="75,30,-416" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.05 frequency=0.3 phase=240 quadratic=1 />
     124                <BlinkingBillboard position="74,30,-402" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.1 frequency=0.3 phase=120 quadratic=1 />
     125                <BlinkingBillboard position="73,30,-388" material="Examples/Flare" colour="0.8, 0.8, 0, 0.1" amplitude=0.15 frequency=0.3 phase=0 quadratic=1 />
     126            </attached>
     127            <collisionShapes>
     128                <BoxCollisionShape position="80,33,-320" halfExtents="7,11,54" info="frontR"/>
     129                <BoxCollisionShape position="79,31,-399" halfExtents="3,6,26" info="frontR"/>
     130            </collisionShapes>
     131        </StaticEntity>
     132       
     133        <StaticEntity name="partL" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     134            <attached>
     135                <Model mesh="HeavyCruiser_partL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     136            </attached>
     137            <collisionShapes>
     138                <BoxCollisionShape position="-94,33,-179" halfExtents="11,13,45" info="partL"/>
     139                <BoxCollisionShape position="-96,33,-230" halfExtents="13,17,22" info="partL"/>
     140            </collisionShapes>
     141        </StaticEntity>
     142       
     143        <StaticEntity name="partR" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     144            <attached>
     145                <Model mesh="HeavyCruiser_partR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     146            </attached>
     147            <collisionShapes>
     148                <BoxCollisionShape position="94,33,-179" halfExtents="11,13,45" info="partR"/>
     149                <BoxCollisionShape position="96,33,-230" halfExtents="13,17,22" info="partR"/>
     150            </collisionShapes>
     151        </StaticEntity>
     152       
     153                <StaticEntity name="sidearmL" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     154            <attached>
     155                <Model mesh="HeavyCruiser_sidearmL.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     156            </attached>
     157            <collisionShapes>
     158                <BoxCollisionShape position="-109,47,87" halfExtents="29,8,26" info="sidearmL, upper connection"/>
     159                <BoxCollisionShape position="-99,-1,79" roll="15" halfExtents="40,4,9" info="sidearmL, lower connection"/>
     160                <BoxCollisionShape position="-145,21,115" roll="15" halfExtents="19,31,105" info="sidearmL, front"/>
     161                <BoxCollisionShape position="-140,12,261" roll="15" halfExtents="22,41,43" info="sidearmL, back"/>
     162                <BoxCollisionShape position="-145,25,5" roll="15" halfExtents="10,18,5" info="sidearmL, front break"/>
     163                <BoxCollisionShape position="-133,-13,29" roll="15" halfExtents="12,6,17" info="sidearmL, bottom cylinder"/>
     164                <BoxCollisionShape position="-165,-4,31" roll="15" halfExtents="7,21,13" info="sidearmL, box"/>
     165                <BoxCollisionShape position="-153,59,96" roll="15" halfExtents="6,7,60" info="sidearmL, upper beam"/>
     166                <BoxCollisionShape position="-143,57,119" roll="15" halfExtents="3,4,85" info="sidearmL, upper inner beam"/>
     167                <BoxCollisionShape position="-142,53,212" pitch="21" yaw="5" roll="15" halfExtents="3,4,10" info="sidearmL, upper inner beam"/>
     168                <BoxCollisionShape position="-160,52,119" roll="15" halfExtents="3,4,85" info="sidearmL, upper outer beam"/>
     169                <BoxCollisionShape position="-159,48,212" pitch="21" yaw="5" roll="15" halfExtents="3,4,10" info="sidearmL, upper outer beam"/>
     170                <BoxCollisionShape position="-152,54,34" pitch="-46" yaw="-14" roll="15" halfExtents="6,7,10" info="sidearmL, upper beam front"/>
     171                <BoxCollisionShape position="-152,54,162" pitch="30" yaw="9" roll="15" halfExtents="6,7,12" info="sidearmL, upper beam back"/>
     172                <BoxCollisionShape position="-168,21,119" roll="15" halfExtents="3,5,109" info="sidearmL, outer beam"/>
     173                <BoxCollisionShape position="-134,-10,169" roll="15" halfExtents="6,4,55" info="sidearmL, lower beam front"/>
     174                <BoxCollisionShape position="-131,-20,217" pitch="-20" roll="15" yaw="-5" halfExtents="6,12,3" info="sidearmL, lower beam middle"/>
     175                <BoxCollisionShape position="-130,-29,233" roll="15" halfExtents="6,3,15" info="sidearmL, lower beam back"/>
     176            </collisionShapes>
     177        </StaticEntity>
     178       
     179        <StaticEntity name="sidearmLfront" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     180            <attached>
     181                <Model mesh="HeavyCruiser_sidearmLfront.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     182            </attached>
     183            <collisionShapes>
     184                <BoxCollisionShape position="-141,15,-53" roll="15" halfExtents="27,44,62" info="sidearmLfront"/>
     185                <BoxCollisionShape position="-153,59,-30" roll="15" halfExtents="4,2,38" info="sidearmLfront, top"/>
     186                <BoxCollisionShape position="-153,61,-41" roll="15" halfExtents="4,4,11" info="sidearmLfront, top"/>
     187                <BoxCollisionShape position="-153,60,-65" roll="15" halfExtents="4,3,4" info="sidearmLfront, top"/>
     188                <BoxCollisionShape position="-153,59,-41" roll="15" halfExtents="8,2,11" info="sidearmLfront, top"/>
     189            </collisionShapes>
     190        </StaticEntity>
     191       
     192        <StaticEntity name="sidearmR" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     193            <attached>
     194                <Model mesh="HeavyCruiser_sidearmR.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     195            </attached>
     196            <collisionShapes>
     197                <BoxCollisionShape position="109,47,87" halfExtents="29,8,26" info="sidearmR, upper connection"/>
     198                <BoxCollisionShape position="99,-1,79" roll="-15" halfExtents="40,4,9" info="sidearmR, lower connection"/>
     199                <BoxCollisionShape position="145,21,115" roll="-15" halfExtents="19,31,105" info="sidearmR, front"/>
     200                <BoxCollisionShape position="140,12,261" roll="-15" halfExtents="22,41,43" info="sidearmR, back"/>
     201                <BoxCollisionShape position="145,25,5" roll="-15" halfExtents="10,18,5" info="sidearmR, front break"/>
     202                <BoxCollisionShape position="133,-13,29" roll="-15" halfExtents="12,6,17" info="sidearmR, bottom cylinder"/>
     203                <BoxCollisionShape position="165,-4,31" roll="-15" halfExtents="7,21,13" info="sidearmR, box"/>
     204                <BoxCollisionShape position="153,59,96" roll="-15" halfExtents="6,7,60" info="sidearmR, upper beam"/>
     205                <BoxCollisionShape position="143,57,119" roll="-15" halfExtents="3,4,85" info="sidearmR, upper inner beam"/>
     206                <BoxCollisionShape position="142,53,212" pitch="21" yaw="-5" roll="-15" halfExtents="3,4,10" info="sidearmR, upper inner beam"/>
     207                <BoxCollisionShape position="160,52,119" roll="-15" halfExtents="3,4,85" info="sidearmR, upper outer beam"/>
     208                <BoxCollisionShape position="159,48,212" pitch="21" yaw="-5" roll="-15" halfExtents="3,4,10" info="sidearmR, upper outer beam"/>
     209                <BoxCollisionShape position="152,54,34" pitch="-46" yaw="14" roll="-15" halfExtents="6,7,10" info="sidearmR, upper beam front"/>
     210                <BoxCollisionShape position="152,54,162" pitch="30" yaw="-9" roll="-15" halfExtents="6,7,12" info="sidearmR, upper beam back"/>
     211                <BoxCollisionShape position="168,21,119" roll="-15" halfExtents="3,5,109" info="sidearmR, outer beam"/>
     212                <BoxCollisionShape position="134,-10,169" roll="-15" halfExtents="6,4,55" info="sidearmR, lower beam front"/>
     213                <BoxCollisionShape position="131,-20,217" pitch="-20" roll="-15" yaw="5" halfExtents="6,12,3" info="sidearmR, lower beam middle"/>
     214                <BoxCollisionShape position="130,-29,233" roll="-15" halfExtents="6,3,15" info="sidearmR, lower beam back"/>
     215            </collisionShapes>
     216        </StaticEntity>
     217       
     218        <StaticEntity name="sidearmRfront" position="0,0,0" direction="0,0,0" collisionType=static mass=100 friction=0.01 >
     219            <attached>
     220                <Model mesh="HeavyCruiser_sidearmRfront.mesh" direction="-1,0,0" position="0,0,0" scale="40"/>
     221            </attached>
     222            <collisionShapes>
     223                <BoxCollisionShape position="141,15,-53" roll="-15" halfExtents="27,44,62" info="sidearmRfront"/>
     224                <BoxCollisionShape position="153,59,-30" roll="-15" halfExtents="4,2,38" info="sidearmRfront, top"/>
     225                <BoxCollisionShape position="153,61,-41" roll="-15" halfExtents="4,4,11" info="sidearmRfront, top"/>
     226                <BoxCollisionShape position="153,60,-65" roll="-15" halfExtents="4,3,4" info="sidearmRfront, top"/>
     227                <BoxCollisionShape position="153,59,-41" roll="-15" halfExtents="8,2,11" info="sidearmRfront, top"/>
     228            </collisionShapes>
     229        </StaticEntity>   
     230
    68231            <!-- front position lights -->
    69232        <BlinkingBillboard position="67,-5,-240" material="Examples/Flare" colour="0, 0.7, 0, 0.1" amplitude=0.3 frequency=0.15 phase=0 quadratic=1 />
     
    79242    </attached>
    80243    <collisionShapes>
    81         <BoxCollisionShape position="80,33,-320" halfExtents="7,11,54" info="frontR"/>
    82         <BoxCollisionShape position="79,31,-399" halfExtents="3,6,26" info="frontR"/>
    83 
    84 
    85         <BoxCollisionShape position="-80,33,-320" halfExtents="7,11,54" info="frontL"/>
    86         <BoxCollisionShape position="-79,31,-399" halfExtents="3,6,26" info="frontL"/>
    87 
    88 
    89         <BoxCollisionShape position="94,33,-179" halfExtents="11,13,45" info="partR"/>
    90         <BoxCollisionShape position="96,33,-230" halfExtents="13,17,22" info="partR"/>
    91 
    92 
    93         <BoxCollisionShape position="-94,33,-179" halfExtents="11,13,45" info="partL"/>
    94         <BoxCollisionShape position="-96,33,-230" halfExtents="13,17,22" info="partL"/>
    95 
    96 
    97         <BoxCollisionShape position="109,47,87" halfExtents="29,8,26" info="sidearmR, upper connection"/>
    98         <BoxCollisionShape position="99,-1,79" roll="-15" halfExtents="40,4,9" info="sidearmR, lower connection"/>
    99         <BoxCollisionShape position="145,21,115" roll="-15" halfExtents="19,31,105" info="sidearmR, front"/>
    100         <BoxCollisionShape position="140,12,261" roll="-15" halfExtents="22,41,43" info="sidearmR, back"/>
    101         <BoxCollisionShape position="145,25,5" roll="-15" halfExtents="10,18,5" info="sidearmR, front break"/>
    102         <BoxCollisionShape position="133,-13,29" roll="-15" halfExtents="12,6,17" info="sidearmR, bottom cylinder"/>
    103         <BoxCollisionShape position="165,-4,31" roll="-15" halfExtents="7,21,13" info="sidearmR, box"/>
    104         <BoxCollisionShape position="153,59,96" roll="-15" halfExtents="6,7,60" info="sidearmR, upper beam"/>
    105         <BoxCollisionShape position="143,57,119" roll="-15" halfExtents="3,4,85" info="sidearmR, upper inner beam"/>
    106         <BoxCollisionShape position="142,53,212" pitch="21" yaw="-5" roll="-15" halfExtents="3,4,10" info="sidearmR, upper inner beam"/>
    107         <BoxCollisionShape position="160,52,119" roll="-15" halfExtents="3,4,85" info="sidearmR, upper outer beam"/>
    108         <BoxCollisionShape position="159,48,212" pitch="21" yaw="-5" roll="-15" halfExtents="3,4,10" info="sidearmR, upper outer beam"/>
    109         <BoxCollisionShape position="152,54,34" pitch="-46" yaw="14" roll="-15" halfExtents="6,7,10" info="sidearmR, upper beam front"/>
    110         <BoxCollisionShape position="152,54,162" pitch="30" yaw="-9" roll="-15" halfExtents="6,7,12" info="sidearmR, upper beam back"/>
    111         <BoxCollisionShape position="168,21,119" roll="-15" halfExtents="3,5,109" info="sidearmR, outer beam"/>
    112         <BoxCollisionShape position="134,-10,169" roll="-15" halfExtents="6,4,55" info="sidearmR, lower beam front"/>
    113         <BoxCollisionShape position="131,-20,217" pitch="-20" roll="-15" yaw="5" halfExtents="6,12,3" info="sidearmR, lower beam middle"/>
    114         <BoxCollisionShape position="130,-29,233" roll="-15" halfExtents="6,3,15" info="sidearmR, lower beam back"/>
    115 
    116 
    117         <BoxCollisionShape position="141,15,-53" roll="-15" halfExtents="27,44,62" info="sidearmRfront"/>
    118         <BoxCollisionShape position="153,59,-30" roll="-15" halfExtents="4,2,38" info="sidearmRfront, top"/>
    119         <BoxCollisionShape position="153,61,-41" roll="-15" halfExtents="4,4,11" info="sidearmRfront, top"/>
    120         <BoxCollisionShape position="153,60,-65" roll="-15" halfExtents="4,3,4" info="sidearmRfront, top"/>
    121         <BoxCollisionShape position="153,59,-41" roll="-15" halfExtents="8,2,11" info="sidearmRfront, top"/>
    122 
    123 
    124         <BoxCollisionShape position="-109,47,87" halfExtents="29,8,26" info="sidearmL, upper connection"/>
    125         <BoxCollisionShape position="-99,-1,79" roll="15" halfExtents="40,4,9" info="sidearmL, lower connection"/>
    126         <BoxCollisionShape position="-145,21,115" roll="15" halfExtents="19,31,105" info="sidearmL, front"/>
    127         <BoxCollisionShape position="-140,12,261" roll="15" halfExtents="22,41,43" info="sidearmL, back"/>
    128         <BoxCollisionShape position="-145,25,5" roll="15" halfExtents="10,18,5" info="sidearmL, front break"/>
    129         <BoxCollisionShape position="-133,-13,29" roll="15" halfExtents="12,6,17" info="sidearmL, bottom cylinder"/>
    130         <BoxCollisionShape position="-165,-4,31" roll="15" halfExtents="7,21,13" info="sidearmL, box"/>
    131         <BoxCollisionShape position="-153,59,96" roll="15" halfExtents="6,7,60" info="sidearmL, upper beam"/>
    132         <BoxCollisionShape position="-143,57,119" roll="15" halfExtents="3,4,85" info="sidearmL, upper inner beam"/>
    133         <BoxCollisionShape position="-142,53,212" pitch="21" yaw="5" roll="15" halfExtents="3,4,10" info="sidearmL, upper inner beam"/>
    134         <BoxCollisionShape position="-160,52,119" roll="15" halfExtents="3,4,85" info="sidearmL, upper outer beam"/>
    135         <BoxCollisionShape position="-159,48,212" pitch="21" yaw="5" roll="15" halfExtents="3,4,10" info="sidearmL, upper outer beam"/>
    136         <BoxCollisionShape position="-152,54,34" pitch="-46" yaw="-14" roll="15" halfExtents="6,7,10" info="sidearmL, upper beam front"/>
    137         <BoxCollisionShape position="-152,54,162" pitch="30" yaw="9" roll="15" halfExtents="6,7,12" info="sidearmL, upper beam back"/>
    138         <BoxCollisionShape position="-168,21,119" roll="15" halfExtents="3,5,109" info="sidearmL, outer beam"/>
    139         <BoxCollisionShape position="-134,-10,169" roll="15" halfExtents="6,4,55" info="sidearmL, lower beam front"/>
    140         <BoxCollisionShape position="-131,-20,217" pitch="-20" roll="15" yaw="-5" halfExtents="6,12,3" info="sidearmL, lower beam middle"/>
    141         <BoxCollisionShape position="-130,-29,233" roll="15" halfExtents="6,3,15" info="sidearmL, lower beam back"/>
    142 
    143 
    144         <BoxCollisionShape position="-141,15,-53" roll="15" halfExtents="27,44,62" info="sidearmLfront"/>
    145         <BoxCollisionShape position="-153,59,-30" roll="15" halfExtents="4,2,38" info="sidearmLfront, top"/>
    146         <BoxCollisionShape position="-153,61,-41" roll="15" halfExtents="4,4,11" info="sidearmLfront, top"/>
    147         <BoxCollisionShape position="-153,60,-65" roll="15" halfExtents="4,3,4" info="sidearmLfront, top"/>
    148         <BoxCollisionShape position="-153,59,-41" roll="15" halfExtents="8,2,11" info="sidearmLfront, top"/>
    149 
    150 
    151244        <BoxCollisionShape position="60,35,-310" halfExtents="13,28,60" info="body, bay1, Rwall"/>
    152245        <BoxCollisionShape position="-60,35,-310" halfExtents="13,28,60" info="body, bay1, Lwall"/>
     
    293386  include("../includes/weaponSettingsHeavyCruiser.oxi")
    294387?>
    295   </SpaceShip>
     388  </ModularSpaceShip>
    296389
    297390</Template>
     
    318411<Template name=HeavyCruiser_body_engine1 baseclass=MultiStateEngine>
    319412  <MultiStateEngine
     413   name           = bodyengine
    320414   boostfactor    = 2
    321415
     
    412506<Template name=HeavyCruiser_sidearmL_engine1 baseclass=MultiStateEngine>
    413507  <MultiStateEngine
     508   name           = sidearmLengine
    414509   boostfactor    = 2
    415510
     
    461556<Template name=HeavyCruiser_sidearmR_engine1 baseclass=MultiStateEngine>
    462557  <MultiStateEngine
     558   name           = sidearmRengine
    463559   boostfactor    = 2
    464560
  • code/branches/presentationFS14/src/external/bullet/BulletCollision/CollisionDispatch/btCompoundCollisionAlgorithm.cpp

    r8393 r10073  
    2121#include "LinearMath/btAabbUtil2.h"
    2222#include "btManifoldResult.h"
     23#include <iostream>
    2324
    2425btCompoundCollisionAlgorithm::btCompoundCollisionAlgorithm( const btCollisionAlgorithmConstructionInfo& ci,btCollisionObject* body0,btCollisionObject* body1,bool isSwapped)
     
    115116        void    ProcessChildShape(btCollisionShape* childShape,int index)
    116117        {
    117                 btAssert(index>=0);
     118                // std::cout << "PCS: " << childShape << std::endl; // FIXME: (noep) remove DEBUG
     119            btAssert(index>=0);
    118120                btCompoundShape* compoundShape = static_cast<btCompoundShape*>(m_compoundColObj->getCollisionShape());
    119121                btAssert(index<compoundShape->getNumChildShapes());
  • code/branches/presentationFS14/src/modules/weapons/projectiles/BasicProjectile.cc

    r9667 r10073  
    7878    @see Pawn.h
    7979    */
    80     bool BasicProjectile::processCollision(WorldEntity* otherObject, btManifoldPoint& contactPoint)
     80    bool BasicProjectile::processCollision(WorldEntity* otherObject, btManifoldPoint& contactPoint, const btCollisionShape* cs)
    8181    {
    8282        if (!this->bDestroy_ && GameMode::isMaster())
     
    9696            if (victim)
    9797            {
    98                 victim->hit(this->getShooter(), contactPoint, this->getDamage(), this->getHealthDamage(), this->getShieldDamage());
     98                victim->hit(this->getShooter(), contactPoint, cs, this->getDamage(), this->getHealthDamage(), this->getShieldDamage());
    9999                victim->startReloadCountdown();
    100100            }
     
    141141    }
    142142
     143
    143144    /**
    144145    @brief
  • code/branches/presentationFS14/src/modules/weapons/projectiles/BasicProjectile.h

    r9667 r10073  
    119119
    120120        protected:
    121             bool processCollision(WorldEntity* otherObject, btManifoldPoint& contactPoint);
     121            bool processCollision(WorldEntity* otherObject, btManifoldPoint& contactPoint, const btCollisionShape* cs);
    122122            void destroyCheck(void);
    123123
  • code/branches/presentationFS14/src/modules/weapons/projectiles/Projectile.cc

    r9667 r10073  
    8888    }
    8989
    90     bool Projectile::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
     90    bool Projectile::collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint)
    9191    {
    92         return this->processCollision(otherObject, contactPoint);
     92        return this->processCollision(otherObject, contactPoint, cs);
    9393    }
    9494
  • code/branches/presentationFS14/src/modules/weapons/projectiles/Projectile.h

    r9667 r10073  
    6464
    6565            virtual void tick(float dt);
    66             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
     66            virtual bool collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint);
    6767
    6868        private:
  • code/branches/presentationFS14/src/modules/weapons/projectiles/Rocket.cc

    r9667 r10073  
    191191    }
    192192
    193     bool Rocket::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
    194     {
    195         return this->processCollision(otherObject, contactPoint);
     193    bool Rocket::collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint)
     194    {
     195        return this->processCollision(otherObject, contactPoint, cs);
    196196    }
    197197
  • code/branches/presentationFS14/src/modules/weapons/projectiles/Rocket.h

    r9667 r10073  
    6464            virtual void tick(float dt); //!< Defines which actions the Rocket has to take in each tick.
    6565
    66             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
     66            virtual bool collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint);
    6767            virtual void destroyObject(void);
    6868            void destructionEffect();
  • code/branches/presentationFS14/src/modules/weapons/projectiles/SimpleRocket.cc

    r9667 r10073  
    172172    }
    173173
    174     bool SimpleRocket::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
    175     {
    176         return this->processCollision(otherObject, contactPoint);
     174    bool SimpleRocket::collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint)
     175    {
     176        return this->processCollision(otherObject, contactPoint, cs);
    177177    }
    178178
  • code/branches/presentationFS14/src/modules/weapons/projectiles/SimpleRocket.h

    r9667 r10073  
    6464            virtual void tick(float dt);
    6565
    66             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
     66            virtual bool collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint);
    6767
    6868            void disableFire(); //!< Method to disable the fire and stop all acceleration
  • code/branches/presentationFS14/src/orxonox/CMakeLists.txt

    r9348 r10073  
    3131  PawnManager.cc
    3232  PlayerManager.cc
     33  ShipPartManager.cc
    3334  Radar.cc
    3435#  Test.cc
  • code/branches/presentationFS14/src/orxonox/OrxonoxPrereqs.h

    r9348 r10073  
    142142
    143143    // items
     144    class ShipPart;
     145    class PartDestructionEvent;
    144146    class Engine;
    145147    class Item;
     
    189191    class Pawn;
    190192    class SpaceShip;
     193    class ModularSpaceShip;
    191194    class Spectator;
    192195    class TeamBaseMatchBase;
  • code/branches/presentationFS14/src/orxonox/Scene.cc

    r9667 r10073  
    349349        SmartPtr<WorldEntity> object1 = static_cast<WorldEntity*>(colObj1->getUserPointer());
    350350
     351        // get the CollisionShape pointers
     352        const btCollisionShape* cs0 = colObj0->getCollisionShape();
     353        const btCollisionShape* cs1 = colObj1->getCollisionShape();
     354
    351355        // false means that bullet will assume we didn't modify the contact
    352356        bool modified = false;
    353357        if (object0->isCollisionCallbackActive())
    354             modified |= object0->collidesAgainst(object1, cp);
     358            modified |= object0->collidesAgainst(object1, cs1, cp);
    355359        if (object1->isCollisionCallbackActive())
    356             modified |= object1->collidesAgainst(object0, cp);
     360            modified |= object1->collidesAgainst(object0, cs0, cp);
    357361
    358362        return modified;
  • code/branches/presentationFS14/src/orxonox/Scene.h

    r9667 r10073  
    143143                                          int index0, const btCollisionObject* colObj1, int partId1, int index1);
    144144
     145            static bool customCollisionCallback(btManifoldPoint& cp, const btCollisionObject* colObj0, int partId0,
     146                                                      int index0, const btCollisionObject* colObj1, int partId1, int index1);
     147
    145148            // Bullet objects
    146149            btDiscreteDynamicsWorld*             physicalWorld_;
  • code/branches/presentationFS14/src/orxonox/collisionshapes/CollisionShape.h

    r9667 r10073  
    170170            void notifyDetached(); // Notifies the CollisionShape of being detached from a CompoundCollisionShape.
    171171
     172            inline unsigned int getParentID()
     173                { return this->parentID_; }
     174
     175            inline CompoundCollisionShape* getParent()
     176                { return this->parent_; }
     177
    172178        protected:
    173179            virtual void updateParent(); // Updates the CompoundCollisionShape the CollisionShape belongs to, after the CollisionShape has changed.
  • code/branches/presentationFS14/src/orxonox/collisionshapes/CompoundCollisionShape.cc

    r9667 r10073  
    3939#include "core/XMLPort.h"
    4040#include "tools/BulletConversions.h"
     41
     42#include "collisionshapes/WorldEntityCollisionShape.h"
    4143
    4244namespace orxonox
     
    118120            this->updatePublicShape();
    119121        }
     122
     123        // If the shape to be attached is not a CompoundCollisionShape (thus an actual physical shape) & this is a WorldEntity's CollisionShape,
     124        // set it's userPointer to the WorldEntity this CompoundCollisionShape belongs to.
     125        if (!orxonox_cast<CompoundCollisionShape*>(shape) && orxonox_cast<WorldEntityCollisionShape*>(this))
     126            shape->getCollisionShape()->setUserPointer(orxonox_cast<WorldEntityCollisionShape*>(this)->getWorldEntityOwner());
    120127    }
    121128
     
    297304        this->updatePublicShape();*/
    298305    }
     306
     307    int CompoundCollisionShape::getNumChildShapes()
     308    {
     309        return this->compoundShape_->getNumChildShapes();
     310    }
    299311}
  • code/branches/presentationFS14/src/orxonox/collisionshapes/CompoundCollisionShape.h

    r9667 r10073  
    7171
    7272            virtual void changedScale();
     73            int getNumChildShapes();
     74
     75            inline std::map<CollisionShape*, btCollisionShape*> getShapesMap()
     76            {
     77                return attachedShapes_;
     78            }
    7379
    7480        private:
  • code/branches/presentationFS14/src/orxonox/controllers/NewHumanController.cc

    r9939 r10073  
    220220                if (!controlPaused_ )
    221221                {
    222                     if (this->getControllableEntity() && (this->getControllableEntity()->isExactlyA(ClassByString("SpaceShip")) || this->getControllableEntity()->isExactlyA(ClassByString("Rocket"))))
     222                    if (this->getControllableEntity() && ((this->getControllableEntity()->isExactlyA(ClassByString("SpaceShip")) || (this->getControllableEntity()->isExactlyA(ClassByString("ModularSpaceShip")))) || this->getControllableEntity()->isExactlyA(ClassByString("Rocket"))))
    223223                        this->showOverlays();
    224224                    else if (this->getControllableEntity() &&  this->getControllableEntity()->isExactlyA(ClassByString("FpsPlayer")))
     
    498498        this->controlMode_ = 0;
    499499        this->centerCursor();
    500         if (this->getControllableEntity() && (this->getControllableEntity()->isExactlyA(ClassByString("SpaceShip")) || this->getControllableEntity()->isExactlyA(ClassByString("Rocket"))))
     500        if (this->getControllableEntity() && ((this->getControllableEntity()->isExactlyA(ClassByString("SpaceShip")) || (this->getControllableEntity()->isExactlyA(ClassByString("ModularSpaceShip")))) || this->getControllableEntity()->isExactlyA(ClassByString("Rocket"))))
    501501        {
    502502            this->showOverlays_ = true;
  • code/branches/presentationFS14/src/orxonox/items/CMakeLists.txt

    r5781 r10073  
    33  Engine.cc
    44  MultiStateEngine.cc
     5  ShipPart.cc
     6  PartDestructionEvent.cc
    57)
  • code/branches/presentationFS14/src/orxonox/worldentities/MovableEntity.cc

    r9667 r10073  
    7272    }
    7373
    74     bool MovableEntity::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
     74    bool MovableEntity::collidesAgainst(WorldEntity* otherObject, const btCollisionShape* ownCollisionShape, btManifoldPoint& contactPoint)
    7575    {
    7676        if (GameMode::isMaster() && enableCollisionDamage_)
     
    8080            {
    8181                float damage = this->collisionDamage_ * (victim->getVelocity() - this->getVelocity()).length();
    82                 victim->hit(0, contactPoint, damage);
     82                victim->hit(0, contactPoint, ownCollisionShape, damage);
    8383            }
    8484        }
     
    8686        return false;
    8787    }
    88 
    8988
    9089    void MovableEntity::registerVariables()
  • code/branches/presentationFS14/src/orxonox/worldentities/MovableEntity.h

    r9667 r10073  
    4747
    4848            virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode);
    49             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
     49            virtual bool collidesAgainst(WorldEntity* otherObject, const btCollisionShape* cs, btManifoldPoint& contactPoint);
    5050
    5151            using WorldEntity::setPosition;
  • code/branches/presentationFS14/src/orxonox/worldentities/StaticEntity.cc

    r9667 r10073  
    3434#include "util/OrxAssert.h"
    3535#include "core/CoreIncludes.h"
     36#include "worldentities/BigExplosion.h"
    3637
    3738namespace orxonox
     
    115116        worldTrans.setRotation(btQuaternion(node_->getOrientation().x, node_->getOrientation().y, node_->getOrientation().z, node_->getOrientation().w));
    116117    }
     118
    117119}
  • code/branches/presentationFS14/src/orxonox/worldentities/WorldEntity.cc

    r10072 r10073  
    4646#include "Scene.h"
    4747#include "collisionshapes/WorldEntityCollisionShape.h"
     48#include <BulletCollision/CollisionShapes/btCollisionShape.h>
    4849
    4950namespace orxonox
  • code/branches/presentationFS14/src/orxonox/worldentities/WorldEntity.h

    r9667 r10073  
    7272    {
    7373        friend class Scene;
     74        friend class ModularSpaceShip;
    7475
    7576        public:
     
    206207
    207208            void notifyChildPropsChanged();
     209
     210            inline int getNumAttachedObj()
     211                { return this->children_.size(); }
    208212
    209213        protected:
     
    374378                Condition is that enableCollisionCallback() was called.
    375379            */
    376             virtual inline bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
     380            virtual inline bool collidesAgainst(WorldEntity* otherObject, const btCollisionShape* ownCollisionShape, btManifoldPoint& contactPoint)
    377381                { return false; } /* With false, Bullet assumes no modification to the collision objects. */
    378382
     
    405409            */
    406410            virtual bool isCollisionTypeLegal(CollisionType type) const = 0;
     411
     412            inline virtual WorldEntityCollisionShape* getWorldEntityCollisionShape()
     413                { return this->collisionShape_; }
    407414
    408415            btRigidBody*  physicalBody_; //!< Bullet rigid body. Everything physical is applied to this instance.
  • code/branches/presentationFS14/src/orxonox/worldentities/pawns/CMakeLists.txt

    r7163 r10073  
    44  Pawn.cc
    55  SpaceShip.cc
     6  ModularSpaceShip.cc
    67  TeamBaseMatchBase.cc
    78  Destroyer.cc
  • code/branches/presentationFS14/src/orxonox/worldentities/pawns/Pawn.cc

    r9950 r10073  
    5050#include "controllers/FormationController.h"
    5151
     52#include "collisionshapes/WorldEntityCollisionShape.h"
     53#include <BulletCollision/CollisionShapes/btCollisionShape.h>
     54#include <BulletCollision/CollisionShapes/btCompoundShape.h>
     55#include "graphics/Model.h"
     56
     57
    5258namespace orxonox
    5359{
     
    244250    }
    245251
    246     void Pawn::damage(float damage, float healthdamage, float shielddamage, Pawn* originator)
    247     {
     252    void Pawn::damage(float damage, float healthdamage, float shielddamage, Pawn* originator, const btCollisionShape* cs)
     253    {
     254        //FIXME: (noep) remove debug
     255        //orxout() << "damage(): Collision detected on " << this->getName() << ", btCS*: " << cs << endl;
     256
     257        //int collisionShapeIndex = this->isMyCollisionShape(cs);
     258        //orxout() << collisionShapeIndex << endl;
     259
    248260        // Applies multiplier given by the DamageBoost Pickup.
    249261        if (originator)
     
    279291
    280292*/
    281     void Pawn::hit(Pawn* originator, const Vector3& force, float damage, float healthdamage, float shielddamage)
     293    void Pawn::hit(Pawn* originator, const Vector3& force, const btCollisionShape* cs, float damage, float healthdamage, float shielddamage)
    282294    {
    283295        if (this->getGametype() && this->getGametype()->allowPawnHit(this, originator) && (!this->getController() || !this->getController()->getGodMode()) )
    284296        {
    285             this->damage(damage, healthdamage, shielddamage, originator);
     297            this->damage(damage, healthdamage, shielddamage, originator, cs);
    286298            this->setVelocity(this->getVelocity() + force);
    287299        }
    288300    }
    289301
    290 
    291     void Pawn::hit(Pawn* originator, btManifoldPoint& contactpoint, float damage, float healthdamage, float shielddamage)
     302    void Pawn::hit(Pawn* originator, btManifoldPoint& contactpoint, const btCollisionShape* cs, float damage, float healthdamage, float shielddamage)
    292303    {
    293304        if (this->getGametype() && this->getGametype()->allowPawnHit(this, originator) && (!this->getController() || !this->getController()->getGodMode()) )
    294305        {
    295             this->damage(damage, healthdamage, shielddamage, originator);
     306            this->damage(damage, healthdamage, shielddamage, originator, cs);
    296307
    297308            if ( this->getController() )
     
    561572
    562573
     574    int Pawn::isMyCollisionShape(const btCollisionShape* cs)
     575    {
     576        // This entities WECS
     577        WorldEntityCollisionShape* ownWECS = this->getWorldEntityCollisionShape();
     578
     579        // e.g. "Box 4: Searching for CS 0x1ad49200"
     580        orxout() << this->getName() << ": Searching for btCS* " << cs << endl;
     581        // e.g. "Box 4 is WorldEntityCollisionShape 0x126dd060"
     582        orxout() << "  " << this->getName() << " is WorldEntityCollisionShape* " << ownWECS << endl;
     583        // e.g. "Box 4 is WorldEntity 0x126dd060"
     584        orxout() << "  " << this->getName() << " is WorldEntity* " << this << endl;
     585        // e.g. "Box 4 is objectID 943"
     586        orxout() << "  " << this->getName() << " is objectID " << this->getObjectID() << endl;
     587
     588        // List all attached Objects
     589        orxout() << "  " << this->getName() << " has the following Objects attached:" << endl;
     590        for (int i=0; i<50; i++)
     591        {
     592            if (this->getAttachedObject(i)==NULL)
     593                break;
     594            orxout() << " " << i << ": " << this->getAttachedObject(i) << " (" << this->getAttachedObject(i)->getName() << ")";
     595            if(!orxonox_cast<Model*>(this->getAttachedObject(i)))
     596                orxout() << " (SE)";
     597            orxout() << endl;
     598        }
     599
     600
     601        // print child shapes of this WECS
     602        printBtChildShapes((btCompoundShape*)(ownWECS->getCollisionShape()), 2, 0);
     603
     604        int temp = entityOfCollisionShape(cs);
     605        if (temp==0)
     606            orxout() << this->getName() << " has been hit on it's main body." << endl;
     607        else
     608            orxout() << this->getName() << " has been hit on the attached entity no. " << temp << endl;
     609
     610        // end
     611        return -1;
     612    }
     613
     614    void Pawn::printBtChildShapes(btCompoundShape* cs, int indent, int subshape)
     615    {
     616        // e.g. "  Childshape 1 (WECS 0x126dc8c0) has 2 childshapes:"
     617        printSpaces(indent);  orxout() << "Childshape " << subshape << " (btCS* " << cs << ") has " << cs->getNumChildShapes() << " childshapes:" << endl;
     618
     619        for (int i=0; i < cs->getNumChildShapes(); i++)
     620        {
     621            printSpaces(indent+2);  orxout() << "- " << i << " - - -" << endl;
     622
     623            // For each childshape, print: (as long as it's not another CompoundCollisionShape)
     624            if (!orxonox_cast<btCompoundShape*>(cs->getChildShape(i)))
     625            {
     626                // pointer to the btCollisionShape
     627                printSpaces(indent+2);  orxout() << "btCollisionShape*: " << cs->getChildShape(i) << endl;
     628
     629                // pointer to the btCollisionShape
     630                printSpaces(indent+2);  orxout() << "m_userPointer*: " << cs->getChildShape(i)->getUserPointer() << " (name_: " << ((BaseObject*)(cs->getChildShape(i)->getUserPointer()))->getName() << ")" << endl;
     631            }
     632
     633            // if the childshape is a CompoundCollisionShape, print its children.
     634            if (cs->getChildShape(i)->isCompound())
     635                printBtChildShapes((btCompoundShape*)(cs->getChildShape(i)), indent+2, i);
     636
     637        }
     638    }
     639
     640    int Pawn::entityOfCollisionShape(const btCollisionShape* cs)
     641    {
     642        btCompoundShape* ownBtCS = (btCompoundShape*)(this->getWorldEntityCollisionShape()->getCollisionShape());
     643
     644        return -1;
     645    }
     646
     647    void Pawn::printSpaces(int num)
     648    {
     649        for(int i=0; i<num; i++)
     650            orxout() << " ";
     651    }
    563652}
  • code/branches/presentationFS14/src/orxonox/worldentities/pawns/Pawn.h

    r9948 r10073  
    126126            //virtual void hit(Pawn* originator, const Vector3& force, float damage);
    127127            //virtual void hit(Pawn* originator, btManifoldPoint& contactpoint, float damage);
    128             virtual void hit(Pawn* originator, const Vector3& force, float damage, float healthdamage = 0.0f, float shielddamage = 0.0f);
    129             virtual void hit(Pawn* originator, btManifoldPoint& contactpoint, float damage, float healthdamage = 0.0f, float shielddamage = 0.0f);
     128            virtual void hit(Pawn* originator, const Vector3& force, const btCollisionShape* cs, float damage, float healthdamage = 0.0f, float shielddamage = 0.0f);
     129            virtual void hit(Pawn* originator, btManifoldPoint& contactpoint, const btCollisionShape* cs, float damage, float healthdamage = 0.0f, float shielddamage = 0.0f);
    130130
    131131            virtual void kill();
     
    196196
    197197            //virtual void damage(float damage, Pawn* originator = 0);
    198             virtual void damage(float damage, float healthdamage = 0.0f, float shielddamage = 0.0f, Pawn* originator = NULL);
     198            virtual void damage(float damage, float healthdamage = 0.0f, float shielddamage = 0.0f, Pawn* originator = NULL, const btCollisionShape* cs = NULL);
    199199
    200200            bool bAlive_;
     
    229229            unsigned int numexplosionchunks_;
    230230
     231            virtual int isMyCollisionShape(const btCollisionShape* cs); // FIXME: (noep) remove debug
     232            void printBtChildShapes(btCompoundShape* cs, int indent, int subshape); // FIXME: (noep) remove debug
     233            void printSpaces(int num);   // FIXME: (noep) remove debug
     234            int entityOfCollisionShape(const btCollisionShape* cs);
     235
    231236        private:
    232237            void registerVariables();
  • code/branches/presentationFS14/src/orxonox/worldentities/pawns/SpaceShip.h

    r9667 r10073  
    270270            float stallSpeed_; //!< The forward speed where no more lift is added.
    271271
     272            std::vector<Engine*> engineList_; //!< The list of all Engines mounted on this SpaceShip.
     273
    272274        private:
    273275            void registerVariables();
     
    284286            void backupCamera(); // Save the original position and orientation of the camera.
    285287            void resetCamera(); // Reset the camera to its original position.
    286 
    287             std::vector<Engine*> engineList_; //!< The list of all Engines mounted on this SpaceShip.
    288288
    289289            Timer timer_;                          //!< Timer for the cooldown duration.
Note: See TracChangeset for help on using the changeset viewer.