Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 9, 2019, 9:39:55 AM (6 years ago)
Author:
jeromela
Message:

spielfeldgroesse

Location:
code/branches/OrxoBlox_FS19/src/modules/OrxoBlox
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBlox.cc

    r12337 r12339  
    143143            // Attach the ball to the centerpoint and set the parameters as specified in the centerpoint, the ball is attached to.
    144144            this->center_->attach(this->ball_);
    145             this->ball_->setPosition(0, 0, 40);
     145            //Startposition Ball
     146            this->ball_->setPosition(0, 0, 50);
    146147            this->ball_->setFieldDimension(this->center_->getFieldDimension());
    147148            this->ball_->setSpeed(0);
  • code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxBall.cc

    r12336 r12339  
    144144            // And its position is set as to not overstep the boundary it has just crossed.
    145145            if (position.z > this->fieldHeight_ / 2){
    146                 ChatManager::message("Ball hat das Feld verlassen");
    147                 //TODO: ball zerstoeren
     146                // Set the ball to be exactly at the boundary.
     147                position.z = this-> fieldHeight_ / 2;
     148                // Set the velocity to zero
     149                this->setSpeed(0); // doesn't work here, why??;
     150                //velocity.x = 0;
     151                //velocity.y = 0;
     152                //velocity.z = 0;
     153                orxout() << "Output" << endl;
     154                ChatManager::message("Waiting");
    148155            }
    149156            if (position.z < -this->fieldHeight_ / 2){
     
    203210            // Set the speed in the direction of the balls current velocity.
    204211            Vector3 velocity = this->getVelocity();
    205             if (velocity.x != 0)
     212            //if (velocity.x != 0)
    206213                velocity.x = sgn(velocity.x) * this->speed_;
    207             else // If the balls current velocity is zero, the speed is set in a random direction.
    208                 velocity.x = this->speed_ * sgn(rnd(-1,1));
     214            //else // If the balls current velocity is zero, the speed is set in a random direction.
     215            //    velocity.x = this->speed_ * sgn(rnd(-1,1));
    209216            //velocity.y = this->speed_;
    210217            velocity.z = this->speed_;
  • code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxCenterpoint.cc

    r12307 r12339  
    5656        RegisterObject(OrxoBloxCenterpoint);
    5757
    58         this->width_ = 200;
    59         this->height_ = 120;
     58        this->width_ = 100;
     59        this->height_ = 50;
    6060        this->ballspeed_ = 100;
    6161        this->ballaccfactor_ = 1.0;
Note: See TracChangeset for help on using the changeset viewer.