Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 10004 in orxonox.OLD for branches


Ignore:
Timestamp:
Dec 3, 2006, 10:36:50 PM (18 years ago)
Author:
marcscha
Message:

see changelog

Location:
branches/playability
Files:
4 added
7 edited

Legend:

Unmodified
Added
Removed
  • branches/playability/ChangeLog

    r9998 r10004  
    33  Multiple weapons per ship added
    44  Several small tweaks needed to make the above working added
     5  Addition of SwarmMissile and SwarmProjectile
    56
    67
  • branches/playability/src/defs/class_id_DEPRECATED.h

    r9869 r10004  
    238238  CL_HYPERBLAST                 =    0x000003e9,
    239239  CL_BOOMERANG_PROJECTILE       =    0x000003ea,
     240  CL_SWARM_PROJECTILE           =    0x000003eb,
    240241
    241242  // NPC's
  • branches/playability/src/world_entities/WorldEntities.am

    r9998 r10004  
    4040                world_entities/weapons/medium_blaster.cc \
    4141                world_entities/weapons/heavy_blaster.cc \
     42                world_entities/weapons/swarm_missile.cc \
    4243                \
    4344                world_entities/projectiles/bolt.cc \
    4445                world_entities/projectiles/mbolt.cc \
    4546                world_entities/projectiles/hbolt.cc \
     47                world_entities/projectiles/swarm_projectile.cc \
    4648                world_entities/projectiles/bomb.cc \
    4749                world_entities/projectiles/laser.cc \
     
    150152                weapons/medium_blaster.h \
    151153                weapons/heavy_blaster.h \
     154                weapons/swarm_missile.h \
    152155                \
    153156                projectiles/bolt.h \
    154157                projectiles/mbolt.h \
    155158                projectiles/hbolt.h \
     159                projectiles/swarm_projectile.h \
    156160                projectiles/bomb.h \
    157161                projectiles/laser.h \
  • branches/playability/src/world_entities/projectiles/hbolt.cc

    r10003 r10004  
    4747  this->angle = 0;
    4848  this->rotationSpeed = 1000;
     49
    4950
    5051  this->emitter = new DotEmitter(100, 5, M_2_PI);
     
    118119void HBolt::updateAngle (float time)
    119120{
     121<<<<<<< .mine
     122  this->angle += this->rotationSpeed * time;
     123=======
    120124  this->angle = this->angle + this->rotationSpeed * time;
     125>>>>>>> .r10003
    121126}
    122127
     
    173178  //this->updateAngle();
    174179
     180<<<<<<< .mine
     181  //glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
     182  //glRotatef(this->angle, 0.0, 0.0, -1.0);
     183  glTranslatef (this->getAbsCoor ().x,
     184                  this->getAbsCoor ().y,
     185                  this->getAbsCoor ().z);
     186  Vector tmpRot = this->getAbsDir().getSpacialAxis();
     187  glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
     188  glRotatef(this->angle, 0.0, 0.0, -1.0);
     189=======
    175190  //glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
    176191  //glRotatef(this->angle, 0.0, 0.0, -1.0);
     
    181196  glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
    182197  glRotatef(this->angle, 0.0, 0.0, 1.0);
     198>>>>>>> .r10003
    183199  this->getModel()->draw();
    184200  glPopMatrix();
  • branches/playability/src/world_entities/space_ships/space_ship.cc

    r10001 r10004  
    2626#include "weapons/medium_blaster.h"
    2727#include "weapons/heavy_blaster.h"
     28#include "weapons/swarm_missile.h"
    2829#include "weapons/boomerang_gun.h"
    2930#include "weapons/turret.h"
     
    152153  wpLeft3->setName("Heavy Blaster Left");
    153154
    154   Weapon* cannon = new BoomerangGun();//Cannon();
    155   cannon->setName("End of World");
     155  Weapon* cannon = new SwarmMissile();
     156  cannon->setName("Swarm Missile");
     157 
    156158
    157159
     
    273275  this->secWeaponMan.setSlotCount(6);
    274276
    275   this->secWeaponMan.setSlotPosition(0, Vector(2.6, -2.5, 0));
     277  this->secWeaponMan.setSlotPosition(0, Vector(1.5, -1, 0));
    276278  this->secWeaponMan.setSlotCapability(0, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);
    277279
     
    300302  this->weaponMan.getFixedTarget()->setParent(this);
    301303  this->weaponMan.getFixedTarget()->setRelCoor(100000,0,0);
     304
    302305 
    303306  this->secWeaponMan.getFixedTarget()->setParent(this);
    304307  this->secWeaponMan.getFixedTarget()->setRelCoor(100000,0,0);
     308  this->secWeaponMan.setRotationSpeed(0);
    305309
    306310  dynamic_cast<Element2D*>(this->weaponMan.getFixedTarget())->setVisibility( false);
     
    367371void SpaceShip::enter()
    368372{
    369   dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( true);
     373  this->secWeaponMan.showCrosshair();
     374  //dynamic_cast<Element2D*>(this->secWeaponMan.getFixedTarget())->setVisibility( true);
    370375  this->attachCamera();
    371376}
     
    373378void SpaceShip::leave()
    374379{
    375   dynamic_cast<Element2D*>(this->getWeaponManager().getFixedTarget())->setVisibility( false);
     380  this->secWeaponMan.hideCrosshair();
     381  //dynamic_cast<Element2D*>(this->secWeaponMan.getFixedTarget())->setVisibility( false);
    376382  this->detachCamera();
    377383}
  • branches/playability/src/world_entities/weapons/weapon_manager.cc

    r9998 r10004  
    126126{
    127127  this->crosshair->setVisibility( false);
     128}
     129
     130void WeaponManager::setRotationSpeed(float speed)
     131{
     132  this->crosshair->setRotationSpeed(speed);
    128133}
    129134
     
    431436
    432437  /*
    433   if( this->crosshair != NULL)
    434   {
    435438        this->crosshair->setRotationSpeed(500);
    436439        this->crossHairSizeAnim->replay();
    437   } */
     440  */
    438441}
    439442
  • branches/playability/src/world_entities/weapons/weapon_manager.h

    r9998 r10004  
    6262    void showCrosshair();
    6363    void hideCrosshair();
     64    void setRotationSpeed(float speed);
    6465
    6566    void setSlotCount(unsigned int slotCount);
Note: See TracChangeset for help on using the changeset viewer.