Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jan 29, 2006, 1:35:43 PM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: ok, the Cube Emitter works

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/projectiles/hyperblast.cc

    r6825 r6826  
    2323#include "class_list.h"
    2424
    25 #include "dot_emitter.h"
    26 #include "sprite_particles.h"
     25#include "box_emitter.h"
    2726#include "spark_particles.h"
    2827
     
    4746  this->size = 4.0;
    4847
    49   this->emitter = new DotEmitter(100, 5, M_2_PI);
     48  this->emitter = new BoxEmitter(Vector(400, 2, 2), 100, 5, M_2_PI);
     49  this->emitter->setRelCoor(200,0,0);
    5050  this->emitter->setParent(this);
    5151  this->emitter->setSpread(M_PI, M_PI);
     
    141141  glPushMatrix();
    142142
    143   float matrix[4][4];
    144   glTranslatef (this->getAbsCoor ().x, this->getAbsCoor ().y, this->getAbsCoor ().z);
    145   this->getAbsDir().matrix (matrix);
    146   glMultMatrixf((float*)matrix);
    147   glScalef(2.0, this->size, this->size);
    148   this->getModel()->draw();
     143  glTranslatef (this->getAbsCoor ().x,
     144                this->getAbsCoor ().y,
     145                this->getAbsCoor ().z);
     146  Vector tmpRot = this->getAbsDir().getSpacialAxis();
     147  glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z );
     148
     149//  glScalef(2.0, this->size, this->size);
     150//  this->getModel()->draw();
    149151
    150152  glPopMatrix();
Note: See TracChangeset for help on using the changeset viewer.